~ubuntu-branches/ubuntu/natty/sysvinit/natty-proposed

« back to all changes in this revision

Viewing changes to debian/initscripts/etc/init.d/mountdevsubfs.sh

  • Committer: Bazaar Package Importer
  • Author(s): Scott James Remnant
  • Date: 2009-09-15 02:45:59 UTC
  • Revision ID: james.westby@ubuntu.com-20090915024559-2bv3ihsb0cu9xw2c
Tags: 2.87dsf-4ubuntu3
FFE LP: #427356.

* Various initscripts have been replaced by Upstart jobs shipped in
  other packages, the following have been removed:
  - hostname.sh
  - mountkernfs.sh
  - mountdevsubfs.sh
  - checkroot.sh
  - mtab.sh
  - checkfs.sh
  - mountall.sh
  - mountall-bootclean.sh
  - mountoverflowtmp
  - mountnfs.sh
  - mountnfs-bootclean.sh
  - bootmisc.sh
  - bootlogs
  - rmnlogin

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#! /bin/sh
2
 
### BEGIN INIT INFO
3
 
# Provides:          mountdevsubfs
4
 
# Required-Start:    mountkernfs
5
 
# Required-Stop:
6
 
# Should-Start:      udev
7
 
# Default-Start:     S
8
 
# Default-Stop:
9
 
# Short-Description: Mount special file systems under /dev.
10
 
# Description:       Mount the virtual filesystems the kernel provides
11
 
#                    that ordinarily live under the /dev filesystem.
12
 
### END INIT INFO
13
 
#
14
 
# This script gets called multiple times during boot
15
 
#
16
 
 
17
 
PATH=/lib/init:/sbin:/bin
18
 
TTYGRP=5
19
 
TTYMODE=620
20
 
[ -f /etc/default/devpts ] && . /etc/default/devpts
21
 
 
22
 
TMPFS_SIZE=
23
 
[ -f /etc/default/tmpfs ] && . /etc/default/tmpfs
24
 
 
25
 
KERNEL="$(uname -s)"
26
 
 
27
 
. /lib/lsb/init-functions
28
 
. /lib/init/mount-functions.sh
29
 
 
30
 
do_start () {
31
 
        #
32
 
        # Mount a tmpfs on /dev/shm
33
 
        #
34
 
        SHM_OPT=
35
 
        [ "${SHM_SIZE:=$TMPFS_SIZE}" ] && SHM_OPT=",size=$SHM_SIZE"
36
 
        domount tmpfs shmfs /dev/shm tmpfs -onosuid,nodev$SHM_OPT
37
 
 
38
 
        #
39
 
        # Mount /dev/pts. Master ptmx node is already created by udev.
40
 
        #
41
 
        domount devpts "" /dev/pts devpts -onoexec,nosuid,gid=$TTYGRP,mode=$TTYMODE
42
 
}
43
 
 
44
 
case "$1" in
45
 
  "")
46
 
        echo "Warning: mountdevsubfs should be called with the 'start' argument." >&2
47
 
        do_start
48
 
        ;;
49
 
  start)
50
 
        do_start
51
 
        ;;
52
 
  restart|reload|force-reload)
53
 
        echo "Error: argument '$1' not supported" >&2
54
 
        exit 3
55
 
        ;;
56
 
  stop)
57
 
        # No-op
58
 
        ;;
59
 
  *)
60
 
        echo "Usage: mountdevsubfs [start|stop]" >&2
61
 
        exit 3
62
 
        ;;
63
 
esac