How to debug X.org problems

I have just installed xorg, started up startx and the twm GUI came up. I then installed xfce, created a .xinitrc file

echo "exec /usr/local/bin/startxfce4 --with-ck-launch" > ~/.xinitrc

After running startx again the screen goes black, flashes, and then returns to the command prompt. Not sure what to do...

/var/log/Xorg.0.log is too long to post - what should I be looking for?
 
Any attempt to debug X needs two things. First, if you have an xorg.conf, post it. Then make /var/log/Xorg.0.log available on the web, like with pastebin.
 
There is no xorg.conf.

Xorg.0.log is here (it's quite long) :-

http://pastebin.com/BEac8WV3

Maybe this the most significant part...

Code:
[ 41093.234] (II) VESA(0): VESA VBE OEM: Intel(R) HSW Mobile/Desktop Graphics Chipset Accelerated VGA BIOS
 
Looking through Xorg.0.log

I see
Code:
    67.949] (EE) Failed to load module "fbdev" (module does not exist, 0)
....
....
    68.665] (EE) AIGLX: reverting to software rendering
 
I was a good idea to test if x11-wm/twm works. If yes there should be no basic issue related to X. Check if exec twm or exec /usr/local/bin/twm in ~/.xinitrc works. Then confirm that /usr/local/bin/startxfce4 exists and can be executed, just to be sure. If yes please verify if exec /usr/local/bin/startxfce4 --with-ck-launch is really the correct command to start xfce4. I am not using xfce4, therefore I am not sure.
 
If I remove ~/.xinitrc then twm comes up.

If I put exec /usr/local/bin/twm in ~/.xinitrc I just get a black screen and no response. Need to do a hard reset.
 
Interestingly if I comment out that line in ~/.xinitrc then X does not come up at all. If I delete the file then twm does come up...
 
Which Intel graphics hardware are you using? It's not clear to me from the log output you posted above. Better yet, can you post the output of pciconf -lv from the machine in question?
 
Code:
root@FreeBSD:/ # pciconf -lv
hostb0@pci0:0:0:0:    class=0x060000 card=0x30a317aa chip=0x0c008086 rev=0x06 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Haswell DRAM Controller'
    class      = bridge
    subclass   = HOST-PCI
vgapci0@pci0:0:2:0:    class=0x030000 card=0x30a317aa chip=0x04028086 rev=0x06 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Haswell Integrated Graphics Controller'
    class      = display
    subclass   = VGA
hdac0@pci0:0:3:0:    class=0x040300 card=0x30a317aa chip=0x0c0c8086 rev=0x06 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Haswell HD Audio Controller'
    class      = multimedia
    subclass   = HDA
xhci0@pci0:0:20:0:    class=0x0c0330 card=0x30a317aa chip=0x8c318086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point USB xHCI Host Controller'
    class      = serial bus
    subclass   = USB
none0@pci0:0:22:0:    class=0x078000 card=0x30a317aa chip=0x8c3a8086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point MEI Controller'
    class      = simple comms
uart2@pci0:0:22:3:    class=0x070002 card=0x30a317aa chip=0x8c3d8086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point KT Controller'
    class      = simple comms
    subclass   = UART
em0@pci0:0:25:0:    class=0x020000 card=0x30a317aa chip=0x153a8086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Ethernet Connection I217-LM'
    class      = network
    subclass   = ethernet
ehci0@pci0:0:26:0:    class=0x0c0320 card=0x30a317aa chip=0x8c2d8086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point USB Enhanced Host Controller'
    class      = serial bus
    subclass   = USB
hdac1@pci0:0:27:0:    class=0x040300 card=0x30a317aa chip=0x8c208086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point High Definition Audio Controller'
    class      = multimedia
    subclass   = HDA
ehci1@pci0:0:29:0:    class=0x0c0320 card=0x30a317aa chip=0x8c268086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point USB Enhanced Host Controller'
    class      = serial bus
    subclass   = USB
isab0@pci0:0:31:0:    class=0x060100 card=0x30a317aa chip=0x8c4e8086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point LPC Controller'
    class      = bridge
    subclass   = PCI-ISA
ahci0@pci0:0:31:2:    class=0x010601 card=0x30a317aa chip=0x8c028086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point 6-port SATA Controller 1 [AHCI mode]'
    class      = mass storage
    subclass   = SATA
none1@pci0:0:31:3:    class=0x0c0500 card=0x30a317aa chip=0x8c228086 rev=0x04 hdr=0x00
    vendor     = 'Intel Corporation'
    device     = 'Lynx Point SMBus Controller'
    class      = serial bus
    subclass   = SMBus
 
X :0 in console 1 gives me a black screen and I am unable to input anything via the keyboard.

ISTR that Ctrl-Alt-Bkspc could break you out of Xwindows... I tried that but it didn't work. Maybe there is some other shortcut..
 
Ctrl-Alt-Fn1 doesn't take you back to console 1 ? It cannot open keyboard then
(nothing in the log suggests that, though)

Juha

Baroque stuff needed for the backspace zapping
/usr/local/etc/X11/xorg.conf.d/keyboard.conf
Code:
Section "InputClass"
  Identifier  "KeyboardDefaults"
  Driver  "keyboard"
  MatchIsKeyboard "on"
  Option  "XkbLayout" "fi"
  Option  "XKbOptions" "terminate:ctrl_alt_bksp"
EndSection
 
Dear balanga,
if this happens what Juha Nurmela describes
Ctrl-Alt-Fn1 doesn't take you back to console 1 ?
it could indicate that you are using the old sc console. May be you might want to enable vt by adding
Code:
kern.vty=vt
to /boot/loader.conf. It likely avoids the black screen as below.
If I put exec /usr/local/bin/twm in ~/.xinitrc I just get a black screen and no response. Need to do a hard reset.
If X crashes or other bad things happen it should be possible to return to the console using vt.
 
Back
Top