[Pkg-sysvinit-devel] Prepare new upload of sysvinit for Squeeze

Kel Modderman kel at otaku42.de
Tue Sep 21 13:13:58 UTC 2010


Hi pkg-sysvinit and release team,

I have applied changes which will improve the boot system in Squeeze
and the debdiff is attached for review. Do any other sysvinit maintainer have
any changes they believe should applied before next upload?

Release team, can you please acknowledge these changes as ok for next upload?

Thanks, Kel.
---
diff -u sysvinit-2.88dsf/debian/changelog sysvinit-2.88dsf/debian/changelog
--- sysvinit-2.88dsf/debian/changelog
+++ sysvinit-2.88dsf/debian/changelog
@@ -1,3 +1,26 @@
+sysvinit (2.88dsf-13) unstable; urgency=low
+
+  * Remove runlevel duration printing code from init.d/rc script
+    as it was scheduled for removal before squeeze and imperfect.
+    (Closes: #584862)
+  * Really ignore CTRL-C interuption in initd.d/rc by setting a
+    signal trap with null string as argument. This prevents incomplete
+    boot if CTRL-C is pressed, eg. during fsck, when conccurrent boot is
+    enabled. (Closes: #595431)
+  * Prevent init.d/rc script from executing stop scripts twice
+    in runlevels 0 and 6 when conccurrent boot is enabled.
+    (Closes: #594253)
+  * Modify debian/startpar/patches/06_stdin_notty.patch so it applies
+    without fuzziness.
+  * Add debian/startpar/patches/08_kfreebsd_proc_error_debug.patch to
+    prevent frequent messages on Debian GNU/kFreeBSD from littering boot
+    messages. Thanks Petr Salinger for the patch. (Closes: #590560)
+  * Avoid umounting virtual filesystems (eg, cgroup) mounted under
+    /sys/* as there is no good reason to do so. Thanks Michael Biebl
+    for the patch. (Closes: #597338)
+
+ -- Kel Modderman <kel at otaku42.de>  Tue, 21 Sep 2010 22:54:56 +1000
+
 sysvinit (2.88dsf-12) unstable; urgency=low
 
   [ Petter Reinholdtsen ]
diff -u sysvinit-2.88dsf/debian/startpar/patches/06_stdin_notty.patch sysvinit-2.88dsf/debian/startpar/patches/06_stdin_notty.patch
--- sysvinit-2.88dsf/debian/startpar/patches/06_stdin_notty.patch
+++ sysvinit-2.88dsf/debian/startpar/patches/06_stdin_notty.patch
@@ -4,12 +4,13 @@
 	 A better approach would be to get parallel booting working in
 	 such setting.
 Fixes:   #584102
-Authour: Petter Reinholdtsen
+Authour: Petter Reinholdtsen, with modification from Kel Modderman to
+         co-exist with 01_dev_pts_workaround.patch without fuzz.
 Status:  Not applied upstream
 
---- a/startpar.c	(revision 1898)
-+++ b/startpar.c	(working copy)
-@@ -631,6 +631,7 @@
+--- a/startpar.c
++++ b/startpar.c
+@@ -698,6 +698,7 @@ int main(int argc, char **argv)
    char *prev_level = getenv("PREVLEVEL");
    char *run_level = getenv("RUNLEVEL");
    char *splashopt = 0;
@@ -17,7 +18,7 @@
  
    (void)signal(SIGUSR1, sighandler_preload);
    (void)signal(SIGUSR2, sighandler_nopreload);
-@@ -813,8 +814,7 @@
+@@ -880,8 +881,7 @@ int main(int argc, char **argv)
  
    if (tcgetattr(0, &tio))
      {
@@ -29,13 +30,13 @@
      wzok = 1;
-@@ -904,6 +904,11 @@
- 		  }
- 		  p->splashadd = calcsplash(num, argc, splashopt);
+@@ -976,9 +976,9 @@ int main(int argc, char **argv)
  		  p->num = num++;
-+                  if (notty)
-+                    {
-+                      interactive_task = p;     /* no tty, treat as interactive */
-+                      continue;
-+                    }
  		  if (interactive_task)
  		    continue;			/* don't start this here */
+-		  if (!devpts)
++		  if (!devpts || notty)
+ 		    {
+-		      interactive_task = p;	/* no /dev/pts, treat as interactive */
++		      interactive_task = p;	/* no /dev/pts or tty, treat as interactive */
+ 		      continue;
+ 		    }
  		  run(p);
diff -u sysvinit-2.88dsf/debian/startpar/patches/series sysvinit-2.88dsf/debian/startpar/patches/series
--- sysvinit-2.88dsf/debian/startpar/patches/series
+++ sysvinit-2.88dsf/debian/startpar/patches/series
@@ -8,0 +9 @@
+08_kfreebsd_proc_error_debug.patch
diff -u sysvinit-2.88dsf/debian/src/sysv-rc/etc/init.d/rc sysvinit-2.88dsf/debian/src/sysv-rc/etc/init.d/rc
--- sysvinit-2.88dsf/debian/src/sysv-rc/etc/init.d/rc
+++ sysvinit-2.88dsf/debian/src/sysv-rc/etc/init.d/rc
@@ -16,8 +16,6 @@
 PATH=/sbin:/usr/sbin:/bin:/usr/bin
 export PATH
 
-starttime=$(date +%s)
-
 # Un-comment the following for interactive debugging. Do not un-comment
 # this for debugging a real boot process as no scripts will be executed.
 # debug=echo
@@ -43,7 +41,7 @@
 trap on_exit EXIT # Enable emergency handler
 
 # Ignore CTRL-C only in this shell, so we can interrupt subprocesses.
-trap ":" INT QUIT TSTP
+trap "" INT QUIT TSTP
 
 # Set onlcr to avoid staircase effect.
 stty onlcr 0>&1
@@ -217,10 +215,13 @@
 	done
 	step=0
 
+	# First, run the KILL scripts.
 	if [ makefile = "$CONCURRENCY" ]
 	then
-		[ "$previous" != N ] && startup stop
-	# First, run the KILL scripts.
+		if [ "$ACTION" = "start" ] && [ "$previous" != N ]
+		then
+			startup stop
+		fi
 	elif [ "$previous" != N ]
 	then
 		# Run all scripts with the same level in parallel
@@ -334,10 +335,4 @@
 trap - EXIT # Disable emergency handler
 
-# This code should be removed when Squeeze freeze is getting closer
-# - Petter 2010-05-18
-endtime=$(date +%s)
-duration=$(($endtime - $starttime))
-log_action_msg "Running scripts in rc$runlevel.d/ took $duration seconds"
-
 exit 0
 
diff -u sysvinit-2.88dsf/debian/src/initscripts/etc/init.d/umountfs sysvinit-2.88dsf/debian/src/initscripts/etc/init.d/umountfs
--- sysvinit-2.88dsf/debian/src/initscripts/etc/init.d/umountfs
+++ sysvinit-2.88dsf/debian/src/initscripts/etc/init.d/umountfs
@@ -27,7 +27,7 @@
 	do
 		echo "$PROTECTED_MOUNTS" | grep -qs "^$DEV $MTPT " && continue
 		case "$MTPT" in
-		  /|/proc|/dev|/.dev|/dev/pts|/dev/shm|/dev/.static/dev|/proc/*|/sys|/lib/init/rw)
+		  /|/proc|/dev|/.dev|/dev/pts|/dev/shm|/dev/.static/dev|/proc/*|/sys|/sys/*|/lib/init/rw)
 			continue
 			;;
 		  /var/run)
only in patch2:
unchanged:
--- sysvinit-2.88dsf.orig/debian/startpar/patches/08_kfreebsd_proc_error_debug.patch
+++ sysvinit-2.88dsf/debian/startpar/patches/08_kfreebsd_proc_error_debug.patch
@@ -0,0 +1,28 @@
+Purpose: Debian GNU/kFreeBSD does not have procs_running/procs_blocked
+         fields in /proc/stat. Avoid frequent messages about it.
+Fixes:   #590560
+Authour: Petr Salinger <Petr.Salinger at seznam.cz>
+Status:  Not yet submitted upstream.
+
+--- a/proc.c
++++ b/proc.c
+@@ -35,7 +35,9 @@ static unsigned long int scan_one(const
+     unsigned long val = 0;
+ 
+     if (!b) {
++#if DEBUG
+ 	fprintf(stderr, "ERROR: no hit for %s\n", key);
++#endif
+ 	return ~0UL;
+     }
+     if (sscanf(b + strlen(key), " %lu", &val) != 1)
+@@ -69,7 +71,8 @@ int read_proc(unsigned long int * const
+     }
+     fclose(stat);
+     
+-    /* These fields are not present in /proc/stat for 2.4 kernels */
++    /* These fields are not present in /proc/stat for 2.4 kernels
++       or GNU/kFreeBSD */
+     running = scan_one(StatBuf, "procs_running");
+     blocked = scan_one(StatBuf, "procs_blocked");
+ 
---



More information about the Pkg-sysvinit-devel mailing list