Display number with inetd
Fri Aug 30 23:38:01 2002
The Way I do it is:
Have a shell script running another shell script
The first one is setup without the & then a $0 next line to reload this
Now the second file
Runs Xvnc with the commands.
/usr/local/bin/Xvnc :1 -geometry 1024x768 -depth 16 -once -query
localhost -httpd /usr/local/vnc/classes -httpport 5801 -dontdisconnect
-nevershared -fp tcp/localhost:7100
Notice the once is so when I exit the window manager it closes the
session, and that is where the first file takes over an runs another
one. And also notice the dontdisconnect and nevershared. Also note that
I don't use a vnc password, as they get the Solaris dtlogin screen, and
then all is under the user context. Note, these servers are training
boxes and db boxes so security is not really an issue.
From: firstname.lastname@example.org [mailto:email@example.com] On
Behalf Of William Hooper
Sent: Friday, August 30, 2002 4:57 PM
Subject: Re: Display number with inetd
----- Original Message -----
From: "Marc Mazas" <firstname.lastname@example.org>
Sent: Friday, August 30, 2002 12:12 PM
Subject: TR : Display number with inetd
> In my case, the display number is a fixed configuration parameter of
> Apache Jserv server, and there is only one X client for all the server
> (I assume a servlet), not one X client for each real user. I had the
> idea to use inetd in order to have it relaunch the vnc server in case
> Xvnc terminated for any reason, and thus to hope the application will
> continue to work. So I would have to use the :2 display number, but I
> cannot guarantee it will always be this one ...
If your goal is to always be sure a VNC stays running then you should be
able to do this with a shell script. I haven't tried it, but what comes
mind is run the vncserver command with the hardcoded display "vncserver
in a cron job every 5 minutes or so. You could keep track of it by
something like I saw on the Redhat Valhalla list here:
Also out of curiosity, have you had trouble with Xvnc terminated?
start one session and have it running continuously and I can say that
had over 100 days of uptime without VNC causing problems.
Give a man a match, you keep him warm for an evening.
Light him on fire, he's warm for the rest of his life.
VNC-List mailing list