[Pkg-sysvinit-commits] r1915 - in sysvinit/trunk/debian: . src/initscripts/etc/init.d

Petter Reinholdtsen pere at alioth.debian.org
Sun Jun 6 09:36:33 UTC 2010


Author: pere
Date: 2010-06-06 09:36:25 +0000 (Sun, 06 Jun 2010)
New Revision: 1915

Modified:
   sysvinit/trunk/debian/changelog
   sysvinit/trunk/debian/src/initscripts/etc/init.d/bootmisc.sh
   sysvinit/trunk/debian/src/initscripts/etc/init.d/checkroot.sh
   sysvinit/trunk/debian/src/initscripts/etc/init.d/mountdevsubfs.sh
   sysvinit/trunk/debian/src/initscripts/etc/init.d/umountfs
   sysvinit/trunk/debian/src/initscripts/etc/init.d/umountnfs.sh
Log:
* Make sure to create /dev/pts/ and /dev/shm/ in mountdevsub.sh
  before mounting them to allow udev to stop creating them at boot
  (Closes: #584742).  Thanks to Marco d'Itri for the patch.
* Drop support for the now obsolete devfs file system.

Modified: sysvinit/trunk/debian/changelog
===================================================================
--- sysvinit/trunk/debian/changelog	2010-06-06 06:22:50 UTC (rev 1914)
+++ sysvinit/trunk/debian/changelog	2010-06-06 09:36:25 UTC (rev 1915)
@@ -5,6 +5,10 @@
     (Closes: #584102)
   * Make init.d/bootlogs soft depend on gdm3 while we wait for gdm3 to
     provide $x-display-manager.
+  * Make sure to create /dev/pts/ and /dev/shm/ in mountdevsub.sh
+    before mounting them to allow udev to stop creating them at boot
+    (Closes: #584742).  Thanks to Marco d'Itri for the patch.
+  * Drop support for the now obsolete devfs file system.
 
  -- Petter Reinholdtsen <pere at debian.org>  Sat, 05 Jun 2010 00:33:27 +0200
 

Modified: sysvinit/trunk/debian/src/initscripts/etc/init.d/bootmisc.sh
===================================================================
--- sysvinit/trunk/debian/src/initscripts/etc/init.d/bootmisc.sh	2010-06-06 06:22:50 UTC (rev 1914)
+++ sysvinit/trunk/debian/src/initscripts/etc/init.d/bootmisc.sh	2010-06-06 09:36:25 UTC (rev 1915)
@@ -34,7 +34,7 @@
 	fi
 
 	# Set pseudo-terminal access permissions.
-	if [ ! -e /dev/.devfsd ] && [ ! -e /dev/.udev ] && [ -c /dev/ttyp0 ]
+	if [ ! -e /dev/.udev ] && [ -c /dev/ttyp0 ]
 	then
 		chmod -f 666 /dev/tty[p-za-e][0-9a-f]
 		chown -f root:tty /dev/tty[p-za-e][0-9a-f]

Modified: sysvinit/trunk/debian/src/initscripts/etc/init.d/checkroot.sh
===================================================================
--- sysvinit/trunk/debian/src/initscripts/etc/init.d/checkroot.sh	2010-06-06 06:22:50 UTC (rev 1914)
+++ sysvinit/trunk/debian/src/initscripts/etc/init.d/checkroot.sh	2010-06-06 09:36:25 UTC (rev 1915)
@@ -41,7 +41,6 @@
 	# 	device node,
 	# 2) Swap that is on a md device or a file that may be on a md 
 	# 	device,
-	# 3) The mount parameters for a devfs filesystem.
 	#
 
 	exec 9<&0 </etc/fstab
@@ -54,7 +53,6 @@
 	rootcheck=no
 	swap_on_lv=no
 	swap_on_file=no
-	devfs=
 
 	while read DEV MTPT FSTYPE OPTS DUMP PASS JUNK
 	do
@@ -77,11 +75,6 @@
 			[ "$FSTYPE" = "swap" ] && swap_on_file=yes
 			;;
 		  *)
-			# Devfs definition ?
-			if [ "$FSTYPE" = "devfs" ] && [ "$MTPT" = "/dev" ] && mountpoint -q /dev
-			then
-				devfs="-t $FSTYPE $DEV $MTPT"
-			fi
 			;;
 		esac
 		[ "$MTPT" != "/" ] && continue
@@ -390,7 +383,6 @@
 	then
 		[ "$roottype" != none ] &&
 			mount -f -o $rootopts -t $roottype $fstabroot /
-		[ "$devfs" ] && mount -f $devfs
 	fi
 
 	#

Modified: sysvinit/trunk/debian/src/initscripts/etc/init.d/mountdevsubfs.sh
===================================================================
--- sysvinit/trunk/debian/src/initscripts/etc/init.d/mountdevsubfs.sh	2010-06-06 06:22:50 UTC (rev 1914)
+++ sysvinit/trunk/debian/src/initscripts/etc/init.d/mountdevsubfs.sh	2010-06-06 09:36:25 UTC (rev 1915)
@@ -31,47 +31,26 @@
 	#
 	# Mount a tmpfs on /dev/shm
 	#
+	if [ ! -d /dev/shm ]
+	then
+		mkdir --mode=755 /dev/shm
+		[ -x /sbin/restorecon ] && /sbin/restorecon /dev/shm
+	fi
 	SHM_OPT=
 	[ "${SHM_SIZE:=$TMPFS_SIZE}" ] && SHM_OPT=",size=$SHM_SIZE"
 	domount tmpfs shmfs /dev/shm tmpfs -onosuid,nodev$SHM_OPT
 
 	#
-	# Mount /dev/pts. Create master ptmx node if needed.
+	# Mount /dev/pts
 	#
-	# As of 2.5.68, devpts is not automounted when using devfs. So we
-	# mount devpts if it is compiled in (older devfs didn't require it
-	# to be compiled in at all).
-	#
 	if [ "$KERNEL" = Linux ]
 	then
-		#
-		# Since kernel 2.5.something, devfs doesn't include
-		# a standard /dev/pts directory anymore. So if devfs
-		# is mounted on /dev we need to create that directory
-		# manually.
-		#
 		if [ ! -d /dev/pts ]
 		then
-			if grep -qs '/dev devfs' /proc/mounts
-			then
-				mkdir --mode=755 /dev/pts
-				[ -x /sbin/restorecon ] && /sbin/restorecon /dev/pts
-			fi
+			mkdir --mode=755 /dev/pts
+			[ -x /sbin/restorecon ] && /sbin/restorecon /dev/pts
 		fi
-		if [ -d /dev/pts ]
-		then
-			if [ ! -c /dev/ptmx ]
-			then
-				mknod --mode=666 /dev/ptmx c 5 2
-				ES=$?
-				if [ "$ES" != 0 ]
-				then
-					log_warning_msg "Failed making node /dev/ptmx with error code ${ES}."
-				fi
-				[ -x /sbin/restorecon ] && /sbin/restorecon /dev/ptmx
-			fi
-			domount devpts "" /dev/pts devpts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE
-		fi
+		domount devpts "" /dev/pts devpts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE
 	fi
 }
 

Modified: sysvinit/trunk/debian/src/initscripts/etc/init.d/umountfs
===================================================================
--- sysvinit/trunk/debian/src/initscripts/etc/init.d/umountfs	2010-06-06 06:22:50 UTC (rev 1914)
+++ sysvinit/trunk/debian/src/initscripts/etc/init.d/umountfs	2010-06-06 09:36:25 UTC (rev 1915)
@@ -42,7 +42,7 @@
 			;;
 		esac
 		case "$FSTYPE" in 
-		  proc|procfs|linprocfs|devfs|sysfs|usbfs|usbdevfs|devpts)
+		  proc|procfs|linprocfs|sysfs|usbfs|usbdevfs|devpts)
 			continue
 			;;
 		  tmpfs)

