Your message dated Sat, 01 Feb 2014 23:04:09 +0000
with message-id <[email protected]>
and subject line Bug#721917: fixed in sysvinit 2.88dsf-46
has caused the Debian Bug report #721917,
regarding Patches fixing sysvinit issues on Debian/Hurd
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
721917: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=721917
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: sysvinit
Version: 2.88dsf-43
Severity: wishlist
Tags: patch
Usertags: hurd

Dear maintainer :)

This is a patch series fixing sysvinit issues on Debian/Hurd *without*
actually switching to sysvinit as init system on Debian/Hurd as this
requires a rebuilt hurd package with recently implemented
functionality.

Thanks,
Justus
From 66a3c62db00e01ff894c7d63bf9182e1a4f2700c Mon Sep 17 00:00:00 2001
From: Justus Winter <[email protected]>
Date: Mon, 8 Jul 2013 11:41:33 +0200
Subject: [PATCH 1/6] initscripts: hurd has a proper tmpfs now, remove
 workaround

---
 debian/changelog                                   |    7 +++++++
 debian/src/initscripts/lib/init/mount-functions.sh |    1 -
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index bbd42d0..573add9 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,10 @@
+sysvinit (2.88dsf-44) UNRELEASED; urgency=low
+
+  [ Justus Winter ]
+  * mount-functions.sh: Hurd has a tmpfs translator now, remove workaround.
+
+ -- Justus Winter <[email protected]>  Thu, 05 Sep 2013 15:10:39 +0200
+
 sysvinit (2.88dsf-43) unstable; urgency=low
 
   [ Roger Leigh ]
diff --git a/debian/src/initscripts/lib/init/mount-functions.sh b/debian/src/initscripts/lib/init/mount-functions.sh
index 9fd369b..5126780 100644
--- a/debian/src/initscripts/lib/init/mount-functions.sh
+++ b/debian/src/initscripts/lib/init/mount-functions.sh
@@ -190,7 +190,6 @@ domount () {
 	elif [ "$PRIFSTYPE" = tmpfs ]; then
 		# always accept tmpfs, to mount /run before /proc
 		case "$KERNEL" in
-			GNU)	FSTYPE=none ;; # for now
 			*)	FSTYPE=$PRIFSTYPE ;;
 		esac
 	elif grep -E -qs "$PRIFSTYPE\$" /proc/filesystems; then
-- 
1.7.10.4

From b9b81e6c1f2fa67ccb90b5341728b2da02d476d6 Mon Sep 17 00:00:00 2001
From: Justus Winter <[email protected]>
Date: Mon, 8 Jul 2013 12:40:09 +0200
Subject: [PATCH 2/6] initscripts: add -ocompatible to procfs mounts on Hurd

---
 debian/changelog                                   |    1 +
 debian/src/initscripts/lib/init/mount-functions.sh |    3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 573add9..29257ab 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,7 @@ sysvinit (2.88dsf-44) UNRELEASED; urgency=low
 
   [ Justus Winter ]
   * mount-functions.sh: Hurd has a tmpfs translator now, remove workaround.
+  * mount-functions.sh: Add -ocompatible to procfs mounts on Hurd.
 
  -- Justus Winter <[email protected]>  Thu, 05 Sep 2013 15:10:39 +0200
 
diff --git a/debian/src/initscripts/lib/init/mount-functions.sh b/debian/src/initscripts/lib/init/mount-functions.sh
index 5126780..8bb3031 100644
--- a/debian/src/initscripts/lib/init/mount-functions.sh
+++ b/debian/src/initscripts/lib/init/mount-functions.sh
@@ -176,7 +176,8 @@ domount () {
 
 	if [ "$PRIFSTYPE" = proc ]; then
 		case "$KERNEL" in
-			Linux|GNU) FSTYPE=proc ;;
+			Linux)     FSTYPE=proc ;;
+			GNU)       FSTYPE=proc; FS_OPTS="-ocompatible" ;;
 			*FreeBSD)  FSTYPE=linprocfs ;;
 			*)         FSTYPE=procfs ;;
 		esac
-- 
1.7.10.4

From b177429374e6c460d734124ddfeb45e6d39655ff Mon Sep 17 00:00:00 2001
From: Justus Winter <[email protected]>
Date: Mon, 8 Jul 2013 12:48:42 +0200
Subject: [PATCH 3/6] initscripts: use pidof -s /sbin/init for robustness

pidof -s returns the first matching process. Since readdir(2) on
procfs returns the processes in ascending order, this returns the
first process. This is more robust if there is more than one
/sbin/init process.

