LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices



Reply
 
Search this Thread
Old 09-14-2010, 07:47 AM   #1
Vilius
Member
 
Registered: Jan 2006
Location: Lithuania
Distribution: CentOS, Debian
Posts: 185

Rep: Reputation: 15
xdm init script problem - /var/run/xdm.pid is gone ?


Hello,

Running Debian lenny 64bit.
I start xdm:
Code:
# /etc/init.d/xdm start
Starting X display manager: xdm.
#
Process is started and xdm.pid is in place:
Code:
# ps -ef|grep xdm
root      3917     1  0 11:30 ?        00:00:00 /usr/bin/xdm
#
# ls /var/run|grep xdm
xdm.pid
#
Now I log in using xdm login dialog and log out. Lets check xdm:
Code:
# ps -ef|grep xdm
root      3917     1  0 11:30 ?        00:00:00 /usr/bin/xdm
#
# ls /var/run|grep xdm
#
xdm.pid is gone and if I try to stop xdm:
Code:
# /etc/init.d/xdm stop
Stopping X display manager: xdm not running (/var/run/xdm.pid not found).
#
Of course I can kill xdm but this is annoying. If I use invoke-rc.d - result is exactly the same.

Why xdm.pid is deleted while xdm continues to run ?
Possible to fix that ?

thanks
Vilius

Last edited by Vilius; 09-14-2010 at 07:49 AM.
 
Old 09-15-2010, 05:57 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 27,765
Blog Entries: 54

Rep: Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976Reputation: 2976
Quote:
Originally Posted by Vilius View Post
Why xdm.pid is deleted while xdm continues to run ?
"xdm does not properly check the pid in /var/run/xdm.pid" (2004): http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=270393 ("Severity set to wishlist")?


Quote:
Originally Posted by Vilius View Post
Possible to fix that ?
Wedging in a rather crude 'pgrep /usr/bin/xdm > /var/run/xdm.pid' at the top of the "stop" section could work as long as only one PID exists or the kill function will deal with killing multiple PIDs?
 
1 members found this post helpful.
Old 09-16-2010, 04:06 AM   #3
Vilius
Member
 
Registered: Jan 2006
Location: Lithuania
Distribution: CentOS, Debian
Posts: 185

Original Poster
Rep: Reputation: 15
Ok added this:
Code:
pgrep -f -n /usr/bin/xdm > /dev/null && pgrep -f -n /usr/bin/xdm > /var/run/xdm.pid
Works.
Thanks for idea.

Vilius
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] xdm init script problem - "invoke-rc.d xdm start" fails ? Vilius Debian 2 09-13-2010 01:15 AM
disabling XDM-AUTHORIZATION-1 in xdm shpenat Linux - Desktop 0 03-18-2009 10:11 AM
xdm missing from /etc/init.d..how do i get it back? flipwhy Linux - Newbie 1 09-01-2006 11:34 AM
rm cannot remove /var/run/atd.pid and /var/run/xdm.pid danishmr Linux - Software 1 05-04-2004 09:01 AM
XDM opens XDM after login jpbarto Linux - Software 1 01-26-2004 11:23 PM


All times are GMT -5. The time now is 01:14 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration