Difference between revisions of "Upgrade Path"

From ArchWiki
Jump to: navigation, search
(Massive page overhaul)
m (grammar)
(7 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
[[Category:System administration]]
 
[[Category:System administration]]
{{Stub|Incomplete article}}
+
{{Warning|It is ''strongly advised'' to avoid the {{ic|--force}} switch as it is not safe. This will seriously break your system, especially for the {{ic|/lib}} update.}}
  
Collected here is an upgrade path from approximately <date unknown> to a up-to-date archlinux system.
+
{{Note|[[mkinitcpio]] can fail during a kernel install, especially after a lengthy delay in updating. If it fails run it again manually before updating or the system will fail to boot}}
  
{{Warning|It is ''strongly advised'' to avoid the {{ic|--force}} switch as it is not safe. This will seriously break your system, especially for the {{ic|/lib}} update.}}
+
{{Note|Remember to deal with [[Pacnew and Pacsave Files]] after upgrading.}}
  
Remember to deal with [[Pacnew and Pacsave Files]] after upgrading.
+
Archlinux upgrades occasionally require manual intervention to complete. While its best practise to regularly update an archlinux installation, sometimes this isn't possible and upgrading a system can be complicated by multiple simultaneous conflicting updates, especially since conflicts can interact with each other. Collected here are detailed instructions to bring old machines from various points of time up to date.
  
 
= Timeline =
 
= Timeline =
  
The timeline of recent breaking changes detailed here:
+
The timeline of recent breaking changes detailed on this page:
  
 
* '''2012-11-04''' [https://www.archlinux.org/news/end-of-initscripts-support/ End of initscripts support]
 
* '''2012-11-04''' [https://www.archlinux.org/news/end-of-initscripts-support/ End of initscripts support]
Line 20: Line 20:
 
= End of initscripts support =
 
= End of initscripts support =
  
As {{ic|systemd}} is now the default init system, Arch Linux is receiving minimal testing on {{ic|initscripts}} systems. Due to a lack of resources and interest, we are unlikely to work on fixing {{ic|initscripts}}-specific bugs, and may close them as WONTFIX.
+
[[Systemd]] is now the default init system. Its strongly encourage for all users to migrate as soon as possible. Please refer to the [[Systemd]] page for more instructions.
 
+
We therefore strongly encourage all users to migrate to {{ic|systemd}} as soon as possible. See the [https://wiki.archlinux.org/index.php/Systemd systemd migration guide].
+
 
+
To ease the transition, {{ic|initscripts}} support will remain in the official repositories for the time being, unless otherwise stated. As of January 2013, we will start removing {{ic|initscripts}} support (e.g., {{ic|rc}} scripts) from individual packages without further notice.
+
  
 
= Fontconfig 2.10.1 update =
 
= Fontconfig 2.10.1 update =
Line 51: Line 47:
  
 
   cd /etc/fonts/conf.d
 
   cd /etc/fonts/conf.d
   ln -s ../conf.avail/XX-foo.conf</pre>
+
   ln -s ../conf.avail/XX-foo.conf
  
 
For more information, refer to [https://wiki.archlinux.org/index.php/Font_Configuration Font Configuration] and [https://wiki.archlinux.org/index.php/Fonts Fonts].
 
For more information, refer to [https://wiki.archlinux.org/index.php/Font_Configuration Font Configuration] and [https://wiki.archlinux.org/index.php/Fonts Fonts].
Line 79: Line 75:
 
   pacman -S filesystem
 
   pacman -S filesystem
  
Then reboot the system before continuing along with the upgrade.  
+
Then reboot the system before continuing along with the upgrade.
  
Upgrading while running a kernels prior to {{ic|linux-3.4}} will get a warning about permissions on {{ic|/sys}}. This is nothing to worry about, as of {{ic|linux-3.4}} the permissions will be {{ic|555}}, and this upgrade reflects this in the {{ic|filesystem}} package.
+
If upgrading while running a kernel prior to {{ic|linux-3.4}}, you will get a warning about permissions on {{ic|/sys}}. This is nothing to worry about; as of {{ic|linux-3.4}}, the permissions will be {{ic|555}}, and this upgrade reflects this in the {{ic|filesystem}} package.
  
 
== Conflict with mtab ==
 
== Conflict with mtab ==
  
The file {{ic|/etc/mtab}} used to be generated at boot and hence was owned by any package. Now it is a symlink to {{ic|/proc/self/mounts}} owned by {{ic|filesystem}}. This change means that {{ic|initscripts}} no longer requires write access to the rootfs (though other packages might).
+
The file {{ic|/etc/mtab}} used to be generated at boot and hence was not owned by any package. Now it is a symlink to {{ic|/proc/self/mounts}} owned by {{ic|filesystem}}. This change means that {{ic|initscripts}} no longer requires write access to the rootfs (though other packages might).
  
However following the instructions on the news, while sufficiently for dealing with this conflict at the time, will now interact with later {{ic|filesystem}} update. To upgrade do
+
However, following the instructions in the news, while sufficient for dealing with this conflict at the time, will now interact with later {{ic|filesystem}} update. To upgrade do
  
 
   pacman -Sy
 
   pacman -Sy
Line 93: Line 89:
 
   rm -r /var/{lock,run} /etc/mtab
 
   rm -r /var/{lock,run} /etc/mtab
  
Now you'll to comment out {{ic|CheckSpace}} in {{ic|/etc/pacman.conf}} as pacman needs to access {{ic|/etc/mtab}} to enable this feature. It is highly recommended to enable to restore it after dealing with the conflict.
+
Now you'll need to comment out {{ic|CheckSpace}} in {{ic|/etc/pacman.conf}} as pacman needs to access {{ic|/etc/mtab}} to enable this feature. It is highly recommended to re‐enable it after dealing with the conflict.
  
 
   pacman -S filesystem
 
   pacman -S filesystem
  
And then reboot the system before continuing along with the upgrade like described in the pervious section.
+
And then reboot the system before continuing along with the upgrade as described in the previous section.

Revision as of 13:58, 29 May 2013

Warning: It is strongly advised to avoid the --force switch as it is not safe. This will seriously break your system, especially for the /lib update.
Note: mkinitcpio can fail during a kernel install, especially after a lengthy delay in updating. If it fails run it again manually before updating or the system will fail to boot
Note: Remember to deal with Pacnew and Pacsave Files after upgrading.

Archlinux upgrades occasionally require manual intervention to complete. While its best practise to regularly update an archlinux installation, sometimes this isn't possible and upgrading a system can be complicated by multiple simultaneous conflicting updates, especially since conflicts can interact with each other. Collected here are detailed instructions to bring old machines from various points of time up to date.

Timeline

The timeline of recent breaking changes detailed on this page:

End of initscripts support

Systemd is now the default init system. Its strongly encourage for all users to migrate as soon as possible. Please refer to the Systemd page for more instructions.

Fontconfig 2.10.1 update

The fontconfig 2.10.1 update overwrites symlinks created by the former package version. These symlinks need to be removed before the update:

 rm /etc/fonts/conf.d/20-unhint-small-vera.conf
 rm /etc/fonts/conf.d/20-fix-globaladvance.conf
 rm /etc/fonts/conf.d/29-replace-bitmap-fonts.conf
 rm /etc/fonts/conf.d/30-metric-aliases.conf
 rm /etc/fonts/conf.d/30-urw-aliases.conf
 rm /etc/fonts/conf.d/40-nonlatin.conf
 rm /etc/fonts/conf.d/45-latin.conf
 rm /etc/fonts/conf.d/49-sansserif.conf
 rm /etc/fonts/conf.d/50-user.conf
 rm /etc/fonts/conf.d/51-local.conf
 rm /etc/fonts/conf.d/60-latin.conf
 rm /etc/fonts/conf.d/65-fonts-persian.conf
 rm /etc/fonts/conf.d/65-nonlatin.conf
 rm /etc/fonts/conf.d/69-unifont.conf
 rm /etc/fonts/conf.d/80-delicious.conf
 rm /etc/fonts/conf.d/90-synthetic.conf
 pacman -Sy fontconfig

Main systemwide configuration should be done by symlinks (especially for autohinting, sub-pixel and lcdfilter):

 cd /etc/fonts/conf.d
 ln -s ../conf.avail/XX-foo.conf

For more information, refer to Font Configuration and Fonts.

The /lib directory becomes a symlink

All Arch Linux packages have had their files in the /lib directory moved to /usr/lib and now /lib is a symlink to usr/lib. When performing this update, pacman will likely identify a conflict in the /lib directory. In the simplest case, this is worked around by doing:

Instructions for dealing with this update have been enumerated here. Please read this page very carefully before proceeding.

https://wiki.archlinux.org/index.php/DeveloperWiki:usrlib

Upgrading Filesystem

Upgrading the filesystem package can get tricky since there are several different breaking changes that may have accumulated over time that somewhat interact with each other. Pick the section below that best describes the conflict you see for instructions to bring the filesystem package up to date.

Symlinks to /run and /run/lock

As of filesystem-2012.6-2 the folders /var/run and /var/lock will be replaced by symlinks to /run and /run/lock, respectively.

On most systems this is already the case, as initscripts create the symlinks on boot. However, these symlinks are not owned by any package, which is what we are fixing with this upgrade.

If the symlinks are already in place on your system (which should be the case for most people), then you can simply perform:

 pacman -Sy
 rm -r /var/{lock,run} /etc/profile.d/locale.sh
 pacman -S filesystem

Then reboot the system before continuing along with the upgrade.

If upgrading while running a kernel prior to linux-3.4, you will get a warning about permissions on /sys. This is nothing to worry about; as of linux-3.4, the permissions will be 555, and this upgrade reflects this in the filesystem package.

Conflict with mtab

The file /etc/mtab used to be generated at boot and hence was not owned by any package. Now it is a symlink to /proc/self/mounts owned by filesystem. This change means that initscripts no longer requires write access to the rootfs (though other packages might).

However, following the instructions in the news, while sufficient for dealing with this conflict at the time, will now interact with later filesystem update. To upgrade do

 pacman -Sy
 pacman -S initscripts
 rm -r /var/{lock,run} /etc/mtab

Now you'll need to comment out CheckSpace in /etc/pacman.conf as pacman needs to access /etc/mtab to enable this feature. It is highly recommended to re‐enable it after dealing with the conflict.

 pacman -S filesystem

And then reboot the system before continuing along with the upgrade as described in the previous section.