[DragonFlyBSD - Bug #3300] Running Xvnc from TigerVNC package through the INETD daemon in TCP WAIT mode fails hard

bugtracker-admin at leaf.dragonflybsd.org bugtracker-admin at leaf.dragonflybsd.org
Thu Jul 11 10:57:17 PDT 2024


Issue #3300 has been updated by adrian.


saper wrote in #note-4:
> Sorry the formating for the last one is wrong:
> 
> To sum up:
> 
> [...]
> 
> argv0 is usually a program name and is not used a "real" parameter.

Hello Saper,

thank you for your input.

I changed my inetd.conf stanza line in the way you suggested, but I can still only get the 'nowait' mode to run,
'wait' mode still fails with:

Jul 11 19:50:19 dragonflybsd Xvnc[4697]: TcpSocket: unable to get peer name for socket
Jul 11 19:50:19 dragonflybsd Xvnc[4697]: TcpSocket: unable to get peer name for socket
Jul 11 19:50:19 dragonflybsd Xvnc[4697]: Connections: accepted: ::0
Jul 11 19:50:19 dragonflybsd Xvnc[4697]: TcpSocket: unable to get peer name for socket
Jul 11 19:50:19 dragonflybsd Xvnc[4697]: VNCSConnST: Failed to flush remaining socket data on close: write: Broken pipe (32)
Jul 11 19:50:19 dragonflybsd Xvnc[4697]: Connections: closed: ::0
Jul 11 19:50:19 dragonflybsd inetd[4149]: 5916/tcp server failing (looping), service terminated

Thank you.

Sincerely,

Adrian Kieß

----------------------------------------
Bug #3300: Running Xvnc from TigerVNC package through the INETD daemon in TCP WAIT mode fails hard
http://bugs.dragonflybsd.org/issues/3300#change-14559

* Author: adrian
* Status: Feedback
* Priority: Normal
* Target version: 6.4
* Start date: 2021-10-25
----------------------------------------
System environment:

<pre>
root at dragonflybsd /home/adrian # uname -a
DragonFly dragonflybsd.v-zone.lan.dac 6.0-RELEASE DragonFly v6.0.1-RELEASE #1: Thu Oct 14 18:25:27 CEST 2021 adrian at dragonflybsd.v-zone.lan.dac:/usr/obj/usr/src/sys/X86_64_GENERIC x86_64
</pre>

Running DragonFlyBSD inside a Debian KVM virtualization as a guest with hardware acceleration,
I can't run Xvnc (from the TigerVNC package) in WAIT mode using the INETD daemon supplied with the base system.

Running XVnc from INETD in NOWAIT mode works fine though! It is only about the WAIT mode, and I would like to use the WAIT mode, to have a long lasting Xorg session.

Here is my stanza from /etc/inetd.conf, to reproduce the error.

At first, the working stanza — in NOWAIT mode:

<pre>
5916            stream          tcp             nowait          adrian          /usr/libexec/tcpd               /usr/local/bin/Xvnc     :16 -inetd -desktop dragonflybsd.v-zone.lan.dac:16 -query localhost -once -geometry 1680x1050 -depth 24 -rfbauth /home/adrian/.vnc/passwd -rfbport 5916 -Log *:syslog:30
</pre>

Now, the NOT working stanza, in WAIT mode:

<pre>
5916            stream          tcp             wait          adrian          /usr/libexec/tcpd               /usr/local/bin/Xvnc     :16 -inetd -desktop dragonflybsd.v-zone.lan.dac:16 -query localhost -once -geometry 1680x1050 -depth 24 -rfbauth /home/adrian/.vnc/passwd -rfbport 5916 -Log *:syslog:30
</pre>

Running the second command through the INETD daemon, /var/log/messages gets flooded by the constantly restarting Xvnc with this:
<pre>

Oct 25 18:51:01 dragonflybsd Xvnc[10132]: warning: can't get client address: Socket is not connected
Oct 25 18:51:01 dragonflybsd inetd[9859]: /usr/libexec/tcpd[10132]: exited, status 1
Oct 25 18:51:01 dragonflybsd Xvnc[10133]: warning: can't get client address: Socket is not connected
Oct 25 18:51:02 dragonflybsd inetd[9859]: /usr/libexec/tcpd[10133]: exited, status 1
Oct 25 18:51:02 dragonflybsd Xvnc[10134]: warning: can't get client address: Socket is not connected
Oct 25 18:51:02 dragonflybsd inetd[9859]: /usr/libexec/tcpd[10134]: exited, status 1
Oct 25 18:51:02 dragonflybsd Xvnc[10135]: warning: can't get client address: Socket is not connected
Oct 25 18:51:02 dragonflybsd inetd[9859]: /usr/libexec/tcpd[10135]: exited, status 1
Oct 25 18:51:02 dragonflybsd Xvnc[10136]: warning: can't get client address: Socket is not connected
Oct 25 18:51:02 dragonflybsd inetd[9859]: /usr/libexec/tcpd[10136]: exited, status 1
Oct 25 18:51:02 dragonflybsd inetd[9859]: 5916/tcp server failing (looping), service terminated
</pre>

Removing /usr/libexec/tcpd in beforehand of Xvnc, the error is this:

<pre>
Oct 25 18:52:11 dragonflybsd :16[10424]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10424]: Connections: closed: ::0
Oct 25 18:52:11 dragonflybsd :16[10426]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10426]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10426]: Connections: accepted: ::0
Oct 25 18:52:11 dragonflybsd :16[10426]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10426]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10426]: Connections: closed: ::0
Oct 25 18:52:11 dragonflybsd :16[10439]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10439]: TcpSocket: unable to get peer name for socket
Oct 25 18:52:11 dragonflybsd :16[10439]: Connections: accepted: ::0
Oct 25 18:52:11 dragonflybsd :16[10439]: TcpSocket: unable to get peer name for socket
</pre>

As you can see, INETD is constantly respawning Xvnc.

Thank you for noticing this issue.

Sincerely,

Adrian Kieß




-- 
You have received this notification because you have either subscribed to it, or are involved in it.
To change your notification preferences, please click here: http://bugs.dragonflybsd.org/my/account


More information about the Bugs mailing list