"Go" in Ubuntu no/etc/inittab files explored

Source: Internet
Author: User

Original URL: http://blog.csdn.net/gavinr/article/details/6584582

Linux starts the first process is/sbin/init, its main function is the software execution environment, including the system host name, network settings, language processing, file system format and other services start. Its config file is/etc/inittab, but I didn't find it in my ubuntu10.10.
Originally used in Ubuntu/etc/event.d this directory, complete similar functions. The ubuntu9.10 version of upstart no longer uses the/ETC/EVENT.D directory. Instead, use the/etc/init directory instead. A file rc-sysinit.conf was found under/etc/init/, similar to the Rc.sysinit file name, and was opened and found to have the following contents:
[HTML]View Plaincopyprint?
  1. # Rc-sysinit-system V initialisation compatibility
  2. #
  3. # This task runs the old system V-style system initialisation scripts,
  4. # and enters the default runlevel when finished.
  5. # Check for default RunLevel in/etc/inittab
  6. if [-r/etc/inittab]
  7. Then
  8. Eval "$ (sed-nre ' s/^[^#][^:]*:([0-6SS]): initdefault:.*/default_runlevel=" \1 ";/P '/etc/inittab | | true) "
  9. Fi
  10. ......
  11. # Run the system initialisation scripts
  12. [-N "${from_single_user_mode}"] | | /etc/init.d/rcs
Obviously, Ubuntu still supports/etc/initab files. At the end of the script,/etc/init.d/rcs is executed, and the contents of the RcS are:
[HTML]View Plaincopyprint?
    1. #! /bin/sh
    2. #
    3. # RcS
    4. #
    5. # call all S?? * Scripts in/etc/rcs.d/in numerical/alphabetical Order
    6. #

All the statements in the file have been commented out, it appears that the file exists only for compatibility, not the implementation of the use. But take a look at the SRS.D directory:

[HTML]View Plaincopyprint?
  1. [Email protected]:/etc/rcs.d$ ll
  2. Total 20
  3. -rw-r--r--1 root root 447 2009-09-07 11:58 README
  4. lrwxrwxrwx 1 root root 2010-12-07 05:27 S01apparmor->. /init.d/apparmor*
  5. lrwxrwxrwx 1 root root 2010-12-07 05:27 S01brltty->. /init.d/brltty*
  6. lrwxrwxrwx 1 root root 2010-12-07 05:27 s01lm-sensors->. /init.d/lm-sensors*
  7. lrwxrwxrwx 1 root root 2010-12-07 05:27 S01x11-common->. /init.d/x11-common*
  8. lrwxrwxrwx 1 root root 2010-12-07 05:27 s02pcmciautils->. /init.d/pcmciautils*
  9. lrwxrwxrwx 1 root root 2010-12-07 05:27 s02urandom->. /init.d/urandom*

All files are symbolic links, all pointing to: Files in the/INIT.D directory

"Go" in Ubuntu without/etc/inittab files

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.