Ubuntu system default startup settings (graphical interface or command line)

Source: Internet
Author: User

In the early days of the Linux system, there was only a command-line interface, and all the work needed to be done with Linux commands.


With the development of the system, as well as the appearance of the graphical interface system, Linux also appears the graphical interface, making the Linux system is no longer only the computer professionals can use, ordinary users can also be very convenient to use Linux.


We can set the Linux system's default startup according to our own requirements: whether it is a graphical interface or a command line interface.


Method One, change the default startup settings

/etc/x11/default-display-manager file: The original value is/USR/SBIN/GDM, which means that the default is to enter the graphical interface. To: False to indicate access to the console.

For example: The/etc/x11/default-display-manager file is as follows:

#/USR/SBIN/GDM

False
When you start Ubuntu, it goes to the command line and does not start the graphical interface. Can save a lot of system memory. Then if you start the graphical interface, you can use the STARTX command.


Method Two, specify system run level

Command: init[0123456] (This command needs to operate under root, or use sudo)

Run Level: (0: Shutdown; 1: Single user; 2: Multiuser status has no network service; 3: Multi-User state has network service; 4: The system is not used to keep the user; 5: graphical interface; 6: System reboot).

Common run levels are 3 and 5, to modify the default run level to modify file/etc/inittab Id:5:inittab: This line of numbers.

For example: Su root

Init 3

Init 5

Or: Vi/etc/inittab

Id:5:initdefault:

Change into
Id:3:initdefault:

        to enter the editor by E when starting the boot interface, enter e when entering the Grub primer interface, and then select the second option to press E, then enter the 1[single user level, and then press B to enter Single-user mode.

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.