LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
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, 06:47 AM   #1
Vilius
Member
 
Registered: Jan 2006
Location: Lithuania
Distribution: Arch, Debian
Posts: 193

Rep: Reputation: 16
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 06:49 AM.
 
Old 09-15-2010, 04:57 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
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, 03:06 AM   #3
Vilius
Member
 
Registered: Jan 2006
Location: Lithuania
Distribution: Arch, Debian
Posts: 193

Original Poster
Rep: Reputation: 16
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



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 12:15 AM
disabling XDM-AUTHORIZATION-1 in xdm shpenat Linux - Desktop 0 03-18-2009 09:11 AM
xdm missing from /etc/init.d..how do i get it back? flipwhy Linux - Newbie 1 09-01-2006 10:34 AM
rm cannot remove /var/run/atd.pid and /var/run/xdm.pid danishmr Linux - Software 1 05-04-2004 08:01 AM
XDM opens XDM after login jpbarto Linux - Software 1 01-26-2004 10:23 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 01:35 AM.

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
Open Source Consulting | Domain Registration