Who's good in copying an installed distro from one HDD to another HDD?
Hello,
I always use 2 identical HDDs in order to keep a true backup of my installed distro (all partitions) in case of a failure. Such failure occurred recently and I was left with one HDD. So I bought 2 new, bigger than my originals. I changed the partition sizes on the new HDDs and my root partition is now smaller. So I try to migrate my installed Kubuntu 11.10 from my old backup HDD (primary failed) to my new primary bigger HDD (under a smaller partition than original HDD). In order to copy my partitions I use Code:
sudo cp -ax /[partition_on_old_disk]/* /[partition_on_new_disk]/ I seemed it copied everything with file attributes and whatnots. Then I changed my grub config in order to support and boot from the new disk. And lastly I booted using the new disk. GRUB (legacy) loaded no problem, my menu entry was there and it did start up the kernel perfectly. But in verbose mode I could see it was performing clean-ups especially on /tmp, not sure that was normal. And at the point of loading XServer, kaboom. Reverted to text mode. I logged in under my user, tried to troubleshoot. I noticed /tmp was all empty, it deleted everything during the boot process. I then did Code:
startx I also tried by copying /tmp content from my old disk to my new disk while I was in txt mode and I get the same XServer errors. Here's the Xorg log file from the point where it starts to do stuff (skipped the help listing): Code:
[ 140.351] Anyone has an idea? My extended partition wasn't flagged as 'LBA', could that be the problem? I'll give a shot later on. Here are my sfdidk of both drives: Old working one: Code:
Disk /dev/sda: 91201 cylinders, 255 heads, 63 sectors/track Code:
Disk /dev/sdb: 121601 cylinders, 255 heads, 63 sectors/track tnx! |
Did you also change /etc/fstab?
If not, you boot up with one partition for / but then switch to another. That could cause problems. Abouth that "partitions weren't ending on the physical block", it's not an issue. This is caused by the way large disks are handled today, earlier a partition had to end on "cylinder boundary". Could you also post your /etc/fstab from both installations. |
Quote:
Quote:
I am now changing my user permissions on /tmp, which has root all over the place at the moment. Since my other disk is disconnected, I cannot check if it should be root or user. No harm to try. Quote:
EDIT: fstab of new disk (old one still not connected as I am trying to figure out if it's a permission issue on the new disk): Code:
# /etc/fstab: static file system information. Old working disk's fstab: Code:
# /etc/fstab: static file system information. |
Hey that partially worked!!
/tmp now has user:user as permissions, I did not change recursively, only the root of /tmp and it works! Interesting, I can't wait to check if I have root or user permissions on that folder on my old disk. /home remains with root permissions and it loads fine. But /tmp needed to be set to user. However when I reboot and let it load by itself it still doesn't load X. But I can load it manually after I login from text mode. weird... |
I checked my /tmp, it has drwxrwxrwt so everybody has full permissions + sticky bit is set.
Are all your partitions the same file system? If not, defaults for mounting might be different. When booting, check the logs - mainly /var/log/Xorg.0.log but also /var/log/messages and "dmesg" (all this taken from my LinuxMint13). |
Quote:
It looks like KDM doesn't load. When I get prompted to tty1, I log in, then startx, it bypasses KDM log in screen. There is no messages file in /var/log. No errors in Xorg.0.log. dmesg doesn't show anything weird to my eye. I will post it. |
dmesg is too big to post, so I have shorten it at the beginning:
Code:
[ 0.847799] udevd[90]: starting version 173 |
What was the first error - the one that made you try to recover from the backup?
A real shot in the dark - what about AppArmor, could it be that it doesn't like the change of partitions? What dm is loading at bootup - kdm, gdm, xdm... ? Check if it's started at bootup (probably not), can you start it manually from terminal as root? --- Edit: Ah, it's kdm (of course - it's kubuntu!) Sorry for my ignorance. |
Quote:
Code:
[ 141.095] (II) XKB: generating xkmfile /tmp/server-B20D7FC79C7F597315E3E501AEF10E0D866E8E92.xkm I don't think I have AppArmor, I'll check that. KDM seems to be running, you're right. Code:
sudo service kdm start EDIT: I do have AppArmor, but don't know how to load it or troubleshoot it. |
You do have Apparmor, it's in dmesg.
But skip that for now, I don't really believe it's causing the problem. Now the first error, could it be caused by /tmp partition being full? Seems to me it's exactly the same error as the one you get when booting from backup. What if X / kdm actually works but is loaded on other teminal? That has happened to me with LinuxMint. Try switching to tty6, tty8 and tty9 (that's hitting <Ctrl>+<Alt>+<F8> etc - just in case you don't already know). --- Edit Also, in terminal kill kdm and start it again. Any more specific error messages? If that doesn't give anything, you could try reinstalling kdm. |
Quote:
I have uninstalled AppArmor and same problem, so that's not it. ctrl-alt-F8 does nothing. ctrl-alt-F7 switches to some verbose mode of stuff which loaded before, then I did a ctrl-alt-f6 to come back. I'll try reinstalling KDM, hoping I won't get hit with newer KDM versions which would require new KDE version which then impacts everything else. :) |
Quote:
Careful now, THINK before you act! It's your system not mine, I can just guess... ---------- Post added 9th Mar 2013 at 20:31 ---------- Start with killing kdm and start it again,see what error message you get. |
Absolutely. Since I have a working system on my other disk, I can screw that one up it doesn't work.
Uninstalling it was easy. Reinstalling was harder, but after a while I found only a few packages to be upgraded and only KDM to be installed. Didn't think about killing it and restarting it first. :( Ok same problem. I have stopped it and restarted it. I see it tries to load the screen, but fails and reverts back to tty6. No error in Xorg.0.log, nothing in dmesg either. startx works as the usual. Well, I guess I'll wait for Kubuntu 13.04 and reinstall from scratch. Or in the meantime I can startx manually all the time, which is usually once a week after I have backed up my root partition with g4l. Feel free if you have any idea, otherwise thanks so much for the time, I progressed but didn't find it. :) |
Maybe install some other dm instead, like xdm or mdm.
It might pull down some other stuff as well but it will not affect your KDE. |
Quote:
|
All times are GMT -5. The time now is 04:50 AM. |