MrEngman
Posts: 3844
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

How do I stop the GUI automatically starting

Thu Jul 12, 2012 1:12 pm

After updating pisces r2 with rpi-update the GUI is automatically started when I boot.

How can I stop the GUI automatically starting?
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

User avatar
RaTTuS
Posts: 10412
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: How do I stop the GUI automatically starting

Thu Jul 12, 2012 1:20 pm

sudo chmod 644 /etc/init.d/slim
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

Joe Schmoe
Posts: 4277
Joined: Sun Jan 15, 2012 1:11 pm

Re: How do I stop the GUI automatically starting

Thu Jul 12, 2012 1:30 pm

RaTTuS wrote:sudo chmod 644 /etc/init.d/slim
Is this real? How did the "auto-start X and present the user with a GINA" thing become the default on any publicly available Pi distro? I thought they were all setup as "You must type 'startx' to start the GUI.".
And some folks need to stop being fanboys and see the forest behind the trees.

(One of the best lines I've seen on this board lately)

masterluke
Posts: 200
Joined: Tue Apr 17, 2012 4:10 pm

Re: How do I stop the GUI automatically starting

Thu Jul 12, 2012 1:36 pm

I was surprised to see a graphical login on updating too. Its a bit annoying as XBMC needs X killed to work properly and I cant for the life of me figure out how to kill X without it restarting itself.

mard0
Posts: 52
Joined: Wed Oct 26, 2011 4:23 pm

Re: How do I stop the GUI automatically starting

Thu Jul 12, 2012 2:06 pm

sudo apt-get purge slim

MrEngman
Posts: 3844
Joined: Fri Feb 03, 2012 2:17 pm
Location: Southampton, UK

Re: How do I stop the GUI automatically starting

Thu Jul 12, 2012 2:54 pm

Thanks guys,

Both methods suggested work for those interested.

That's much better.
Simplicity is a prerequisite for reliability. Edsger W. Dijkstra

Please post ALL technical questions on the forum. Please Do Not send private messages.

gidoca
Posts: 6
Joined: Thu Nov 24, 2011 3:56 pm

Re: How do I stop the GUI automatically starting

Fri Jul 13, 2012 9:54 am

I don't have my Raspberry Pi in front of me right now to test it, but I believe that changing /etc/X11/default-display-manager to be empty should also prevent slim from starting.

User avatar
mpthompson
Posts: 620
Joined: Fri Feb 03, 2012 7:18 pm
Location: San Carlos, CA
Contact: Website

Re: How do I stop the GUI automatically starting

Fri Jul 13, 2012 10:13 pm

gidoca wrote:I don't have my Raspberry Pi in front of me right now to test it, but I believe that changing /etc/X11/default-display-manager to be empty should also prevent slim from starting.
This is the approach I take. Actually, just putting a '#' in front of the first line in the file (commenting it out) will effectively disable the display manager from starting.

egorive
Posts: 2
Joined: Wed Oct 17, 2012 3:38 pm

Re: How do I stop the GUI automatically starting

Sun Oct 28, 2012 12:31 pm

Hi,

Any of the three methods given in this thread solve me the problem. There is still the login command line screen after reboot.

¿Any other ideas?

Thank you very much.

User avatar
RaTTuS
Posts: 10412
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: How do I stop the GUI automatically starting

Mon Oct 29, 2012 11:33 am

egorive wrote:Hi,

Any of the three methods given in this thread solve me the problem. There is still the login command line screen after reboot.

¿Any other ideas?

Thank you very much.
there are ways of enabling the auto login feature - can you make a new post as this is old info and should be ignored now
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

k7n4n5t3w4rt
Posts: 7
Joined: Sat Dec 12, 2015 7:34 pm

Re: How do I stop the GUI automatically starting

Sat Dec 12, 2015 8:09 pm

Setting up a new Pi, I downloaded Noobs and selected Raspbian as the OS as I have done many times. It's pretty annoying that the gui now starts up automatically.

I used to get the config options where I could enable ssh, set the timezone etc. Now it just boots into the gui. My mouse doesn't seem to work (it's an old Apple one) and I can't seem to navigate the gui with my keyboard only (or maybe it's not recognising the keyboard). In any case, I can't get a command line and I can't use either of these options:

sudo chmod 644 /etc/init.d/slim

or

sudo apt-get purge slim

I'm thinking I might be able to get to this file if I put the SD card back into my mac:

/etc/X11/default-display-manager

But I have no idea where it is on the SD card. Any suggestions?

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: How do I stop the GUI automatically starting

Sat Dec 12, 2015 8:42 pm

k7n4n5t3w4rt wrote:Setting up a new Pi, I downloaded Noobs and selected Raspbian as the OS as I have done many times. It's pretty annoying that the gui now starts up automatically.
This is usually controlled using some sort of systemd thing. So I'd look at that. Whether or not old methods are made new again, that is the old way you used to do it suddenly works, I cannot say, but I guess we all need to give in to the tsunami and learn this new scheme. Next week, upstart is back again! (I keed, I keed)

User avatar
rpdom
Posts: 14994
Joined: Sun May 06, 2012 5:17 am
Location: Chelmsford, Essex, UK

Re: How do I stop the GUI automatically starting

Sat Dec 12, 2015 8:52 pm

Try Ctrl-Alt-F2 to get to a virtual console. Then log in as "pi" and "sudo raspi-config"

Ctrl-Alt-F7 should get you back to the desktop afterwards, or you could just "sudo reboot" to make the changes take effect.

k7n4n5t3w4rt
Posts: 7
Joined: Sat Dec 12, 2015 7:34 pm

Re: How do I stop the GUI automatically starting

Sun Dec 13, 2015 3:00 am

Thanks rpdom, I'd try that if the keyboard had any effect at all.

Maybe I'll try another. This one used to work fine with the pi when Raspbian didn't fire up the GUI automatically.
rpdom wrote:Try Ctrl-Alt-F2 to get to a virtual console. Then log in as "pi" and "sudo raspi-config"

Ctrl-Alt-F7 should get you back to the desktop afterwards, or you could just "sudo reboot" to make the changes take effect.

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: How do I stop the GUI automatically starting

Sun Dec 13, 2015 3:27 am

k7n4n5t3w4rt wrote:Thanks rpdom, I'd try that if the keyboard had any effect at all.
So when you hit caps lock, the light doesn't go on? If the ctrl-alt-F4 or other choices don't work, you've got to look at the flash drive by mounting it somewhere loop. (Or try a different flash drive or something that direction)

The img isn't just one partition, it could be several so you'll need to find out the offset when you mount everything. In any case, do that and then go in and change the target so it doesn't boot to the GUI. If you mount it on an x86 box, you won't be able to chroot to run the systemd config program or the raspberry pi one so you'll have to figure out how to change the target by hand directly. At least I think this is the situation, if someone else has a different plan by all means try that.

k7n4n5t3w4rt
Posts: 7
Joined: Sat Dec 12, 2015 7:34 pm

Re: How do I stop the GUI automatically starting

Sun Dec 13, 2015 10:23 am

It worked! Thanks rpdom.

I did Ctrl-Alt-F2 while it was booting up and it recognised the keyboard and went into a virtual console without going into the GUI (I never did get the keyboard to work if it went into the GUI). Once once in the console, "sudo raspi-config" got me into the config interface and I set it to boot into console. Then a reboot and now it's all good.

Thanks again!
rpdom wrote:Try Ctrl-Alt-F2 to get to a virtual console. Then log in as "pi" and "sudo raspi-config"

Ctrl-Alt-F7 should get you back to the desktop afterwards, or you could just "sudo reboot" to make the changes take effect.

Shadow_7
Posts: 47
Joined: Sat Jul 12, 2014 5:50 am

Re: How do I stop the GUI automatically starting

Mon Dec 14, 2015 9:13 am

The more official way (at least in debian) is to populate this file with "false".

/etc/X11/default-display-manager

Although uninstalling a display manager works too. As previously mentioned. But then you install something that grabs a display manager and installs it as a dependency. Like many of the mainstream window managers / desktop environments. And you're back to square one.

$ sudo apt-get purge slim

As far as the keyboard, have you tried the usual?

$ sudo dpkg-reconfigure keyboard-configuration

Since my very first experience with raspbian was with the euro keyboard setup by default in my usa world. As in # and | aka number and pipe typed "other" characters.

These days I just do minimal debootstrap style installs. Running a wm in X and the install base is < 1GB (including downloaded .deb's). Which leaves plenty of room for useful things without the update hell that is an endless waiting game aka american ISPs.

stderr
Posts: 2178
Joined: Sat Dec 01, 2012 11:29 pm

Re: How do I stop the GUI automatically starting

Mon Dec 14, 2015 4:42 pm

Shadow_7 wrote:The more official way (at least in debian) is to populate this file with "false".
/etc/X11/default-display-manager
Does that work with systemd? When trying to get systemd to not start the GUI, I found so many different ways to stop it that didn't stop it that it was just amazing. This was with Ubuntu on x86 but the idea is similar.

User avatar
RaTTuS
Posts: 10412
Joined: Tue Nov 29, 2011 11:12 am
Location: North West UK

Re: How do I stop the GUI automatically starting

Mon Dec 14, 2015 4:50 pm

on new jessie - use
sudo raspbi-config
and disable it there
How To ask Questions :- http://www.catb.org/esr/faqs/smart-questions.html
WARNING - some parts of this post may be erroneous YMMV

1QC43qbL5FySu2Pi51vGqKqxy3UiJgukSX
Covfefe

PhoenixFireBird
Posts: 1
Joined: Mon Feb 15, 2016 6:04 pm

Re: How do I stop the GUI automatically starting

Mon Feb 15, 2016 6:06 pm

Thanks rpdom,

It worked, and now I am able to go to the command line and optionally get into GUI. :)

Return to “Raspbian”