Jump to content


Photo

Telling Ubuntu to be Headless


  • Please log in to reply
9 replies to this topic

#1 sluthy

sluthy

    Charge

  • Lurker
  • 264 posts

Posted 11 September 2008 - 07:22 AM

Can I just start by saying how annoyed I am at losing my Favourites list and having to remember all of my previous discussions etc, but anyway... I have an Ubuntu 8.04 box running as our home server. It was not going to have a monitor initially, then it was, now it isn't. The problem is, it runs fine normally when you take the monitor off and use VNC, but when it restarts, if it hasn't got a monitor attached, it doesn't load X or anything. The monitor has to be plugged in when it's turned on or else it just doesn't start properly. Is there any way to tell Ubuntu to keep it's 1280x1024-start-X whatever settings as if the monitor were there even when it isn't? Or am I going to have to swap the monitor onto it every time an update demands a restart?

#2 Linux_Inside V2

Linux_Inside V2

    Guru

  • Atomican
  • 16,187 posts

Posted 11 September 2008 - 08:05 AM

it's more likely that the machine isn't getting past the POST stage because Its detecting no monitor. Can you ssh in after booting with no monitor? Try pulling out the video card and turning it on, also set your bios to halt on no errors so even ifit isn't happy it will boot. Does vnc server attach to the x server these days? It's been such a long time since I've used it on Linux.

#3 sluthy

sluthy

    Charge

  • Lurker
  • 264 posts

Posted 11 September 2008 - 01:37 PM

No, it gets past the POST and everything, but it just gets to a bash prompt. The GUI doesn't load. Haven't tried ssh at all, and it's onboard graphics.

#4 garlic

garlic

    Master

  • Atomican
  • 765 posts

Posted 11 September 2008 - 06:42 PM

Sounds like it is booting fine. You will need to restart your VNC session every time the computer reboots however.

#5 lew~

lew~

    Champion

  • Atomican
  • 7,913 posts

Posted 11 September 2008 - 07:14 PM

Sounds like it is booting fine. You will need to restart your VNC session every time the computer reboots however.

It is booting fine. He's saying it's not starting X when a monitor isn't plugged in.

I think this post in this thread may help.

#6 GlennsPref

GlennsPref

    Overlord

  • Atomican
  • 2,173 posts

Posted 11 September 2008 - 11:06 PM

What gui's do you need to run on the headless machine, you may need a headless vnc server/client package. You don't need x on a headless server, afaik. regards, Glenn ps, or comment the load device lines in /ect/X11/xorg.conf for the monitor and graphics. You might be able to do that by just commenting this... Section "ServerLayout" Identifier "layout1" InputDevice "Keyboard1" "CoreKeyboard" InputDevice "Mouse1" "CorePointer" Screen "screen1" 0 0 EndSection
"Everything depends upon relative minuteness". Life is what "you" make of it. http://counter.li.org registered as GNU/Linux user #406321 Mageia1, kde4, openbox VirtualBox (non-ose AMD64) must read... http://www.religious....org/taoism.htm #(spiritual-stuff, it's good!) http://www.webofdebt...r-deception.php

#7 Redhatter

Redhatter

    Guru

  • Hero
  • 9,300 posts

Posted 12 September 2008 - 12:52 PM

I'm pretty sure the display managers just look for /usr/bin/X when starting the X server.

This will probably be a symlink to Xorg. Once upon a time, this used to be a symlink to one of a few servers (people might remember the old crew, XF86svga, XF86vga, XF86mono, XF86ati...etc, you may even remember Metrolink's MetroX) but since XFree86 4.0, we just have the one server.

My guess is if you blow away this symlink, and replace it with a link to Xvnc, it'll do what you want.
# rm /usr/bin/X && ln -sv $( which Xvnc ) /usr/bin/X

Stuart Longland (aka Redhatter, VK4MSL) I haven't lost my mind, it's backed up on a tape somewhere...

No longer active on these forums, see http://stuartl.longlandclan.yi.org/ for contact details.


#8 garlic

garlic

    Master

  • Atomican
  • 765 posts

Posted 12 September 2008 - 04:29 PM

Sounds like it is booting fine. You will need to restart your VNC session every time the computer reboots however.

It is booting fine. He's saying it's not starting X when a monitor isn't plugged in.

I think this post in this thread may help.


Yea I get that. I was under the impression when you establish an vnc server session it starts up a new display / x server, so you don't need X running? I run this setup at home with no problems??? maybe I am missing the point completely?

#9 eckythump

eckythump

    Primarch

  • Atomican
  • 1,902 posts

Posted 12 September 2008 - 09:36 PM

I have a colocation machine that unfortunately requires X for a stuipd java app to configure e-commerce merchants (Fuck you, and your GUI shite, Camtech!) I don't run/start X. I merely run/start vnc and it launches Xvnc. Configure your machine so it doens't start xdm/kdm/gdm/whatever, and configure it so it does start vnc. That should presumably solve the problem.
One good thing about V3 is that I no longer have to see this shit. :D

#10 Redhatter

Redhatter

    Guru

  • Hero
  • 9,300 posts

Posted 13 September 2008 - 05:51 PM

I have a colocation machine that unfortunately requires X for a stuipd java app to configure e-commerce merchants (Fuck you, and your GUI shite, Camtech!)


Heh... the IBM ServeRAID utilities are Java/Swing apps. I have to run them within a vncserver environment.

But for the original poster, another alternative would be to configure your display manager to not start X, but rather listen for XDMCP requests, then just set up Xvnc to query localhost in your /etc/rc.local (or equivalent, e.g. /etc/conf.d/local.start on Gentoo).

Stuart Longland (aka Redhatter, VK4MSL) I haven't lost my mind, it's backed up on a tape somewhere...

No longer active on these forums, see http://stuartl.longlandclan.yi.org/ for contact details.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users