Modified: sysvinit/trunk/debian/src/initscripts/etc/init.d/umountnfs.sh
===================================================================
--- sysvinit/trunk/debian/src/initscripts/etc/init.d/umountnfs.sh	2010-06-06 06:22:50 UTC (rev 1914)
+++ sysvinit/trunk/debian/src/initscripts/etc/init.d/umountnfs.sh	2010-06-06 09:36:25 UTC (rev 1915)
@@ -7,7 +7,7 @@
 # Default-Start:
 # Default-Stop:      0 6
 # Short-Description: Unmount all network filesystems except the root fs.
-# Description:       Also unmounts all virtual filesystems (proc, devfs,
+# Description:       Also unmounts all virtual filesystems (proc,
 #                    devpts, usbfs, sysfs) that are not mounted at the
 #                    top level.
 ### END INIT INFO
@@ -66,7 +66,7 @@
 		  nfs|nfs4|smbfs|ncp|ncpfs|cifs|coda|ocfs2|gfs)
 			DIRS="$MTPT $DIRS"
 			;;
-		  proc|procfs|linprocfs|devfs|devpts|usbfs|usbdevfs|sysfs)
+		  proc|procfs|linprocfs|devpts|usbfs|usbdevfs|sysfs)
 			DIRS="$MTPT $DIRS"
 			;;
 		esac




More information about the Pkg-sysvinit-commits mailing list