Currently on Hurd there are two /sbin/init processes. Clearly this
needs some investigation. But as far as I can tell this could also
happen if INITDEBUG is defined as /sbin/init then forks a child that
can be ptrace(2)d on a vanilla Linux kernel.
---
 debian/changelog                              |    1 +
 debian/src/initscripts/etc/init.d/mountall.sh |    2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 29257ab..49afbed 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -3,6 +3,7 @@ sysvinit (2.88dsf-44) UNRELEASED; urgency=low
   [ Justus Winter ]
   * mount-functions.sh: Hurd has a tmpfs translator now, remove workaround.
   * mount-functions.sh: Add -ocompatible to procfs mounts on Hurd.
+  * mountall.sh: Use pidof -s /sbin/init for robustness.
 
  -- Justus Winter <[email protected]>  Thu, 05 Sep 2013 15:10:39 +0200
 
diff --git a/debian/src/initscripts/etc/init.d/mountall.sh b/debian/src/initscripts/etc/init.d/mountall.sh
index 5f913cd..392eeec 100755
--- a/debian/src/initscripts/etc/init.d/mountall.sh
+++ b/debian/src/initscripts/etc/init.d/mountall.sh
@@ -55,7 +55,7 @@ do_start() {
 		mknod -m 600 "$INITCTL" p
 
 		# Reopen control channel.
-		PID="$(pidof /sbin/init || echo 1)"
+		PID="$(pidof -s /sbin/init || echo 1)"
 		[ -n "$PID" ] && kill -s USR1 "$PID"
 	fi
 
-- 
1.7.10.4

From 4a58b5c18367c9f6e6491ec5060f8b3375219609 Mon Sep 17 00:00:00 2001
From: Justus Winter <[email protected]>
Date: Mon, 8 Jul 2013 18:35:44 +0200
Subject: [PATCH 4/6] initscripts: Only run rootcheck on Linux

Neither kFreeBSD nor Hurd have /dev/root and the device ids used here
are specific to Linux. Note that fsck is still run, rootcheck refers
to the check whether the root device in /etc/fstab matches the actual
device.
---
 debian/changelog                               |    2 ++
 debian/src/initscripts/etc/init.d/checkroot.sh |    6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index 49afbed..f8b8da1 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -4,6 +4,8 @@ sysvinit (2.88dsf-44) UNRELEASED; urgency=low
   * mount-functions.sh: Hurd has a tmpfs translator now, remove workaround.
   * mount-functions.sh: Add -ocompatible to procfs mounts on Hurd.
   * mountall.sh: Use pidof -s /sbin/init for robustness.
+  * checkroot.sh: Only run rootcheck on Linux. Neither kFreeBSD nor Hurd
+    have /dev/root and the device ids used here are specific to Linux.
 
  -- Justus Winter <[email protected]>  Thu, 05 Sep 2013 15:10:39 +0200
 
diff --git a/debian/src/initscripts/etc/init.d/checkroot.sh b/debian/src/initscripts/etc/init.d/checkroot.sh
index 05a3c96..61afa70 100755
--- a/debian/src/initscripts/etc/init.d/checkroot.sh
+++ b/debian/src/initscripts/etc/init.d/checkroot.sh
@@ -84,7 +84,11 @@ do_start () {
 	# If not we try to use the /dev/root alias device, and if that
 	# fails we create a temporary node in /run.
 	#
-	if [ "$rootcheck" = yes ]
+	# Do this only on Linux. Neither kFreeBSD nor Hurd have
+	# /dev/root and the device ids used here are specific to
+	# Linux.
+	KERNEL="$(uname)"
+	if [ "$rootcheck" = yes ] && [ "$KERNEL" = Linux ]
 	then
 		ddev="$(mountpoint -qx $rootdev)"
 		rdev="$(mountpoint -d /)"
-- 
1.7.10.4

From 75639b8760da7636518e9a3b255368545ca1bc1a Mon Sep 17 00:00:00 2001
From: Justus Winter <[email protected]>
Date: Mon, 8 Jul 2013 15:56:46 +0200
Subject: [PATCH 5/6] killall5.c: Use sysconf(_SC_SYMLOOP_MAX) instead of
 MAXSYMLINKS.

If sysconf returns an error, fall back to MAXSYMLINKS on platforms
that define it.

Fixes build on Hurd.
---
 debian/changelog |    2 ++
 src/killall5.c   |   15 ++++++++++++++-
 2 files changed, 16 insertions(+), 1 deletion(-)

diff --git a/debian/changelog b/debian/changelog
index f8b8da1..83cd26c 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,8 @@ sysvinit (2.88dsf-44) UNRELEASED; urgency=low
   * mountall.sh: Use pidof -s /sbin/init for robustness.
   * checkroot.sh: Only run rootcheck on Linux. Neither kFreeBSD nor Hurd
     have /dev/root and the device ids used here are specific to Linux.
+  * killall5.c: Use sysconf(_SC_SYMLOOP_MAX) instead of MAXSYMLINKS.
+    Fixes build on Hurd.
 
  -- Justus Winter <[email protected]>  Thu, 05 Sep 2013 15:10:39 +0200
 
diff --git a/src/killall5.c b/src/killall5.c
index 5937d98..2c9bb4f 100644
--- a/src/killall5.c
+++ b/src/killall5.c
@@ -367,13 +367,26 @@ out:
 }
 
 /*
+ *     Get the maximal number of symlinks to follow.
+ */
+static int maxsymlinks(void)
+{
+	int v = sysconf(_SC_SYMLOOP_MAX);
+#ifdef MAXSYMLINKS
+	if (v == -1)
+		return MAXSYMLINKS;
+#endif
+	return v;
+}
+
+/*
  *     Check path is located on a network based partition.
  */
 int check4nfs(const char * path, char * real)
 {
 	char buf[PATH_MAX+1];
 	const char *curr;
-	int deep = MAXSYMLINKS;
+	int deep = maxsymlinks();
 
 	if (!nlist) return 0;
 
-- 
1.7.10.4

From bb1362bd0487d76f5b4951161bf6134c2cf35160 Mon Sep 17 00:00:00 2001
From: Justus Winter <[email protected]>
Date: Mon, 8 Jul 2013 19:00:04 +0200
Subject: [PATCH 6/6] sysvinit: Fix getty path in /etc/inittab on Hurd.

This is essentially the same as
89f6476d8979174f395a1bf784486254464c349d but fixes the existing
/etc/inittab file in the postinstall script.
---
 debian/changelog          |    1 +
 debian/sysvinit.config    |   43 +++++++++++++++++++++++++++++++++++++++++++
 debian/sysvinit.postinst  |   13 +++++++++++++
 debian/sysvinit.templates |   15 +++++++++++++++
 4 files changed, 72 insertions(+)
 create mode 100755 debian/sysvinit.config
 create mode 100644 debian/sysvinit.templates

diff --git a/debian/changelog b/debian/changelog
index 83cd26c..ac37127 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -8,6 +8,7 @@ sysvinit (2.88dsf-44) UNRELEASED; urgency=low
     have /dev/root and the device ids used here are specific to Linux.
   * killall5.c: Use sysconf(_SC_SYMLOOP_MAX) instead of MAXSYMLINKS.
     Fixes build on Hurd.
+  * sysvinit.postinst: Fix file name of gettys in /etc/inittab on Hurd.
 
  -- Justus Winter <[email protected]>  Thu, 05 Sep 2013 15:10:39 +0200
 
diff --git a/debian/sysvinit.config b/debian/sysvinit.config
new file mode 100755
index 0000000..ce34f63
--- /dev/null
+++ b/debian/sysvinit.config
@@ -0,0 +1,43 @@
+#!/bin/sh
+# config script for sysvinit
+#
+# see: dh_installdeb(1)
+
+set -e
+
+. /usr/share/debconf/confmodule
+
+# summary of how this script can be called:
+#	 * <config> `configure' <installed-version>
+#	 * <config> `reconfigure' <installed-version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+case "$1" in
+    configure|reconfigure)
+
+	if [ "$(uname)" = GNU ]; then
+	    db_set sysvinit/hurd-fix-inittab "true"
+	    if echo '3e3693078d18d4696c83a76531433cd4  /etc/inittab' \
+		| md5sum --status --check -; then
+		    # The file is unmodified, update it silently.
+		    :
+	    elif fgrep -q '/libexec/getty' /etc/inittab; then
+		    db_input low sysvinit/hurd-fix-inittab || true
+		    db_go
+	    fi
+	fi
+    ;;
+
+    *)
+	echo "config script called with unknown argument \`$1'" >&2
+	exit 1
+    ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/sysvinit.postinst b/debian/sysvinit.postinst
index 1750412..d78fe86 100755
--- a/debian/sysvinit.postinst
+++ b/debian/sysvinit.postinst
@@ -5,6 +5,9 @@
 
 set -e
 
