Results 1 to 15 of 15

Thread: Weirdest Issue: Installing Kali Linux On An External Harddrive

  1. #1
    Join Date
    2017-Aug
    Posts
    10

    Weirdest Issue: Installing Kali Linux On An External Harddrive

    Hey there!
    So I am new here but very much a computer enthusiast. I have been dealing with the upcoming issue for more than 6 days now and I am starting to claw my eyes out. I am becoming ever confused, desperate and most of all annoyed because every time I get something right, it's broken down again. Alright, onto the issue.

    I am running windows 10 on an MSI laptop and I have gotten sick of windows which I reluctantly use for some windows only applications that I need in live. I decided I wanted to start using Linux more because it appeals more to me. I started experimenting with Kali Linux since most of my books use Kali as a distro for pentesting. So I got a sandisk 16 GB 3.0 usb and used diskpart to convert it to GPT, format it to FAT32 and then used 7zip to extract the most recent Kali Linux ISO to the USB. I got into BIOS, turned off fast boot and secure boot, set the boot settings so that it would boot from usb first and then the windows disks. So far so good. I grab my external Seagate 1TB HDD and plug it in. Then I boot my USB in with the extracted ISO. Restart computer and press F11 to go into boot settings. I select my UEFI USB with the ISO and boot into it. The Kali menu shows up and asks me to boot into live, install the system etc. Cool! So far so good. I go into advanced settings to do the graphical install. Selecting all necessary options. Then comes the hard drive partitioning. My seagate shows up. Nice. I select it and want to have a seperate /home, /var and /temp partition. ERROR: /var partition is offset by 3584 bytes and how this can screw your performance up. But it shows instructions on how to fix it so I follow those. However the instructions are fruitless and I am clueless on how to fix it. But whatever I decide to throw all in one single partition and it shows no errors now. Ok. So the system is getting installed on the hard disk. Once done I reboot, press F11 again and boot into the available kali seagate option! Awesome! I have actually gotten kali to work from an external hard drive on my laptop! It isnt slow it runs smooth and everything works!

    Now this is where things get f*cking weird....

    I turn my laptop off.... boot into windows one last time..... shutdown the computer.... take out the external usb hdd after the light switched off. Next day I wanted to start my new lovely kali linux... I put in the external hard drive, and turn on the system. I press F11 and..... there is no option to select the hard drive. The option I had the day before is gone. Diskmgmt on Windows 10 shows the partitions and all that but I cant boot into it. HOW COME?! How come that I could boot into that harddrive right after installation finished and even download wallpapers and then after SAFELY unplugging it, it is not to be found in the boot manager?! Please help me! Even the local computer store people dont know what happened and changing from UEFI to Legacy in BIOS doesn't change it!

  2. #2
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    When you press F11, do you see an option Boot from EFI just below the Windows Boot Manager?

  3. #3
    Join Date
    2017-Aug
    Posts
    10
    Nope. The option isnt there. But it gets worse now! Read on.

    After all this nonsense with the external hard drive i said screw it i cant fix it. So i installed it on my internal hard drive and works like a charm. Now here is the big BUT(t)!

    I had to clean my laptop from the inside. I disconnected the hard drive and plugged it in again. I restart my computer and the grub boot loader is missing again! I cant boot into linux and grub doesnt show up. I can mount the partitions but I cant start up kali linux since the bootloader is gone. Any help would be great.
    Last edited by maiki; 2017-09-06 at 08:28. Reason: Foul Language

  4. #4
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    Your original issue with external HDD wouldn't have been a problem if you had continued with conversation in this thread. In UEFI settings you can manually add entries of bootloaders.

  5. #5
    Join Date
    2017-Aug
    Posts
    10
    Well since this problem is exactly the other than the fact its an internal hard drive ill see what I can do. Reason I didnt continue conversation was because I didn't check often nor did i receive any notifications. But ill try your suggestion out see what happens.

  6. #6
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    In UEFI settings>Boot order>Add>Select interface>EFI>kali>grubx64.efi


    Settings can be different in your device but they are similar. If you get stuck, post a screenshot from that point where you don't know how to proceed.

  7. #7
    Join Date
    2017-Aug
    Posts
    10
    Will do! (Sorry for the profanities... )

  8. #8
    Join Date
    2017-Aug
    Posts
    10

  9. #9
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    When you power ON press F9, it will take you to boot menu options. Select Boot from EFI>Select interface>EFI>kali>grubx64.efi. Once you boot kali run sudo grub-install /dev/sda && sudo update-grub

  10. #10
    Join Date
    2017-Aug
    Posts
    10
    Untitled.jpg
    here are the partitions on both drives. According to windows they are all " Healthy" however I see that the EFI partition doesn't have the (Boot) flag. Could this be my problem?

    On MSI its actually F11. Ill post pics in a bit.

    This is what I am shown/

    WhatsApp Image 2017-09-09 at 15.43.02.jpg
    (sorry... didnt upload properly)

    I am actually prepared to transfer 40$ to the first person that knows how to fix this problem because I do not know where to go anymore.
    Last edited by maiki; 2017-09-11 at 10:01. Reason: Merge posts

  11. #11
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    Your firmware doesn't have option to add entry of grub from EFI. Even if it has we might have missed it somewhere in the UEFI settings. So we are going to use the long way. Follow the instructions given here to reinstall grub: https://forums.kali.org/showthread.p...ith-Windows-10

    Also show the output of fdisk -l once you boot kali live.

  12. #12
    Join Date
    2017-Aug
    Posts
    10
    root@kali:~# fdisk -l
    Disk /dev/nvme0n1: 238.5 GiB, 256060514304 bytes, 500118192 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: gpt
    Disk identifier: CD914108-4C59-49AC-89E2-56C495FD3BC5

    Device Start End Sectors Size Type
    /dev/nvme0n1p1 2048 616447 614400 300M EFI System
    /dev/nvme0n1p2 616448 878591 262144 128M Microsoft reserved
    /dev/nvme0n1p3 878592 498274303 497395712 237.2G Microsoft basic data
    /dev/nvme0n1p4 498274304 500117503 1843200 900M Windows recovery environment


    Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 4096 bytes
    I/O size (minimum/optimal): 4096 bytes / 4096 bytes
    Disklabel type: gpt
    Disk identifier: 7B37B810-43B9-458C-A01B-9CED3B9BF283

    Device Start End Sectors Size Type
    /dev/sda1 2048 865132543 865130496 412.5G Microsoft basic data
    /dev/sda2 865132544 866183167 1050624 513M EFI System
    /dev/sda3 1914009600 1953523711 39514112 18.9G Windows recovery environment
    /dev/sda4 866183168 939511807 73328640 35G Linux filesystem
    /dev/sda5 939511808 959565823 20054016 9.6G Linux filesystem
    /dev/sda6 959565824 967907327 8341504 4G Linux swap
    /dev/sda7 967907328 971812863 3905536 1.9G Linux filesystem
    /dev/sda8 971812864 1914009599 942196736 449.3G Linux filesystem

    Partition table entries are not in disk order.


    Disk /dev/sdb: 14.5 GiB, 15597568000 bytes, 30464000 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disklabel type: dos
    Disk identifier: 0xbad74d2f

    Device Boot Start End Sectors Size Id Type
    /dev/sdb1 * 64 5456223 5456160 2.6G 17 Hidden HPFS/NTFS
    /dev/sdb2 5456224 5457631 1408 704K 1 FAT12
    /dev/sdb3 5457920 30463999 25006080 11.9G b W95 FAT32


    Disk /dev/loop0: 2.4 GiB, 2558234624 bytes, 4996552 sectors
    Units: sectors of 1 * 512 = 512 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes

    This is the output of fdisk -l. Following your guide i have to mount all my linux partitions?

    I mounted all my partitions to /mnt. However when i do "root@kali:~# mount --bind /dev /mnt/dev" it says "mount: mount point /mnt/dev does not exits". A penny for your thoughts?
    Last edited by maiki; 2017-09-11 at 10:02. Reason: Merge posts

  13. #13
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    When you run those commands, replace /dev/sda* with /dev/sda4 and /dev/sda+ with /dev/nvme0n1p1. grub-install /dev/sda will become grub-install /dev/nvme0n1 where /dev/nvme0n1 is the name of your SSD.

    Be careful with spaces or copy paste them.
    Last edited by _defalt; 2017-09-09 at 20:28.

  14. #14
    Join Date
    2017-Aug
    Posts
    10
    You sure? The EFI folder with Grubx64.efi (or however its called) is located in /dev/sda2. I want to know why you choose the EFI partition on /dev/nvme0n1p1 (i want to learn more about it than just perform tasks )

    Alright so I reinstalled the bootloader to sda2. It works again!!!!! I owe you 40$! Please send me a paypal email address because you deserve the money for solving this issue that those people at the computer store couldnt.
    Last edited by maiki; 2017-09-11 at 10:03. Reason: Merge posts

  15. #15
    Join Date
    2016-Oct
    Location
    /dev/sda
    Posts
    928
    Quote Originally Posted by G0dlyLuck View Post
    You sure? The EFI folder with Grubx64.efi (or however its called) is located in /dev/sda2.
    You can install grub in either of the EFI partition. Some people even install grub in USB.

    Quote Originally Posted by G0dlyLuck View Post
    I want to know why you choose the EFI partition on /dev/nvme0n1p1 (i want to learn more about it than just perform tasks )
    In /dev/nvme0n1p1 your windows bootloader is also present so it is just for convenience if both the bootloaders lies in same EFI partition.

    But while installing grub you have to make sure where you are installing it. You must know the name of partition to mount and the name of that EFI partition where grub will be installed. The name of disk is also required to point grub-install command to the disk where your EFI partition is. That's why i asked you to make following changes while entering those commands:
    Quote Originally Posted by _defalt View Post
    When you run those commands, replace /dev/sda* with /dev/sda4 and /dev/sda+ with /dev/nvme0n1p1. grub-install /dev/sda will become grub-install /dev/nvme0n1 where /dev/nvme0n1 is the name of your SSD.

    Be careful with spaces or copy paste them.

    Quote Originally Posted by G0dlyLuck View Post
    Alright so I reinstalled the bootloader to sda2.
    It wouldn't have worked if name of your disk and partitions were different. While creating that thread i chose the standard name as /dev/sda and this is different for each storage units attached with your system.
    Last edited by _defalt; 2017-09-09 at 20:57.

Similar Threads

  1. Installing Kali 2.0 and boot loader to external USB harddrive
    By JCDinPGH in forum Installing Archive
    Replies: 0
    Last Post: 2015-08-13, 15:41
  2. Installing on external hard disk grub issue
    By Blackshield1 in forum Installing Archive
    Replies: 0
    Last Post: 2015-07-10, 21:08

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •