Commit e194a7a7 authored by Tollef Fog Heen's avatar Tollef Fog Heen
Browse files

Don't migrate /var/run to a symlink if /run is a symlink

parent 06ac2c47
......@@ -15,6 +15,8 @@ systemd (43-1) experimental; urgency=low
* Install a tmpfiles.d file for the /dev/initctl → /run/initctl
migration. Closes: #657979
* Disable coredump handling, it's not ready yet.
* If /run is a symlink, don't try to do the /var/run → /run migration.
Ditto for /var/lock → /run/lock. Closes: #647495
[ Michael Biebl ]
* Add Build-Depends on liblzma-dev for journal log compression.
......
......@@ -5,12 +5,22 @@ set -e
if [ ! -L /etc/mtab ]; then
ln -sf /proc/mounts /etc/mtab
fi
# Migrate /var/run to be a symlink to /run, unless /run is already a
# symlink, to prevent loops.
if [ ! -L /var/run ]; then
rm -rf /var/run
ln -s /run /var/run
if [ ! -L /run ]; then
rm -rf /var/run
ln -s /run /var/run
fi
fi
# Migrate /var/lock to be a symlink to /run/lock, unless /run/lock is
# already a symlink, to prevent loops.
if [ ! -L /var/lock ]; then
rm -rf /var/lock
ln -s /run/lock /var/lock
if [ ! -L /run/lock ]; then
rm -rf /var/lock
ln -s /run/lock /var/lock
fi
fi
exit 0
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment