I would like to start Debian without the GUI and then just type commands in to launch the desired programs (which are located on my local machine), eg
$ chromium-browser &
I already do a similar thing when sshing in to other machines on the LAN - it is handy if I need to visualise csv data for example in soffice. i currently have gnome desktop and Debian 7 installed.
I have found some instructions for disabling the GUI on startup with Debian, however I am reluctant to try them out for fear of being locked out of using the web browser once I do this (I will need it to seek help using the browser if I get stuck).
I was wondering if I could temporarily test out the method of starting the GUI on one of the other terminals (eg ctrl+alt+f1) to see if there are any problems? Will this work? Will it be equivalent to starting the GUI when booting without a GUI?
If this is feasible, please could someone provide full instructions for:
- enabling the GUI on terminal f1so that i can run gui programs (without showing the full desktop interface)
- turning off the desktop interface GUI on bootup
obviously I will need to run X11 to load GUI programs - that's fine, but I'm looking to boot up into text mode and then just execute GUI programs as needed.
doing some tests on an ubuntu 12.04 virtualbox vm (hopefully not too different to debian 7?)...
$ ps aux | grep gdm
# *blank*
$ ps aux | grep kdm
# *blank*
$ ps aux | grep lightdm
root      1225  0.0  0.0 270664  3500 ?        Ssl  12:43   0:00 lightdm
root      1234  1.9  2.2 236564 112276 tty7    Ss+  12:43   0:01 /usr/bin/X :0 -auth /var/run/lightdm/root/:0 -nolisten tcp vt7 -novtswitch -background none
root      1382  0.0  0.0 156772  3572 ?        Sl   12:43   0:00 lightdm --session-child 12 19
$ sudo update-rc.d lightdm disable
update-rc.d: warning: /etc/init.d/lightdm missing LSB information
update-rc.d: see <http://wiki.debian.org/LSBInitScripts>
 Disabling system startup links for /etc/init.d/lightdm ...
 Removing any system startup links for /etc/init.d/lightdm ...
   /etc/rc0.d/K20lightdm
   /etc/rc1.d/K20lightdm
   /etc/rc2.d/K80lightdm
   /etc/rc3.d/K80lightdm
   /etc/rc4.d/K80lightdm
   /etc/rc5.d/K80lightdm
   /etc/rc6.d/K20lightdm
 Adding system startup for /etc/init.d/lightdm ...
   /etc/rc0.d/K20lightdm -> ../init.d/lightdm
   /etc/rc1.d/K20lightdm -> ../init.d/lightdm
   /etc/rc6.d/K20lightdm -> ../init.d/lightdm
   /etc/rc2.d/K80lightdm -> ../init.d/lightdm
   /etc/rc3.d/K80lightdm -> ../init.d/lightdm
   /etc/rc4.d/K80lightdm -> ../init.d/lightdm
   /etc/rc5.d/K80lightdm -> ../init.d/lightdm
$ sudo shutdown -r 0
and the gui is back up and running again after the reboot! so this clearly did not have the desird effect. however:
$ sudo /etc/init.d/lightdm stop
kills the gui. moving to tty2 (by pressing ctrl+alt+f2) and attempting to open firefox:
$ firefox &
Error: no display specified
so attempting to specify a display:
$ export DISPLAY='0.0'
$ firefox &
Error: cannot open display: 0.0
and now i'm stuck. i can still get the gui back on ctrl+alt+f7 by entering the following into tty2:
$ sudo /etc/init.d/lightdm start
but this is not what i want. i just want to be able to run firefox without showing all the other desktop things such as the clock and the menu bars, etc.
trying out some of the things in goldilocks' answer
$ sudo /etc/init.d/lightdm stop
$ echo "#!/bin/bash" > ~/.xinitrc
$ echo "exec firefox" >> ~/.xinitrc
$ xinit
this does exactly what i want :)


startxafter logging in, but you still need X running to be able to do anything useful with programs relying on an X display being available. This may or may not be what you want so please clarify. Maybe simply switching to a lightweight WM will do what you want?ssh. i'm fine with the method of running x locally. i'd rather not install new wm unless its absolutely necessary for this. my thinking was that i would be able to alter some config settings but not have to install anything new as i already have the gnome desktop gui running.service gdm3 stopas root. A normal user can start X with "startx".