Okay, so, I’ve got my ArchLinux installed on my HP EliteBook 8570w. I wish have the same installation on my HP EliteBook 8530w. The way to go, just make a copy of the root file system and put it on the other machine.
cd / tar --one-file-system -avpcf /mnt/usb-hard-disk/arch-rootfs-running.tar.xz .
Then boot up the other system, in UEFI mode, from the ArchLinux USB Flash stick, and follow UEFI installation guide up to and including formatting the partitions. (See also my previous post: UEFI Installation guide. Then, in stead of pacstrapping, we’re going to insert the usb-hard-disk where we made a tarball and extract it to the root file system partition.
mkdir /mnt/{hd,usb} mount /dev/sda3 /mnt/hd mount /dev/sdc1 /mnt/usb cd /mnt/hd tar -xvpf /mnt/usb/arch-rootfs-running.tar.xz
Now, we have a “clone” of the installation of the other machine. A few system specific stept must be performed to make this system ready for use. First, I will arch-chroot into the system:
arch-chroot /mnt/hd
I will set the hostname for this laptop
echo 8530w > /etc/hostname
I will remove the graphics card specific patch (See Glamot Acceleration Problems)
rm /etc/X11/xorg.conf.d/20-radeon
I will remove the ssh keys, such that a new keypair will be generated. The same keys on two machines is a no-go
cd /etc/ssh rm *key*
Another thing that must be done is generating a new fstab, as we have formatted new partitions, their UUID will be different. It is unique after all. (I am overwriting the file. I will re-add the NFS mounts later)
mount /dev/sda1 /boot/efi mount /dev/sda4 /home swapon /dev/sda2 genfstab -U -f / > /etc/fstab
And finally, setting up the boot loader
grub-install –target=x86_64-efi –efi-directory=/boot/efi –bootloader-id=grub grub-mkconfig > /boot/grub/grub.cfg
Which works fine on this laptop. The other laptop had an issue with efibootmgr.
However, the system boots up into an emergency console. Looking at the fstab generated, it had some weird entry causing the problem:
/etc/resolv.conf/etc/resolv.conf /etc/resolv.conf none rw,relatime,bind 0 0
Which is probably a remains from the booting from installation media and using the genfstab inside the arch-chroot, in stead of before.
Just removing the entry solves the problem, and then the system just boots up to the login prompt.
But, we’re not done yet. I have cloned the root file system, and not the home partition, Which means, there will be no home directory for my user.
so, log in as root,
mkdir /home/andre chown andre:users /home/andre
Then, I can log out as root and log in as myself.
Just for convinience, I’ll copy some files from my other laptop’s home directory over:
scp -r 8570w:.config . scp -r 8570w:.thunderbird . scp -r 8570w:.mozilla .
The xfce4-cpufreq-plugin
didn’t really like this operation, but removing and re-adding it makes everything work. Also, I have to add the temperature monitor for the GPU again.
« Computers, CPU’s, Motherboards, upgrade aborted. A WWAN (3G) module for my EliteBook 8530w »
1 Trackback or Pingback for this entry:
[…] I have recently bought a new computer. As my default operating system, I use ArchLinux. Simply boot from a running USB stick, and copy the content over. I have explained the procedure before. […]