You are not logged in.

#1 2009-05-31 22:52:44

MW
Member
Registered: 2007-07-27
Posts: 127

Restarting X

I'm a seasoned Linux user, but for the life of me I cannot figure out why I cannot restart X on my media server.

When I restart X from CLi or with Alt+Ctrl+Del I just get a blank screen.
Error when trying to restart X manually:

# /etc/rc.d/kdm restart
:: Stopping KDE Display Manager                                                                                                                                                      [DONE]
:: Starting KDE Display Manager                                                                                                                                                      [FAIL]

I have had this problem now for over 2 years on Arch (Gentoo on desktop machine), but recently it is getting the better of me since there were a few updates that needed a X restart and then epic fail.

The only problem I can see in kdm.log:

(EE) Failed to load module "freetype" (module does not exist, 0)                                   
Link points to "/tmp/kde-root"                                                                     
error setting MTRR (base = 0xe0000000, size = 0x007d0000, type = 1) Invalid argument (22)          

Backtrace:
0: /usr/bin/X(xorg_backtrace+0x3b) [0x813278b]
1: /usr/bin/X(xf86SigHandler+0x51) [0x80dda61]
2: [0xb8049400]                               
3: /usr/lib/xorg/modules//libshadow.so(shadowRemove+0x4e) [0xb7b05f1e]
4: /usr/lib/xorg/modules//libshadow.so [0xb7b063c4]                   
5: /usr/bin/X [0x80bf247]                                             
6: /usr/bin/X [0x81100dc]                                             
7: /usr/bin/X [0x811c2bc]                                             
8: /usr/bin/X [0x8122d4c]                                             
9: /usr/bin/X [0x80df95e]                                             
10: /usr/lib/xorg/modules/drivers//vesa_drv.so [0xb7b14ae2]           
11: /usr/bin/X [0x80bd71b]                                            
12: /usr/bin/X [0x815f22b]                                            
13: /usr/bin/X [0x80c2d48]                                            
14: /usr/bin/X [0x80ce723]                                            
15: /usr/bin/X [0x8148675]
16: /usr/bin/X [0x81798dc]
17: /usr/bin/X [0x814245b]
18: /usr/lib/xorg/modules/extensions//libglx.so [0xb7b6356a]
19: /usr/bin/X(main+0x44c) [0x8071fcc]
20: /lib/libc.so.6(__libc_start_main+0xe5) [0xb7c1a6c5]
21: /usr/bin/X [0x8071401]

Fatal server error:
Caught signal 11.  Server aborting

Have no idea where to start looking on Arch for the problem, any help?

Offline

#2 2009-05-31 23:05:09

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: Restarting X

Just for clarification:  you can boot into X, right?  You can stop X (via e.g. /etc/rc.d/kdm stop) with no problem, but when you try to start it again you get a blank screen?  And what exactly do you mean by "blank"?

Try bringing down the X server and starting it again with xinit instead of kdm.

Offline

#3 2009-05-31 23:15:07

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Restarting X

I think that C-A-Backspace kills X, not C-A-Del.
http://bbs.archlinux.org/viewtopic.php?id=73064

Offline

#4 2009-05-31 23:33:36

MW
Member
Registered: 2007-07-27
Posts: 127

Re: Restarting X

Blank as in nothing, black.

Yes, starting up or restarting the machine loads X fine.

Very strange indeed, if I try and kill X it re-spawns almost immediately. I cannot seem to make any headway with xinit because of this.
sad

EDIT:
Ctrl+Alt+Backspace then, spelling mistake/lapse of concentration when typing, whatever, you should know where I was going with this anyway.

Last edited by MW (2009-05-31 23:35:34)

Offline

#5 2009-05-31 23:35:43

Peasantoid
Member
Registered: 2009-04-26
Posts: 928
Website

Re: Restarting X

Try switching to a VC (f.e. ctrl-alt-F1), logging in, and then running `kill` on the X process?

Offline

#6 2009-05-31 23:49:32

MW
Member
Registered: 2007-07-27
Posts: 127

Re: Restarting X

Nope, does not work in bringing down X, as soon as I try to kill X, kdm or even the session it just re-spawns.

This is frustrating...
hmm

Offline

#7 2009-06-01 07:26:47

Gen2ly
Member
From: Sevierville, TN
Registered: 2009-03-06
Posts: 1,529
Website

Re: Restarting X

Probably needs a delay.  From console I'd try:

/etc/rc.d/kdm stop && sleep 5 && /etc/rc.d/kdm start

Last edited by Gen2ly (2009-06-01 07:27:29)


Setting Up a Scripting Environment | Proud donor to wikipedia - link

Offline

#8 2009-06-01 08:28:07

vries
Member
Registered: 2008-04-20
Posts: 8

Re: Restarting X

Have you tried to comment out "freetype" module in your xorg.conf? I think it was removed from xorg 1.6.

Offline

#9 2009-06-01 09:52:53

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Restarting X

I'm not using KDE but maybe somebody can help you if you post the relevant (kdm?) configs.

@vries
IIRC type1 was removed and you have to install freetype separately.

Offline

