LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
Search this Thread
Old 06-25-2008, 10:04 AM   #1
johg
LQ Newbie
 
Registered: Jun 2008
Posts: 2

Rep: Reputation: 0
Check wether a X server is running and ok


Basically I need a more reliable way to check wether a X server is ok than using ps/pgrep.
Is there a (standard) application which connects to a X server and exits again giving me the status? Something like "xterm -e exit".
 
Old 06-25-2008, 10:27 AM   #2
solarkash
LQ Newbie
 
Registered: Jun 2008
Posts: 11

Rep: Reputation: 1
# xset -q

( q - for query )

It works good for me. The only case it is missing is the shortage of file descriptors.
 
Old 06-25-2008, 04:42 PM   #3
marozsas
Senior Member
 
Registered: Dec 2005
Location: Campinas/SP - Brazil
Distribution: SuSE, RHEL, Fedora, Ubuntu
Posts: 1,393
Blog Entries: 1

Rep: Reputation: 64
what about ....
Code:
export DISPLAY=":0.0"
xdpyinfo
(running on a tty, not on a terminal inside X)
 
Old 06-29-2008, 02:32 PM   #4
johg
LQ Newbie
 
Registered: Jun 2008
Posts: 2

Original Poster
Rep: Reputation: 0
Thanks, both answers answer my question and I appreciate your help.
 
  


Reply

Tags
code, exit, server, status, x11


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
How to check uptime of all applications running in solris server rajaniyer123 Solaris / OpenSolaris 1 10-13-2007 12:37 AM
Check yor dcop server is running error messae dazpaul2222 Linux - Newbie 6 01-16-2007 06:26 PM
Health Check / Server Completion Check Software? tells Linux - Enterprise 0 04-20-2006 12:03 PM
ethernet, unsure wether it is working for me Michael_aust MEPIS 2 01-09-2006 04:50 AM
How can I check wether a file is empty in Linux by using shell script programming ??? Bassam Linux - General 2 02-26-2004 02:01 AM


All times are GMT -5. The time now is 04:11 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