1

I've installed Debian on an old netbook of mine which I intend to turn into a thin client for a personal thingie while also having it ready to play a video or some music when needed.
After swimming against the current for hours, working around known bugs and getting wireless to work, I've finally come to a point where I can't find any more help on Google. (I've hardly used Linux)

I wish to boot into a terminal (like pressing Control + Alt + F1) by default, but also have the GUI (Gnome, in my case) loading in the background if possible (for quick access with Control + Alt + F7).
How do I do this?

Vercas
  • 111
  • 5

2 Answers2

1

You need to start Xorg with the -novtswitch option. If you're using lightdm as your display manager (which is a reasonable choice), edit /etc/lightdm/lightdm.conf, uncomment the xserver-command line in the [SeatDefaults] section and change it to

xserver-command=X -novtswitch

Set up autologin or not as desired.


This seems like a strange setup. There's no advantage to using the console if you're going to start an X server anyway. You might as well start the X server and open a terminal window, it'll be more comfortable at no extra cost.

Gilles 'SO- stop being evil'
  • 807,993
  • 194
  • 1,674
  • 2,175
  • I need a fullscreen terminal for my client app, and the GUI so my mother will not dissect me for not being able to watch her shows or read her recipes online. **Edit**: Also, I have no clue what "lightdm" is and the folder you mentioned doesn't exist. I use Gnome for the desktop, if it matters. – Vercas Mar 30 '14 at 09:15
  • I think X11 is my display manager. `/etc/X11` contains a file named `default-display-manager`. And the Debian wiki suggests the same: https://wiki.debian.org/DisplayManager – Vercas Mar 30 '14 at 09:45
  • @Vercas The display manager is the GUI program where you type your password. X11 is not a display manager. The display manager is the program mentioned in the file `/etc/X11/default-display-manager`. – Gilles 'SO- stop being evil' Mar 30 '14 at 12:55
  • It contains `/usr/sbin/gdm3`. – Vercas Mar 30 '14 at 14:59
  • @Vercas It seems that [Gdm3 doesn't allow customizing how the X server is executed](http://unix.stackexchange.com/questions/81096/how-to-make-gdm3-start-x-installed-in-a-different-path-or-running-x-from-a-pers). – Gilles 'SO- stop being evil' Mar 30 '14 at 15:36
  • So, does this mean that I can't do specifically what I want (loading GUI in background) or that I couldn't even possibly stop the GUI from loading? – Vercas Mar 30 '14 at 18:36
  • @Vercas With gdm, not easily. But you could switch to lightdm. For most users, the difference in functionality between lightdm, gdm and kdm isn't noticeable. – Gilles 'SO- stop being evil' Mar 30 '14 at 18:42
  • Switched to lightdm (double checked too) and changed command as you indicated. No effect. Also, in the replacement you indicated you removed the initial `x` (xcommand -> command). Is that on purpose? – Vercas Mar 31 '14 at 14:47
  • @Vercas That was a typo, it should be `xserver-command`. Does it work that way? (You need to restart lightdm for the change to take effect: `service restart lightdm`) – Gilles 'SO- stop being evil' Mar 31 '14 at 14:58
  • I restarted the laptop. I hope that's okay. When I try to restart the service, it says the service is not recognized. However, when I do `sudo service --status-all` I see ` [ + ] lightdm`. – Vercas Mar 31 '14 at 15:02
  • Also, I tried it *with* the `x` before. As stated, no changes whatsoever. :( – Vercas Mar 31 '14 at 18:27
  • I've actually made huge progresses... I got ONE step left... – Vercas Apr 01 '14 at 19:33
0

So, by empirical evidence, the GUI won't even start up properly unless I'm switched to it (VT7) during the loading, so I tried something else.

I used this to get tty1 and tty2 to autologin into my account.
Then I set up the file ~/.bash_profile with this code:

#!/bin/sh

if [ $(tty) = 'dev/tty1' ]
then
    echo "boot script yada yada on tty1"
else
    echo "Type 'startx' to get your GUI!"
fi

Then I instructed the other potential users of my netbook to press Control + Alt + F2 and Control + Alt + F7 to get around. (Taped sticky note...)

This is the best solution I've found so far.
If anyone posts a better (full) solution, it'll get all the cookies.

Vercas
  • 111
  • 5