#10 2009-06-01 14:13:59

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: Restarting X

Can you stop X with "/etc/rc.d/kdm stop"?  I think display managers usually are responsible for the respawning action.

Offline

#11 2009-06-01 15:59:54

broch
Banned
From: L.A. California
Registered: 2006-11-13
Posts: 975

Re: Restarting X

first question would be related to your VGA video:
1) can you see debug info while starting OS (before X loads)
2) while on X can you see leftovers from debug in F1

if you don't, then I would think that your VGA resolution is messed up. If this is the only issue, it is easy to fix by editing kernel line in boot loader and setting vga ask.

Try switching to a VC (f.e. ctrl-alt-F1), logging in, and then running `kill` on the X process?
..
Nope, does not work in bringing down X, as soon as I try to kill X, kdm or even the session it just re-spawns.

I am not sure how you get X on vc1, by default it should be vc7, so the question asked still makes sense.

I think that C-A-Backspace kills X, not C-A-Del.
http://bbs.archlinux.org/viewtopic.php?id=73064

Because OP mentioned that problem exists for the last two yrs, then any suggestion about CAB is irrelevant to the problem.

Offline

#12 2009-06-01 18:05:33

MW
Member
Registered: 2007-07-27
Posts: 127

Re: Restarting X

Gen2ly wrote:

Probably needs a delay.  From console I'd try:

/etc/rc.d/kdm stop && sleep 5 && /etc/rc.d/kdm start

Nope, same failure.

Have you tried to comment out "freetype" module in your xorg.conf? I think it was removed from xorg 1.6.

I cannot see how this could be the cause since it is only a font module, but to be complete I did comment it out and still the same problem.

I'm not using KDE but maybe somebody can help you if you post the relevant (kdm?) configs.

The only config file I know of is /etc/rc.d/kdm , and it is dead standard, nothing tinkered or changed in the file:

#!/bin/bash

. /etc/rc.conf
. /etc/rc.d/functions

PID=`pidof -o %PPID /usr/bin/kdm`
case "$1" in
  start)
    stat_busy "Starting KDE Display Manager"
    [ -z "$PID" ] && /usr/bin/kdm &>/dev/null
    if [ $? -gt 0 ]; then
      stat_fail
    else
      echo $PID > /var/run/kdm.pid
      add_daemon kdm
      stat_done
    fi
    ;;
  stop)
    stat_busy "Stopping KDE Display Manager"
    [ ! -z "$PID" ]  && kill $PID &> /dev/null
    if [ $? -gt 0 ]; then
      stat_fail
    else
      rm_daemon kdm
      stat_done
    fi
    ;;
  restart)
    $0 stop
    sleep 3
    $0 start
    ;;
  *)
    echo "usage: $0 {start|stop|restart}"
esac
exit 0

Can you stop X with "/etc/rc.d/kdm stop"?  I think display managers usually are responsible for the respawning action.

Yes and no.
Yes is gives confirmation that it stopped kdm, but if you fire up top I notice that it just re-spawned kdm automagically. No matter how I try and kill or stop kdm, X or even VC:7, it just keeps on re-spawning.

first question would be related to your VGA video:
1) can you see debug info while starting OS (before X loads)
2) while on X can you see leftovers from debug in F1

No debug/leftovers except the one I posted earlier, other than that, nothing.

Going to try the boot loader option, so lets see how this goes.

Offline

#13 2009-06-01 19:56:07

broch
Banned
From: L.A. California
Registered: 2006-11-13
Posts: 975

Re: Restarting X

I was thinking about standard kernel info printed during boot process. If you can see this, then video resolution is set correctly and problem lays somewhere else. If you can't see standard kernel information printed during boot process, then probably you have incorrectly set vga resolution.

Offline

#14 2009-06-01 20:56:30

karol
Archivist
Registered: 2009-05-06
Posts: 25,440

Re: Restarting X

Is it possible that sth in f.e. .bashrc is automatically doing this respawning stuff?

(a slightly modified piece of http://dotfiles.org/~brisbin33/.bashrc)

while [[ -z "$DISPLAY" ]] && [[ $(tty) = /dev/vc/1 ]]; do
  startx
done

If you log into vc/2 and startx from CLI will this start X (I have no idea how kdm works)? Can you restart it then or do you run into the same problems?

Last edited by karol (2009-06-01 21:14:27)

Offline

#15 2009-06-02 00:12:29

Trent
Member
From: Baltimore, MD (US)
Registered: 2009-04-16
Posts: 990

Re: Restarting X

Can you start X from the command line after bringing up the machine without a graphical environment?  It seems strange that it would work during the boot process but not later.  Comment out the line in /etc/inittab that says 'id:5:initdefault:' and uncomment the one that says 'id:3:initdefault:'.  Save and reboot, it should drop you to a console with nothing on vc/7.

You may also try 'xinit -- :1' which will start a new X server on a different display that doesn't interfere with the currently running one.

I'm not sure why you can't stop kdm, but then I haven't used it in at least three years.  I think that would be configured in inittab as well; hopefully somebody else can help here.

Offline

Board footer

Powered by FluxBB