Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Follow Contact

HF Rulez the UniverseHF Rulez the Universe
Raymond Reddington
Legendary Vendor
kali linux kali setup hacking pentesting cybersecurity

[TuT] Kali Linux Installation Tutorial - HDD, USB, VM, RPi & VPS

Posted 09-07-2022, 04:53 PM
[Image: mfuNoEa.png]

[Image: zsBn6iI.gif]

[Image: gXRamuy.gif]

Introduction to Kali Linux
The Linux distribution every hacker needs in their life.

[Image: Khsq7Hx.jpg]

I.) Introduction
Kali Linux (formerly known as BackTrack Linux) is a Debian-derived Linux distribution designed for digital forensics and penetration testing. It is maintained and funded by Offensive Security, the maintainer of the ExploitDB vulnerability database. Kali Linux is specifically geared to meet the requirements of professional penetration testing and security auditing.

Kali Linux is geared towards various information security tasks, such as penetration testing, security research, computer forensics and reverse engineering. You can run Kali Linux on your local HDD, on an external bootable USB, a virtual machine - or better yet on a Raspberry Pi or RDP/VPS. You can find your respective version on at https://www.kali.org/get-kali/ we'll be covering tutorials on all fronts for installation

II.) System Requirements
Kali Linux requires:
  • A minimum of 20GB hard disk space for installation depending on the version, Version 2020.2 requires at least 20GB.
  • A minimum of 2GB RAM for i386 and AMD64 architectures.
  • A bootable CD-DVD drive or a USB stick.
  • A minimum of an Intel Core i3 or an AMD E1 processor for good performance.

We recommend going with around 8GB of RAM and at least 40GB of disk space while installing Kali. You may require more disk space if you intend on storing large files, such as wordlists or hash lists.

III.) Local HDD Installation Tutorial

  1. Download the 32-bit or 64-bit ISO files from the Kali website, and proceed to either burn the ISO to a DVD or a flash drive.

  2. Proceed to boot via your installation medium to initiate the setup. Select "graphical install" for a GUI-enabled installation.

    [Image: QlVtiVZ.png]

  3. Proceed to select your language, location, keyboard mode. You will then be prompted to enter your hostname, domain name and username.

    [Image: B1geBo4.png]

  4. After you're finalized these, you should be prompted to configure your root password

  5. You should now be prompted regarding disk partition options. For this tutorial, we shall continue with "Guided - use entire disk"

    [Image: Yqu9Dp3.png]

  6. You will have to select a local disk that will serve as the main partition for your Kali Linux installation.

  7. Proceed with the option to "Place all files in the same partition" and finish partitioning.

    [Image: Il4tiNj.png]

  8. Your OS should be installing right now.

    [Image: 3gpWqO2.png]

  9. Once you are done with the setup, you should be prompted for further networking options such as proxied communication. If you aren't using a proxy, I recommend skipping this part.

  10. The final prompt should be the GRUB boot loader installation, proceed by installing it to the master boot record.

    [Image: Ae2oLfQ.png]

  11. The system will automatically restart and you should be able to access Kali Linux after that.

    [Image: 75VedCO.jpg]

IV.) External USB Installation Tutorial

  1. For USBs, Kali Linux “Live” is the default version for operating Kali out of an external USB. However, we will need to enable persistence - the preservation of data on the “Kali Live” USB drive - across reboots of Kali Live.

  2. With active persistence, you should be able to retain data across different systems as you operate your portable version of Kali Linux from your flash drive.

  3. To get started with the setup, insert the USB flash drive you'll be installing Kali Linux on. Make sure it's over 8GB in size, preferably 16-32GB. Use a USB 3.0 port for faster read/write speeds.

  4. Use a tool such as Rufus or Win32 Disk Imager to write the ISO file to your USB. Make sure to select FAT32 as the file system (check the screenshots below).

    [Image: ebDGjpU.png]
    [Image: B80ZA32.png]

  5. Make sure UEFI mode is disabled within the BIOS.

  6. Install MiniTool Partition Wizard. We will be requiring this tool within the tutorial.

  7. Locate your USB within Partition Wizard and create a partition within the USB drive.

    [Image: GT0auvE.jpg]

  8. Use the following information while making this partition:
    Partition Label: Persistence
    Create As: Primary
    File System: Ext3

  9. Our final step will involve enabling persistence for our Kali Linux Live instance to be setup, for which, you will need to reboot and boot into your USB.

  10. Use the following commands to recreate the persistence partition you just created:
    fdisk -l
    mkfs.ext3 -L persistence /dev/sd3
    e2label /dev/sd3 persistence
    mkdir -p /mnt/my_usb
    mount /dev/sd3/mnt/my_usb

    [Image: MQ0TLLi.jpg]

  11. To conclude, add a config file to temporarily store your data and reboot your OS.
    echo "/union"> /mnt/my_usb/persistence.conf

  12. You should be able to access the "Live USB Persistence" mode on Kali Linux Live and operate Kali Linux from your USB drive.

