PDA

View Full Version : Kali 2016 not booting when installed to USB flash drive



NoahWL1
2016-02-17, 13:25
In the past I've had no problems installing the original Kali Linux, Kali 2.0, or Kali 2016. However, I now am. Previously I've always dual or triple booted it on my main hard drive in my laptop or desktop, but now I want to install it solely on a 128gb flash drive I have. Going through the normal instalation process I've tried manually configuring two partitions like I normally do: main ext4 partition as root and a swap partition. I also tried using the guided partitioning setup but got the same result. Either way the system installs fine so I think it has something to do with GRUB. At first I tried choosing the flash drive to install GRUB to but upon booting to it I was prompted with a never ending blinking white cursor. I then tried installing it to my main hard drive, on the master boot record, and it worked. I could boot into my Windows system, my Ubuntu, my Kali Linux, and the Kali 2016 OS on the drive. So, why doesn't it work when I install GRUB to the USB drive? I feel like I've tried everything. Oh, and I'm using a different flash drive (an 8gb one) to install Kali, not the 128gb one I'm trying to install to. The sha1 checksums check out as well, so my download isn't corrupt. Is there a thing I can do? Thanks.

duxim
2016-02-17, 20:33
dual boot any Linux on two disk is little bit tricky. you have a two methods.
first is when you physical disconnect your main hdd from the system and perform normal installation on second drive in your case on usb with grub. when you finish this, restart your system and verify is system normally boot, run etc...
on this point you need to setup bios to boot from usb
is everything ok then you can connect your main hdd and set boot order (usb should be first device for boot) and if usb is presented
then Kali will start if not then the main system (from main hdd) will start.
this is a "safe method" :)
second method is when both disc are connected to the system and you install Kali on usb (second disc) with grub on it (not on main hdd)
when you finish installation just reboot to examine is everything ok with your first disk.
system will boot into Windows and Ubuntu (in your case). Then restart again and in bios change the boot sequence to
second hdd (in your case usb) and from that point you should have grub with all listed systems
this is "theory of dual boot with two hdd" :o

I never did this on usb, but on two hdd it works
and if you want "sure thing" for usb installation read this post
https://forums.kali.org/showthread.php?27043-Master-trick-How-to-install-Kali-2-0-to-an-USB-stick-without-any-kind-of-problem

If you try those methods it will be nice to inform us if they works on usb installation.

Cheers
duxim

NoahWL1
2016-02-17, 20:49
Thanks for the reply Duxim. I had tried the second method you listed but wasn't getting those results. Grub just wasn't showing up when booting from the flash drive when selecting to boot from the flash drive in the BIOS. I'm trying the first method now, where I remove the primary hdd. It's installing now so I'll post my results here in a bit. Thanks for the help.

NoahWL1
2016-02-17, 21:06
I was able to get Grub to install on the USB drive by removing the laptop's hdd, but when I choose Kali from the Grub menu I get the errors as shown in this picture: http://i.imgur.com/aBsSp33.jpg

I've never gotten anything like this before.

duxim
2016-02-17, 22:32
read this post. maybe it could be helpful
http://ubuntuforums.org/showthread.php?t=1610142

i am thinking that errors have something with settings, but I don't know which one.
try stupid things like set bios to default setting and once again set boot order, unplug and plug again usb....

always you got third method which works, but if you have time little investigate why you get those errors

village_idiot
2016-02-18, 18:27
Noah I have had no end of problems creating bootable flash drives with recent distributions
of varied Linux flavors. I have tried different brands of flash drives and even different models
within a brand and I cannot make rhyme or reason out of why some work and some do not.
I have a few PNY Attache which work reliably to create bootable Pen Drives but other models
do not play nicely for me. I read on another site to use the ISOHYBRID tool but that has not
proven reliable for me. At this time it has only muddied the water so to speak. Thus far I use
a 32 bit ISO and DD which provides consistent results with the Attaches. I also use dd to copy
the image to the flash. For Kali that results in two partitions on a 4 GB flash drive. sdx1 starts
at sector 64 and ends at sector 6324223. It is an ID 17 Hidden HPFS/NTFS file system. sdx2
is 78.7 MB starting at 6324224 and ends at 6485375. It is an ID 1 Fat12 file system. I do not
know why the gap occurs between sdx1 and sdx2 relative to the missing sectors.

One thing I have noticed is that on some boxes even the drives that boot drop to a CL
prompt balking about the file not being a COM32 image. In that case to continue the boot
process I hit the tab key. That displays the names of the images on the flash drive and
then I type the name of the particular distro appearing at the command line prompt. If
my intent is to install then I type "install live"
and it goes to the installation screen.

One other anomaly is on some machines I will be stopped by a message telling me the
CD-ROM is not found or busy despite the boot is form the flash drive. To solve that
problem grab the flash drive and rudely rip it out of the port. Wait five seconds. Then
plug the drive back in and again wait five seconds. Then select the option to continue.

I have no clue why that works. For more info see the link:

superuser.com/questions/962926/cant-install-kali-linux-from-usb-fails-to-find-cdrom-drive


The only consistency I can find thus far is the bootables drives boot on some machines as expected,
other boxes it is a dance to install using the above methods. No brand of computer seems to work
better than the other, it is just hit or miss.

Wish I could be of more help. I ordered PNY Attaches last Sunday for hoarding purposes. Some write ups
indicate that the internal controllers in the flash drives are bad actors in this manège de trois. That would
explain why some of the PNY drives work for me and other PNY's do not.

I miss the old days were I just plugged in a flash drive and the downloaded ISO worked out of the gate.


VI

Monday is an awful way to spend 1/7 of your life.

village_idiot
2016-02-19, 16:15
More notes on the booting issue.

I received an order of flash drives direct from PNY yesterday afternoon.
A 32 GB USB 3.0 drive was selected for the test. The test would be to
dd the Kali 2016 ISO image to the drive and try to boot.

The test failed with the new drive.

Next trial involved using dd to copy the working Kali 2016 bootable flash
to the new 32 GB USB 3.0 flash drive. The command

dd if=/dev/sdc | pv | dd of=/dev/sdd

was used to copy the working drive to the flash drive. dd diligently copied
the image of the 4 GB drive to the 32 GB USB drive.

Then the partition contents of sdc and sdd were compared using 'fdisk -l'
which returned the info the two partitions on sdd match the partitions on
sdc.

Looks good so far. Tried to boot and the system with the 32 GB USB 3.0
drive and it was totally ignored. Tried the original working 4 GB USB 2.0
drive and the system booted from the flash drive.

Drilling further down I compared the partitions using MD5SUM. First I
check the MD5SUM of sdc1 and then sdd1. They returned different
MD5SUM values.

I have tried to make multiple different drives bootable using Universal
USB Installer, Live USB Creator (both for Windows), Live USB Creator
for Linux and also 'dd'. I have concluded there is something amiss
with the flash drives as some boot fine on my test platform and
others do not despite having the same partitions, files etc.
I get the same results when using various flavors of Linux. Some
drives will boot using the live distro and others will not.

To abuse an often used phrase, "This is above my pay grade"
or basically I have reached the end of my rope trying to determine
who is doing what to whose cow for how much money.

Anyone familiar with the innards of flash drives that can elaborate
out there?

VI

The colder the X-Ray table the more of your body that is required to be indirect contact with the surface.

NoahWL1
2016-02-20, 20:13
After a lot of trying and failing I decided to just go with using the Live USB with persistence route. I didn't want to do this originally since I wasn't sure exactly what would be saved, and I don't think I'll be able to do dist upgrades on it, but it seems to be working fine for now. Thanks for the help guys.