Bug#851427: sysvinit makes /dev/shm a symlink to /run/shm, should be other way round

Dmitry Bogatov KAction at debian.org
Sat Jan 12 12:41:38 GMT 2019

[ Please, next time attach patch, not whole file. Much more convenient
  for review ]

[2019-01-10 10:54] Dolphin Oracle <dolphinoracle at gmail.com>
> the buster version of sysvinit initscripts still mounts the with /run/shm
> as the mount point for the tmpfs and /dev/shm as a symlink.
> just adding on to the discussion...the situation actually prevents running
> certain flatpak applications.
> modifying mount-functions.sh per the attached will reverse the situation,

Works fine to me, I intend to accept it. Dear co-maintainers,
any objections?

> although there is still some migration code in there that strictly speaking
> isn't necessary.

Further patches are welcome. Just remember, that not only fresh installs
must work fine, but also upgrade from stable must be smooth and painless.

Here is patch for convenience of other developers:

diff --git a/debian/src/initscripts/lib/init/mount-functions.sh b/debian/src/initscripts/lib/init/mount-functions.sh
index 7511761c..98f53a86 100644
--- a/debian/src/initscripts/lib/init/mount-functions.sh
+++ b/debian/src/initscripts/lib/init/mount-functions.sh
@@ -436,7 +436,7 @@ post_mountall ()
 	# directory.  The migration logic will then take care of the
 	# rest.  Note that it will take a second boot to fully
 	# migrate; it should only ever be needed on broken systems.
 	if read_fstab_entry "/dev/shm"; then
@@ -559,8 +559,8 @@ mount_shm ()
-	SHMDIR="/run/shm"
+	SHMDIR="/dev/shm"
 	if read_fstab_entry "/dev/shm"; then
 		if [ "$MNTMODE" = "mount_noupdate" ]; then
 			log_warning_msg "Warning: fstab entry for /dev/shm; should probably be for /run/shm unless working around a bug in the Oracle database"
@@ -706,13 +706,3 @@ is_fastboot_active() {
 	return 1

More information about the Debian-init-diversity mailing list