[SOLVED] Moving root partition from /dev/sda to /dev/vda
SlackwareThis Forum is for the discussion of Slackware Linux.
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.
I have a slackware 14.1 guest that I use with qemu/kvm. I installed it using a normal harddrive which shows up as /dev/sda, but now I want to convert it. When I connect it as a virtio harddrive it shows up as /dev/vda.
I tried the following to convert the slackware installation. I booted with the livecd, mounted the harddrive at /mnt, set up bind mounts, and chrooted into /mnt.
Then I created an initrd image where I load virtio, virtio_blk and virtio_mmio drivers. I also make sure that initrd root is correct (/dev/vda2). I get no errors. Then I add initrd entry to /etc/lilo.conf and install lilo again with -b /dev/vda switch. I have also changed fstab to point to /vda instead of /sda.
When I try to boot with my new config I get the following errors:
no kernel modules found for linux 3.10.17-smp
mounting /dev/vda2 to /mnt failed
no /sbin/init found on rootdev.
When the boot process halts I get access to a shell where I can move around in initrd. Since the initrd image is on /dev/vda it seems like it's possible read /dev/vda despite the fact that no modules are loaded.
Any ideas?
Last edited by insectiod; 08-23-2014 at 10:20 AM.
Reason: make title less confusing
Distribution: Ubuntu 11.4,DD-WRT micro plus ssh,lfs-6.6,Fedora 15,Fedora 16
Posts: 3,233
Rep:
maybe you should use UUID instead of raw device node? if you can access the system and run blkid (as root) on /dev/vda2 (are you sure it's /dev/vda2 and not /dev/vda1 ?) and replace /dev/vdaX with UUID={uuid} in the FSTAB maybe you will have better luck.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.