1

in Debian Lenny, using TightVNC 1.3.9 I can setup a VNC server manually by using

vncserver -query localhost -once -geometry 1024x768 -depth 16 :1

But then, as I have read is a better option, I use xinetd with the following configuration:

 service vnc-1024x768x16
  {
    protocol = tcp
    socket_type = stream
    wait = no
    user = nobody
    server = /usr/bin/vncserver
    server_args = -inetd -query localhost -once -geometry 1024x768 -depth 16
  }

I have open port 5901 to connect to the server. With first way (vncserver alone) I manage to connect to my server succesfully.

But with xinetd way I just can't connect.

Externally I can see that port 5901 is open and even that VNC service is available. Looking at VNC log generated for the :1 display I haven't found anything.

In fact, I was considering that the problem was with xinetd, but I have other services setted up with it (telnet & ftp for example) and I can use them correctly.

So now I'm lost with this, what else am I not considering with VNC service through xinetd? Where can I find logs or useful information to get a clue about this problems?

Any ideas?

Thanks for reading...


UPDATES (nov-29-'10):

-Manage to get an X display, but with no login screen or terminal to run any commands by changing

user = my_user_name
server = /usr/bin/Xvnc
server_args = -inetd -once -geometry 1024x768 -depth 16 -rfbauth=/home/my_user_name/.vnc/passwd

this Xvnc server is another VNC program (not Xtightvnc which I prefer...) The username changed so I can use my auth file, stored in the passwd file

If I run manually Xvnc, with the additional parameter -query localhost (and no -inetd one), I get a login screen! But with Xvnc is very laggy... with Xtightvnc I get a faster connection...

Whatever, setting the -query localhost parameter in the xinted.d configuration file, I get nothing again, not an X display screen, no login screen nor terminal...

As far as I understand, -query localhost lets me use XDCMP for the login screen or terminal, but it's not working with xinetd.d

And a collateral problem: now I get the message

XDMCP fatal error: Session declined Maximum number of open sessions from your host reached

So I cannot do more test right now... Googleing a little I learned it's about the number of maximum XDMCP sessions allowed. But I've only found how to increase this number, and right now I need just to know how to kill current XDMCPsessions, any ideas?

Thanks again!

Javier Novoa C.
  • 367
  • 1
  • 6
  • 18

1 Answers1

0

Well, I think I managed to get a compromise solution for this:

using the following configuration I can get a login screen:

service vnc-1024x768x16
{
  protocol = tcp
  socket_type = stream
  wait = no
  user = user_name
  server = /usr/bin/Xvnc
  server_args = -inetd -query localhost -once -geometry 1024x768 -depth 16 -rfbport=5901 -rfbauth=/home/user_name/.vnc/passwd
  disable = no
}

Looking at this tutorial, I can observe that the solution is similar. I even noticed that they aren't using vncserver as I was looking for (since I use vncserver to run manually the VNC server, without xinetd).

Looking at the man page of vncserver, they say that in fact this program is a wrapper for Xvnc. However, when I run vncserver alone, it calls a program named Xtightvnc, not Xvnc.

Changing the 'server' line in the above configuration to call Xtightvnc instead of Xvnc gives me no connection, so I still will have to carry on with Xvnc.

The other big difference I noticed between using Xtightvnc and Xvnc is that the last one makes a pretty slow connection, so I still prefer Xtightvnc...

By now, I can handle this a little bit better, but any further ideas are welcome too...

BTW, I discovered that Xvnc is in fact RealVNC for my machine, not TightVNC as I desired, guess I'll have to look more on how to redirect things well, also on how to use Xtightvnc as I desire...

Thanks for reading...

just as a colophon... I finally got to get Xtightvnc to work. The problem? In the xinetd server_args configuration line doesn't accepts the '=' character for assigning value to parameters! :D so the final result is:

service vnc-1024x768x16
{
  protocol = tcp
  socket_type = stream
  wait = no
  user = user_name
  server = /usr/bin/Xvnc
  server_args = -inetd -query localhost -once -geometry 1024x768 -depth 16 -rfbport 5901 -rfbauth /home/user_name/.vnc/passwd
  disable = no
}

I also had to change the Xvnc soft link, which was pointing to Xvnc4 (realvnc) so it finally pointed to Xtightvnc...

Javier Novoa C.
  • 367
  • 1
  • 6
  • 18