V.) Virtual Machine Installation Tutorial
  1. Download the latest ISO for Kali Linux VM installations from their website.

  2. For this tutorial we shall be using Oracle VM VirtualBox but you can use other tools such as VMWare or Citrix DaaS too. Proceed to "Create" a new VM instance

  3. Once you type "Kali Linux", VMWare will automatically recognize the distribution and autofill the Type & Version by itself.

    [Image: 8htC2D0.png]

  4. Allocate anywhere between 2GB (minimum) to 8GB RAM to your VM. You can allocate more if you have more RAM available.

    [Image: WrNAT68.png]

  5. Choose to create a new virtual hard disk. You will be prompted for the filetype right after that.

    [Image: vMby5Nw.png]

  6. You can select a fixed or dynamically allocated hard disk storage for your VM as per your personal preference. The fixed format will instantly reserve the specified size on your hard disk while the dynamic format will grow gradually as your data piles up.

    [Image: yxXU23z.png]

  7. Make sure to allocate a minimum of 20GB to your installation. It's recommended to go with a higher size such as 30-40GB if you intend on using it often.

    [Image: UCg8uOs.jpg]

  8. Your VM is created. We have one final change before we boot up the VM, head over to "Network" settings and select "Move All" for Promiscuous Mode.

    [Image: 9WAkQTU.jpg]

  9. Open your VM and select your ISO file as the start-up disk.

    [Image: OmLKXXv.jpg]

  10. You will be greeted by the Kali Linux boot menu. From here, the steps involved shall remain similar to the Local HDD Installation Tutorial. Kindly refer to Section III.) of this thread.

    [Image: OmLKXXv.jpg]

VI.) Linux VPS Installation Tutorial

  1. You can easily install Kali Linux on common Linux distributions such as Debian or Ubuntu. Within this tutorial, I shall illustrate how to install Kali Linux within your Linux VPS within minutes. This works perfectly combined with the free Azure VPS tutorial I've posted a few days ago.

  2. After you acquire your Debian/Ubuntu VPS, we will proceed by updating it and installing the latest Kali live-build packages. Run the following commands:
    sudo apt update
    sudo apt -y upgrade
    wget https://http.kali.org/pool/main/k/kali-archive-keyring/kali-archive-keyring_2022.1_all.deb
    wget https://http.kali.org/pool/main/l/live-build/live-build_20210216kali1_all.deb
    sudo apt -y install git live-build cdebootstrap debootstrap curl
    sudo dpkg -i kali-archive-keyring_2022.1_all.deb
    sudo dpkg -i live-build_20210216kali1_all.deb
    cd /usr/share/debootstrap/scripts/ (echo "default_mirror http://http.kali.org/kali"; sed -e "s/debian-archive-keyring.gpg/kali-archive-keyring.gpg/g" sid) > kali sudo ln -s kali kali-rolling  cd ~ git clone git://gitlab.com/kalilinux/build-scripts/live-build-config.git  cd live-build-config/

  3. After the live-build packages have been installed and assuming your versions are correct, we will proceed to build the required ISO.
    sudo ./build.sh --variant light --verbose
    sudo apt -y install qemu-kvm libvirt-bin ubuntu-vm-builder bridge-utils sudo adduser $(id -un) kvm newgrp kvm
    qemu-img create -f qcow2 kali-disk.img 100G kvm --name Kali -m 1024 -hda kali-disk.img -cdrom kali-linux-light-rolling-amd64.iso -boot d

  4. You should be greeted by the familiar Kali Linux boot menu on via QEMU Disk Image Utility:


  5. Proceed with the same steps as explained within Section III.) of this thread.

  6. Once you are done with installation, you can boot up Kali Linux on your VPS by using the following command:
    kvm --name Kali -m 1024 -hda kali-disk.img -boot c

VII.) Raspberry Pi Installation Tutorial

  1. Download the Raspberry Pi ISO from the official Kali Linux website for this setup. You will need a SD card (recommended 8GB+ space) and preferably a class 10 SD card for faster read/write speeds.

  2. You will need to decompress the downloaded package using any compression software such as WinRAR, WinZip or 7z.

  3. Download and install balenaEtcher. We will use it to write the decompressed disk image to our Raspberry Pi.

    [Image: r4b6IiV.jpg]

  4. Select the decompressed image, your SD card and flash your SD card.

  5. You can now insert your SD card into to your Raspberry Pi and you successfully have installed it on your RPi. You can proceed to connect display, Ethernet, mouse/keyboard & power supply and Kali Linux will boot up.

  6. Similarly, you can also run this virtually on your RPi by combining the methods used in VI.) and VII.)

  7. Your login credentials will be the default credentials on Kali Linux installations. These are
    Username: root
    Password: toor