Tell me more ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Is it possible to disable X at boot time? I'm setting up a server so it would be nice if it wouldn't load the graphical interface every time I boot.

share|improve this question

4 Answers

For Ubuntu 11.10 and 12.04, 12.10

Edit /etc/default/grub with your favorite editor,

sudo nano /etc/default/grub

Find out this line:

GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash”

Change it to:

GRUB_CMDLINE_LINUX_DEFAULT=”text”

Update Grub:

sudo update-grub

No need to remove / disable lightdm upstart conf, it already does that for you.

lightdm.conf

# Check kernel command-line for inhibitors, unless we are being called
        # manually
        for ARG in $(cat /proc/cmdline); do
            if [ "$ARG" = "text" ]; then
                plymouth quit || :
                stop
                exit 0
            fi
        done

You will still be able to use X by typing startx after you logged in.

share|improve this answer

For 11.04 and previous versions (and perhaps later)

If you want to boot into text mode:

Edit /etc/default/grub. For example:

sudo gedit /etc/default/grub

Find this line:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

Add text:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash text"

Then update Grub:

sudo update-grub

Note: Removing quiet splash (i.e. GRUB_CMDLINE_LINUX_DEFAULT="") will show text during boot but then show a graphical login screen as usual. Replacing quiet splash with text will leave you at a login prompt; to start a GNOME session, use sudo /etc/init.d/gdm start or startx.

To disable GDM:
Install bum Install bum

After installation it will be found under System>>Administration>>Bootup-Manager

Uncheck Gnome Display Manager alt text

share|improve this answer
The GRUB config worked. Out of curiosity, why would I want to disable GDM? – Olivier Lalonde Dec 6 '10 at 3:22
1  
because doing so would accomplish the same thing. – RolandiXor Dec 6 '10 at 3:27
Confirmed in 13.04 that GRUB_CMDLINE_LINUX_DEFAULT="" works to show details during boot while still launching graphical login. – Jesse Glick May 20 at 13:46

You could use Ubuntu Server edition.

share|improve this answer
+1 for the straight solution. – Anwar Sep 26 '12 at 16:12

I did following

Step 1 First update your repository by running

sudo apt-get update

Step 2 There is some bug in old version of lightdm, so we need to upgrade the same. To do so run,

sudo apt-get install lightdm

Step 3 Now we have to modify grub config.

Step 3a Open /etc/default/grub with your faviourite editor and change

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

to

GRUB_CMDLINE_LINUX_DEFAULT="text"

Step 3b Also comment GRUB_HIDDEN_TIMEOUT=0 This line is for unhiding the GRUB menu

Step 4 Now we will upgrade GRUB configuration

sudo update-grub

Step 5 Now restart your machine.

share|improve this answer
According to lightdm.conf it is not necessary to remove lightdm. – Bruno Pereira Jan 12 '12 at 20:18
if you did not remove it you will get GUI after doing all this. – Vidyadhar Jan 14 '12 at 7:59
Sorry, just tested it in 11.10, this is not true, no need to remove lighdm, step 5 is not necessary. – Bruno Pereira Jan 14 '12 at 8:56
Ok I have removed the 5th step regarding lightdm – Vidyadhar Jan 15 '12 at 8:14

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.