Linux - Newbie This 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.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
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.
|
 |
02-04-2010, 06:44 AM
|
#1
|
LQ Newbie
Registered: Feb 2010
Posts: 4
Rep:
|
migrated from ext3-disk to a ext4 disk - now linux wont boot
OS: Debian unstable 32bit, kernel 2.6.32-2, grub 1.98 from late january 2010 (only have working net-access from work now, so I am grabbing information from memory).
EXT3 and EXT4 support is compiled into the kernel along with chipset/scsi/sata support (not as modules), and I have tested to boot ext3 with it before proceeding.
Prereq: my old disk started to have too much S.M.A.R.T errors, so I bought another one, put in a USB cabinet, added swap and ext4 partition/filesystem to it, and copied over all data from the old system to the new that was mounted at /dest using the command "find ./ -xdev -print0 | cpio -paV0 /dest".
Swiched disks, so I now have the ext4 disk sitting at /dev/sda (partitions: sda1 => ext4, sda2 => swap), and booted into rescue-mode from cdrom, using /dev/sda1 as root with a shell on.
After doing this, I performed the following commands:
mount --bind /dev /dest/dev
chroot /dest
modified the /etc/default/grub to instruct the kernel to boot using ext4, ran grub-install --recheck /dev/sda
ran update-grub to modify /boot/grub/grub.cfg (which looks as it should)
After doing this, grub finds my partition and mounts it. It however stalls with the message: "warning: unable to open an initial console" and does nothing after this point.
I have no ramdisk, but my old kernel booted fine from ext3 (and still does if I copy it to a ext3 partition), and since the ext4 support is compiled into the kernel - should I really need a ramdisk?
Anyone have a clue about what could be wrong?
|
|
|
02-04-2010, 10:26 AM
|
#2
|
LQ 5k Club
Registered: May 2003
Location: London, UK
Distribution: Fedora40
Posts: 6,153
|
Quote:
Anyone have a clue about what could be wrong?
|
Only grub2 has support for ext4, so you'll need to get a copy of that, and use grub2 from now on. I doesn't matter that you have ext4 compiled into your kernel - grub cannot load the kernel from the ext4 partition.
You could boot from a 'buntu 9.10 CD which comes with grub2 and use the live CD to install grub2 to your HDD using the command line in a root terminal.
Here's a tutorial for grub2. I suggest you read it before you start as grub2 is very different from "grub legacy".
|
|
|
02-04-2010, 10:34 AM
|
#3
|
LQ Newbie
Registered: Feb 2010
Posts: 4
Original Poster
Rep:
|
Quote:
Originally Posted by tredegar
Only grub2 has support for ext4, so you'll need to get a copy of that, and use grub2 from now on. I doesn't matter that you have ext4 compiled into your kernel - grub cannot load the kernel from the ext4 partition.
You could boot from a 'buntu 9.10 CD which comes with grub2 and use the live CD to install grub2 to your HDD using the command line in a root terminal.
Here's a tutorial for grub2. I suggest you read it before you start as grub2 is very different from "grub legacy".
|
I have grub2 installed (the version number is 1.98, grub1 latest is 0.97 methinks). I am using a very up-to-date debian disk to do the rescuing, which is practical as it both contains grub2 and ext4 support.
|
|
|
02-04-2010, 10:49 AM
|
#4
|
LQ 5k Club
Registered: May 2003
Location: London, UK
Distribution: Fedora40
Posts: 6,153
|
You have grub2 - sorry for not noticing that.
So, if you boot your kernel (and do you mean just the kernel, or the root filesystem as well?) from an ext3 partition, it works, but if you boot the kernel from an ext4 partition, it fails?
What does your grub.cfg look like?
|
|
|
02-05-2010, 03:19 AM
|
#5
|
LQ Newbie
Registered: Feb 2010
Posts: 4
Original Poster
Rep:
|
Quote:
Originally Posted by tredegar
You have grub2 - sorry for not noticing that.
So, if you boot your kernel (and do you mean just the kernel, or the root filesystem as well?) from an ext3 partition, it works, but if you boot the kernel from an ext4 partition, it fails?
What does your grub.cfg look like?
|
Well.. as I tried to take another copy of the old disk, it went up into smoke.. so now I am in no need of moving data anymore (disk is so full of broken sectors now that I hardly can copy anything from it)
Btw, I suspect this is the reason that my migration method failed - the old disk contained too much broken data, and that caused "sh", "init" or similar to stop working.
New install, heere I come :/
|
|
|
All times are GMT -5. The time now is 02:02 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|