Difference between revisions of "Migrate installation to new hardware"
m (<tt>text</tt> -> {{Codeline|text}}) |
m (grammar mistakes) |
||
(8 intermediate revisions by 5 users not shown) | |||
Line 1: | Line 1: | ||
− | [[Category:Getting and installing Arch | + | [[Category:Getting and installing Arch]] |
− | [[Category:System recovery | + | [[Category:System recovery]] |
{{Stub}} | {{Stub}} | ||
This page summarizes some hints and ideas (especially handy commands) useful when moving an Arch Linux system to new hardware. The goal is to achieve the same ArchLinux installation, as far as software and configuration is concerned, but also to clean config files and to update to more recent techniques. | This page summarizes some hints and ideas (especially handy commands) useful when moving an Arch Linux system to new hardware. The goal is to achieve the same ArchLinux installation, as far as software and configuration is concerned, but also to clean config files and to update to more recent techniques. | ||
Line 18: | Line 18: | ||
==== Copy to some backup space. ==== | ==== Copy to some backup space. ==== | ||
− | * You can consider backing up /var/cache/pacman/pkg if you | + | * You can consider backing up /var/cache/pacman/pkg if you do not go from x86 to x86_64 |
− | * /etc should be | + | * /etc should be backed up, in order to peek if necessary. |
=== On the new system === | === On the new system === | ||
Line 65: | Line 65: | ||
*initially the Fallback image could work | *initially the Fallback image could work | ||
*regenerate image | *regenerate image | ||
− | ** | + | **mkinitcpio -p linux |
− | |||
=== Update the graphic drivers === | === Update the graphic drivers === | ||
Line 80: | Line 79: | ||
**/etc/hosts | **/etc/hosts | ||
**other apps using hostname: synergy, nut (network ups tools) | **other apps using hostname: synergy, nut (network ups tools) | ||
− | ***"{{ | + | ***"{{Ic|# grep -Ri 'hostname' /etc}}" should give some hints on the files to be updated |
== See also == | == See also == | ||
*[[Disk Cloning]] | *[[Disk Cloning]] | ||
*[[Migrating Between Architectures Without Reinstalling]] | *[[Migrating Between Architectures Without Reinstalling]] | ||
− | *[[ | + | *[[Moving an existing install into (or out of) a virtual machine]] |
Revision as of 14:36, 12 December 2012
This page summarizes some hints and ideas (especially handy commands) useful when moving an Arch Linux system to new hardware. The goal is to achieve the same ArchLinux installation, as far as software and configuration is concerned, but also to clean config files and to update to more recent techniques.
Basically, there are two ways:
- Bottom to Top: Install a fresh Arch Linux system on the new hardware, and try to install and configure all packages from the old.
- Top to Bottom: Bitwise copy the old partitions to the new system, trying to get the kernel working without forgetting some tweaks.
Which way you choose depends heavily on how the new system differs from your old and how exactly you want to reproduce the system.
Warning: Some of the following instructions can be dangerous: you are advised to backup all of your important data on the old system before continuing.
Contents
Bottom to Top
On the old system
What software?
$ pacman -Qqe | grep -vx "$(pacman -Qqm)" > Packages $ pacman -Qqm > Packages.aur
gives you a nice list of explicitly installed packages. Don't forget the software not installed through pacman.
Copy to some backup space.
- You can consider backing up /var/cache/pacman/pkg if you do not go from x86 to x86_64
- /etc should be backed up, in order to peek if necessary.
On the new system
Wiki articles
- Read some Wiki articles concerning new hardware, for examples your new SSD.
- Stick to the well-written installation guidelines here in this wiki. Since you are experienced, the Quick_Arch_Linux_Install could be enough.
- Try to configure as much as possible sticking to current wiki articles and forum posts.
Copy from backup space
- Copy the pacman cache to var/cache/pacman/pkg
- Don't forget to edit /etc/pacman.d/mirrorlist
Install software
As root, grab a cup of coffee and execute:
# xargs -a Packages pacman -S --noconfirm --needed
Top to Bottom
- See these forum threads:
Move the system to the new HDDs
Note: If you are planning to keep the hard drive where the system is already installed, you can skip this section.
- connect origin and destination HDDs to the same pc (either the old or the new one) and copy the filesystem(s)
- copy the filesystem(s) using temporary storage devices (external HDDs, DVDs...)
- transfer over network (using a live system on the new pc?)
- consider that you might need adapters (PATA->SATA, USB-HDD-Cases, etc.) and choose a fast connection (or prepare for long copy times)
- command for making an identical copy of the original filesystem: see Disk Cloning
Update fstab
- using /dev paths: this should change depending on how the new drives are connected to the mainboard, on the BIOS and on the new partitions scheme
- using fs labels: should be safe
- using UUIDs
Reconfigure the bootloader
- because of:
- new HDD and partitions configuration
- new BIOS configuration
- GRUB allows to edit entries with 'e'
- use a live system?
- update framebuffer mode (if new gpu)
Regenerate kernel image
- initially the Fallback image could work
- regenerate image
- mkinitcpio -p linux
Update the graphic drivers
- if changed driver (e.g. from ATI to NVIDIA) can uninstall the old drivers
Reconfigure audio
- alsamixer volume
- save settings
Reconfigure network
- if need to change hostname:
- /etc/rc.conf
- /etc/hosts
- other apps using hostname: synergy, nut (network ups tools)
- "
# grep -Ri 'hostname' /etc
" should give some hints on the files to be updated
- "