Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Hello, i just installed Kali Linux on an external hard drive, everything worked fine and Kali worked as expected.
But now i plugged the hard drive into another laptop, and when i boot Kali linux from the Grub menu, i get This:
mount: mounting /dev/sdb1 on / root failed: no such device
mount: mounting/dev on /root/dev failed: no such file or directory
mount: mounting/dev on /root/dev failed: no such file or directory
mount: mounting/dev on /root/run failed: no such file or directory
run-init: current directory on the same filesystem as the root: error 0
Target filesystem doesnīt have requested /sbin/init.
run-init: current directory on the same filesystem as the root: error 0
run-init: current directory on the same filesystem as the root: error 0
run-init: current directory on the same filesystem as the root: error 0
run-init: current directory on the same filesystem as the root: error 0
run-init: current directory on the same filesystem as the root: error 0
No init found. Try Passing init= bootarg.
BusyBox v1,27,2 (Debian 1:1.27.2-3) built-in shell (ash)
Enter īhelp` for a list of built in commands
(initranfs)
I guess the problem is that it thinks that it is still connected to the other laptop.
it would be very nice if someone could tell me how to fix this, since iīm new to Linux and donīt know what to do.
you plugged in the hdd into a DIFFERENT system using /dev/sda is your problem. usb usually starts at sdb depending on what is hooked up inside of the box. UUID is good for moving hdds around via usb plugs if you're not knowing how to deal with the changing of the dev/sdx prior to booting it else where.
using grub on a different system it would be good to boot that system with that usb os plugged in update-grub, then reboot so it knows what and where to boot to get it running.
Do both laptops have identical BIOS configurations, both set to UEFI boot, or both to BIOS/Legacy boot? Are they similar in age and/or CPU type? Will the second boot with the non-booting USB connected? If so, show us the output from bootinfoscript. Do the same booted from the USB connected to the original target. Also give us lspci output from both laptops. Model numbers for both might be of use as well.
Thank you both for your quick replies, it's very nice to see how open the Linux community is. mrmazda, it will take some time to find out the info you asked for. But I didn't understand one of your requests, you said: Will the second boot with the non-booting USB connected.
I don't understand what you mean with '' the non booting USB connected''.
I don't understand what you mean with '' the non booting USB connected''.
With the USB HD connected, try to boot from the internal HD. If that's not possible, then boot from the internal HD without the USB HD connected, and after it boots, connect the USB HD, then collect the requested information.
@BWuserx
I guess the problem is really that it doesnīt recognize that it is plugged into antoher laptop, because in the grub boot menu it also shows me windows 7 to boot. Even though i donīt have windows 7, but it was installed on the previous laptop. i tried typing "update-grub" in the grub shell, but nothing happens. Do you know a Command that can update grub?
If necessary i can hook up the hard drive to the first laptop, where Kali works so that i can use the terminal.
Alternatively i also have a kali linux live stick if that is needed.
Thank You!
@mrmazda
First of: maybe i can solve the problem much easier: I know that if i simply reinstall kali on the second laptop, my problem would be fixed. I didnīt do that so far because that would require me to add grub to my mastert boot record. Normally that wouldnīt be a problem, but i switched the bootmode to legacy. Since iīm in legacy bootmode it doesnīt recognize Windows because that is installed in UEFI.
I am afraid that that installing grub to the MBR will make windows unbootable.
But i donīt know if the master boot record is the same for legacy and UEFI. If installing grub to the MBR in legacy boot mode will leave my UEFI boot untouched i could simply reinstall Kali in legacy on my second laptop. So please tell me if UEFI and LEGACY are seperate or on the same MBR.
Your requests:
They are both set to legacy boot mode, the first laptop was always on legacy boot mode. I always had the second one set to UEFI, however my UEFI is making a lot of problems
(because somehow i have two UEFI partitions, one on my internal ssd and one on my internal hdd)
and i am not able to boot anything except for windows10 there. So i switched to legacy boot mode which works but only for Linux. I always have to change to UEFI if i want to use Windows.
The first laptop is way older, it has an intel core i3 inside. Itīs a Think pad. The second one has an intel core i5 7200u inside. Itīs an acer aspire e 15.
I had to use the first laptop for the kali installation, because i donīt want to install grub to my main (second)laptop.
I donīt know how to answer your last request since when iīm in legacy boot mode i canīt boot from the internal drive because it only works on UEFI.
maybe this is helpful: i already had Kali linux installed and used it on the second laptop. I made a mistake with trying to reinstall my kernel headers in the terminal which completely destroyed my previous installation of Kali. The difference with the previous installation was that i had installed Kali on a friends PC which also runs Windows 10 and has similar specs. If iīm unable to make my external HD boot kali on the second laptop i could ask that friend again to install kali from his pc which will probably work, but he is currenly on vacation.
It is unclear what happens when you switch the second laptop to boot in legacy mode. When you do that trying to boot the USB, do you get the errors reported in your OP, or does it boot normally?
AFAICT, there is no PC or laptop that can have disks with installations in both legacy and UEFI mode and be able to boot unconditionally, that is, either you can boot those that are in legacy mode, or those in UEFI mode, according to the BIOS setting, never have a choice among all without a BIOS setting change between legacy and UEFI according to which you wish to boot.
As to MBR issues, I defer to others. I never install Grub to MBR. On my UEFI systems Grub is on the ESP partition and the root partitions. On my legacy systems the MBR always contains either no boot code, or Windows-compatible boot code; Grub on legacy/MBR disks here is installed only to partitions. https://old-en.opensuse.org/Bugs/gru...orking_GRUB.3F explains why installing to partitions
@ohondo thank you, the post I found in your link was very helpful, however could you explain
It a bit more in detail, because I don't know for example if I need to type these commands inside of grub or inside of kali.
In your original post you indicate that you installed Kali to a secondary drive (sdb) and everything worked. In a later post when you attempt to boot from the second drive, you indicate that the Grub menu shows windows 7. Does that mean you have windows 7 on the original computer? If so, that is expected behavior. Did you do a Legacy/MBR install of Kali which windows 7 almost certainly was. Did you install the Kali Grub to the MBR of the first drive? If you were planning to use Kali on another computer, you should have install Grub code to the MBR of the usb, which in your case would seem to be sdb.
You then mention that you have windows installed UEFI, is that windows 7 from the first computer or another windows system? I know of no way for a Legacy Grub to boot an EFI system of windows as has been pointed out above. It can be done with Linux/Linux installs.
Quote:
Yes I have Grub installed on the drive, and it boots without having to use f12 but only in legacy
Today 01:29 AM
Quote:
When I use the drive on the second laptop It boots normally into grub and when I select kali Linux, it shows me the error message from my first post.
The two quotes above from separate posts seem to contradict each other. Does it successfully boot Kali on the usb drive or not?
If you have one system Legacy and one UEFI, the only way to boot between them is through the BIOS as pointed out above.
Might be best to download and run the 'bootinfoscript' and post the output here as it will have a lot more detail. It may simply be a problem with UUIDs but it may also be a conflict between EFI/Legacy.
It doesn't boot on the second laptop which your quotes are about I just meant that it boots into grub, and then into kali but inside of kali I get the error. I wasn't sure what was meant by boot, because it depends on the definition. So it does boot in the sense that it starts grub. But it doesn't boot in the sense that inside of kali it gets stuck.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.