+# Source debconf library.
+. /usr/share/debconf/confmodule
+
 # Restart init, and migrate to /run/initctl if needed.
 do_restart() {
 	INITCTL=/run/initctl
@@ -83,6 +86,16 @@ rm -f /etc/ioctl.save
 if [ ! -f /etc/inittab ]
 then
 	cp -p /usr/share/sysvinit/inittab /etc/inittab
+elif [ "$(uname)" = GNU ] && fgrep -q '/libexec/getty' /etc/inittab; then
+	rm -f -- /etc/inittab.dpkg-new
+	sed -e '/^[^#]/ s|/libexec/getty|/sbin/getty|' \
+	    < /etc/inittab > /etc/inittab.dpkg-new
+
+	db_get sysvinit/hurd-fix-inittab
+	if [ "${RET}" = "true" ]; then
+		mv -- /etc/inittab /etc/inittab.dpkg-old
+		mv -- /etc/inittab.dpkg-new /etc/inittab
+	fi
 fi
 
 restart=yes
diff --git a/debian/sysvinit.templates b/debian/sysvinit.templates
new file mode 100644
index 0000000..935ae84
--- /dev/null
+++ b/debian/sysvinit.templates
@@ -0,0 +1,15 @@
+Template: sysvinit/hurd-fix-inittab
+Type: boolean
+_Description: Update getty file names in /etc/inittab?
+ Your /etc/inittab seems to use /libexec/getty as getty. The default
+ inittab has been changed, however your /etc/inittab has been
+ modified. Note that sysvinit has never been used to boot an Hurd
+ system, so any errors in that file would not have shown up.
+ .
+ Do you want me to change /etc/inittab to use /sbin/getty as getty?
+ .
+ If you choose yes, a backup will be stored in /etc/inittab.dpkg-old.
+ .
+ If you choose no, an updated inittab will be written to
+ /etc/inittab.dpkg-new. Please review the changes and update your
+ /etc/inittab accordingly.
-- 
1.7.10.4


--- End Message ---
--- Begin Message ---
Source: sysvinit
Source-Version: 2.88dsf-46

We believe that the bug you reported is fixed in the latest version of
sysvinit, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Petter Reinholdtsen <[email protected]> (supplier of updated sysvinit package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Format: 1.8
Date: Fri, 31 Jan 2014 20:48:39 +0100
Source: sysvinit
Binary: sysvinit sysvinit-core sysvinit-utils sysv-rc initscripts bootlogd
Architecture: source amd64 all
Version: 2.88dsf-46
Distribution: experimental
Urgency: medium
Maintainer: Debian sysvinit maintainers 
<[email protected]>
Changed-By: Petter Reinholdtsen <[email protected]>
Description: 
 bootlogd   - daemon to log boot messages
 initscripts - scripts for initializing and shutting down the system
 sysv-rc    - System-V-like runlevel change mechanism
 sysvinit   - System-V-like init utilities
 sysvinit-core - System-V-like init utilities
 sysvinit-utils - System-V-like utilities
Closes: 691210 705132 721917 726483 736060 737073
Changes: 
 sysvinit (2.88dsf-46) experimental; urgency=medium
 .
   [ Thomas Goirand ]
   * Uploading to Experimental.
   * Added myself as uploader (after Petter advised for it).
   * Refreshed patches.
 .
   [ James McCoy ]
   * sysv-rc:
     - Update invoke-rc.d and service to trim .sh from service names when
       calling systemctl.  (Closes: #726483)
 .
   [ Roger Leigh ]
   * sysv-rc:
     - Remove obsolete/broken update-rc.d usage information from
       update-rc.d(8) and update-rc.d itself (Closes: #736060).  Thanks
       to Julian Gilbey for finding these bugs.
   * initscripts:
     - mountkernfs mounts configfs on /sys/kernel/config when available.
 .
   [ Justus Winter ]
   * Fixes for Debian/Hurd (Closes: #737073, #721917).
     - mount-functions.sh: Hurd has a tmpfs translator now, remove
       workaround.
     - mount-functions.sh: Add -ocompatible to procfs mounts on Hurd.
     - mountall.sh: Use pidof -s /sbin/init for robustness.
     - checkroot.sh: Only run rootcheck on Linux. Neither kFreeBSD nor
       Hurd have /dev/root and the device ids used here are specific to
       Linux.
     - killall5.c: Use sysconf(_SC_SYMLOOP_MAX) instead of MAXSYMLINKS.
       Fixes build on Hurd.
     - sysvinit.postinst: Fix file name of gettys in /etc/inittab on
       Hurd.
     - Break hurd << 0.5.git20131101~. Older versions of the hurd
       package lack the necessary functionality to boot Debian/Hurd
       using sysvinit.
     - Add runsystem.sysv that uses sysvinit to boot Debian/Hurd.
 .
   [ Petter Reinholdtsen ]
   * Updated Japanese debconf translations from Hideki Yamane
     (Closes: #705132).
   * Added getty on the Mach console in the Hurd inittab.  Patch from
     Samuel Thibault.
   * Completed Norwegian Bokmål debconf translation.
 .
   [ Gabriele Giacone ]
   * Bump Standards-Version to 3.9.5 (no changes).
   * sysv-rc:
     - Remove leftover from .legacy-bootordering flagfile removal (#668312)
       (Closes: #691210)
Checksums-Sha1: 
 019fa201d8b1ee026120c57b5cb45488bb033245 1777 sysvinit_2.88dsf-46.dsc
 28e0029f3bfa874bdb5011350b8793c99d708612 169076 
sysvinit_2.88dsf-46.debian.tar.xz
 d5a55bda1032bcfcec748b3c5e0f57165b260ddb 80976 sysvinit_2.88dsf-46_amd64.deb
 6880500de5ae519041eedeb44b16627a562de720 128278 
sysvinit-core_2.88dsf-46_amd64.deb
 048b98cf869f9d20310c6fa56bebc683c950e948 93430 
sysvinit-utils_2.88dsf-46_amd64.deb
 43bfc89508151aeba54bacc450e177d220c6cd08 79736 sysv-rc_2.88dsf-46_all.deb
 6c8949eb5e82041de6e5c2e836653213843f0d38 84660 initscripts_2.88dsf-46_amd64.deb
 bdaec64a3fd1cb6a25384c0ec3f1b54b1836a877 56176 bootlogd_2.88dsf-46_amd64.deb
Checksums-Sha256: 
 2d1bd06aadacae74e4da277f6ba5efaa4561d8c080a31d69d397a13f957344c0 1777 
sysvinit_2.88dsf-46.dsc
 eb368bee58f0d8fe67292fdc3e4d68b11e25fff90d52c3c98a211b7b522ca9cc 169076 
sysvinit_2.88dsf-46.debian.tar.xz
 90a6c6b79c56bb6dcbd388c2659d023ce45ba55835b4a9ca205768246515b42e 80976 
sysvinit_2.88dsf-46_amd64.deb
 31405c0746a75f74f1c8b4f0a290b519219338ac75b80a7b1b7a8aed8a1e4585 128278 
sysvinit-core_2.88dsf-46_amd64.deb
 f51ddaade9668dbe5b1df94ade4a5b5c5da2d0a756db22153cf2eb18d5285ecf 93430 
sysvinit-utils_2.88dsf-46_amd64.deb
 147a5ebb06b024c0b943474318d12a5f46040602a2bf4c5d068c6f6ed594d4bf 79736 
sysv-rc_2.88dsf-46_all.deb
 4498b31716729fbdf71bbebaf55a0795371a6d4c13a04ab681e495802fe41c9d 84660 
initscripts_2.88dsf-46_amd64.deb
 49de104e7f5865611623af4dea8f761ce487d61001ad85b568c89fc4c9686986 56176 
bootlogd_2.88dsf-46_amd64.deb
Files: 
 54a473d8d4d01845ea9e3ab1d7092a05 1777 admin required sysvinit_2.88dsf-46.dsc
 ef76216786e35a9c78a2ae96aaad72fb 169076 admin required 
sysvinit_2.88dsf-46.debian.tar.xz
 b8f4c66a63104be7fa752b6f44e74727 80976 admin required 
sysvinit_2.88dsf-46_amd64.deb
 87c1ad1ef2e1c92debc99cc2fb4e397b 128278 admin required 
sysvinit-core_2.88dsf-46_amd64.deb
 693a53be84ab469ef7f24345c8a276ac 93430 admin required 
sysvinit-utils_2.88dsf-46_amd64.deb
 d07834455c892f4439f4cb81e968b8ff 79736 admin required 
sysv-rc_2.88dsf-46_all.deb
 2ee9f95bcacab0fd465293058e0af12b 84660 admin required 
initscripts_2.88dsf-46_amd64.deb
 d63fc5352ac1a30e5669764ca3404119 56176 admin optional 
bootlogd_2.88dsf-46_amd64.deb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iD8DBQFS7XmR20zMSyow1ykRAkzaAKDurI+9c1yGUt9QOeg/kAtLwjmVSwCg4Fy+
6l9BjAeqO9saqtvdgWunFIw=
=jGhL
-----END PGP SIGNATURE-----

--- End Message ---
_______________________________________________
Pkg-sysvinit-devel mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-sysvinit-devel

Reply via email to