Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I use my old computer as an NAS, so I remove the monitor after I installed linux on it (disconnect vga cable). I use ssh to control the machine and it works fine. Until some day, after kernel/softare upgrade or messing up some configs, I cannot connect to it through ssh, then I have to plug the monitor back, but the monitor says "No input signal". So I have to restart the computer WITH the monitor connected, and the monitor's back!

I think the computer/linux kernel doesn't detect the monitor plug-in event. So how can I start my linux box without a monitor, but when it goes wrong I can still plug my monitor (vga) back and use the console.

Edit: just one pci-e video card, has dvi, vga, tv/out (s-video)

Edit2: Xorg is not running. I just need the console (CTRL+ALT+F1). The problem is, if the machine booted without a monitor connected, it won't give me a pseudo terminal after I attach the vga cable while it's running. Clearly the monitor is not auto detected as usb device. I'm wondering how to let the monitor auto detected.

share|improve this question
    
Toni: Does this computer with Linux have two video cards? (onboard and expansion slot) or perhaps two video ports (DSUB and DVI)? – deltaray Mar 19 '11 at 14:02
    
Do you also connect a keyboard at the same time as the monitor, or have one connected all the time? It could well be failing to detect a keyboard and deciding to use serial console. There should be a setting in Grub to force VGA console. – Majenko Mar 19 '11 at 15:14
    
@MattJenkins: how to force VGA console? – yaroot Mar 19 '11 at 15:38
    
If I knew that I'd have put it in my comment. – Majenko Mar 19 '11 at 15:42

Do you have an xorg.conf file, or do you let X auto-detect the configuration? Recent Linux distributions use a version of X that auto-detects your configuration so an xorg.conf file is not necessary. But if X is auto-detecting, it probably doesn't see a monitor so it can't start. Try creating an xorg.conf file manually, or use this to have Xorg generate one for you:

Xorg :1 -configure
cp /root/xorg.conf.new /etc/X11/xorg.conf

I haven't tried this without a monitor present so I'm not sure it will work. You might also need to restart X after plugging in the monitor, by pressing CTRL+ALT+Backspace on the keyboard.

share|improve this answer
    
As it's an NAS, it doesn't need GUI, so xorg is not running. And, CTRL+ALT+Backspace it not working with recent version of xorg. – yaroot Mar 19 '11 at 15:14

If you are talking about the X server running then this is normal behaviour.

X tries to load but since you do not have the screen connected it fails...usually there is a maximum number of tries for that from which on it fails and stops.

However, the system is left at with a blank screen. So when you connect you are probably getting at best case a blinking cursor.

The pseudo terminals should be visible though. Try CTRL+ALT+F2 , F3 ... should give something.

If this does not work then it seems that for some reason the pseudo-terminals have failed. I cannot know the reason for that. You should post more details, i.e. /var/log/messages.

Normally you should start your system at runlevel 3 .

share|improve this answer

This maybe years too late however I was coming across the same issue when I ran into this question but no suitable answer has been given, and I imagine other people having the same problem have came across this question as well.

My fix that seems to work brilliantly is to trick the kernel into thinking a VGA is already connected by adding a kernel parameter (this might be specified in the grub configuration file) which is

video=VGA-1:e

the video parameter could be specified more than once for the kernel so if you already have a video= parameter then just add a new video= parameter (unless of course the existing parameter you believe would conflict with the above fix)

share|improve this answer

adam3141's answer is great! I still don't have enough reputation to up-vote it but it's definitly the best answer for this problem I've been looking for days!

The solution works both if a monitor is connected or not, and in both cases you can remote connect with x11vnc. It also allows to connect a monitor AFTER the X server has been started if needed.

By default, with this configuration, the X server will use a 1024x768 resolution because it cannot read the supported resolutions from the monitor. To fix this you can change the configuration of the default monitor in /etc/X11/xorg.conf (create the file if it does not exist) and add the modelines to support the resolutions you want. For example:

Section "Monitor"
    Identifier "<default monitor>"
    Modeline "1680x1050" 146.25 1680 1784 1960 2240 1050 1053 1059 1089
EndSection

By the way, you can find more info on the "video" kernel parameter here: http://distro.ibiblio.org/fatdog/web/faqs/boot-options.html

share|improve this answer
    
Not being able to vote or comment yet doesn't justify posting answers that are actually comments. – Julie Pelletier May 29 at 2:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .