Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
What Needs To Be Changed After Cloning A System? [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
fredbear5150
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2003
Posts: 76

PostPosted: Wed Dec 24, 2014 6:49 pm    Post subject: What Needs To Be Changed After Cloning A System? [SOLVED] Reply with quote

I have two near-identical HP PCs (the only difference are the hard disk manufacturers although disk and partition sizes are identical across the two of them) so I did a scratch build on one (PC 1) and then cloned the build to the second PC (PC 2).

I now have some weird problems on PC 2. I use LightDM and MATE as my display manager and desktop environment respectively. On PC 2, it boots fine, the LightDM background appears but it takes about 30 seconds before the user list and login prompt appears. After logging is as my normal user, it takes about 30 seconds for the MATE menu bar to appear. I also cannot launch a mate-terminal from the icon, it indicates it is starting on the window bar but never opens.

I have already changed the IP addresses and hostname of the new system, the correct hostname appears at the login prompt.

I cloned the system using rsync from PC2 on a Gentoo Live CD, PC1 was booted normally. I excluded the /proc, /sys, /dev and /tmp directories, I used the following command to clone:

rsync -aHxv root@192.168.1.10:/* /mnt/gentoo --exclude=/dev --exclude=/proc --exclude=/sys --exclude=/tmp

In other cloning tutorials on the web I've seen that both PCs are booted from Live CDs before cloning, is that a better way to do it? Have I possibly copied across something that was cached for PC1 onto PC2? I use OpenRC and consolekit, I don't use Systemd.

Any suggestions?


Last edited by fredbear5150 on Thu Dec 25, 2014 12:04 am; edited 1 time in total
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 43178
Location: 56N 3W

PostPosted: Wed Dec 24, 2014 8:14 pm    Post subject: Reply with quote

fredbear5150,

Cloning a live root filesystem usually gives problems due to files being open for writing.
As well as the things you have already changed, you need to change the clones ssh fingerprint.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5760

PostPosted: Wed Dec 24, 2014 8:35 pm    Post subject: Reply with quote

You should also `rm /etc/machine-id; dbus-uuidgen --ensure` if you use any programs that depend on dbus, especially networked ones.
Back to top
View user's profile Send private message
fredbear5150
Tux's lil' helper
Tux's lil' helper


Joined: 11 Oct 2003
Posts: 76

PostPosted: Thu Dec 25, 2014 12:04 am    Post subject: Reply with quote

Ant P. / NeddySeagoon

Thanks to both of you for your help, I got the clone working perfectly.

I booted both PCs from the Gentoo Live CD and did an rsync over SSH, I also ran the commands you mentioned and deleted existing SSH keys.

Obviously I changed hostname and (fixed) IP address, it all worked perfectly first time
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum