Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

VNC not working only noVNC does #174

Closed
etamari opened this issue Mar 24, 2023 · 6 comments
Closed

VNC not working only noVNC does #174

etamari opened this issue Mar 24, 2023 · 6 comments

Comments

@etamari
Copy link

etamari commented Mar 24, 2023

consol/debian-xfce-vnc

latest

running: docker run -it -p 6333:5901 -p 6222:6901 -e VNC_PASSWORDLESS=true consol/debian-xfce-vnc on ubuntu20.04 host

No error everything opened normal

browser access is okay, via VNC viewer just want start.
your old image does works fine, but it is ubuntu16

docker run -it -p 6333:5901 -p 6222:6901 -e VNC_PASSWORDLESS=true consol/debian-xfce-vnc

@etamari
Copy link
Author

etamari commented Mar 24, 2023

------------------ update chromium-browser.init ------------------

... set window size 1280 x 1024 as chrome window size!

------------------ change VNC password ------------------

------------------ start noVNC ----------------------------
start vncserver with param: VNC_COL_DEPTH=24, VNC_RESOLUTION=1280x1024
...
start window manager
...

------------------ VNC environment started ------------------

VNCSERVER started on DISPLAY= :1
=> connect via VNC viewer with 172.17.0.11:5901

noVNC HTML client started:
=> connect via http://172.17.0.11:6901/?password=...

@manicai
Copy link

manicai commented Mar 27, 2023

Having a similar problem running on Ubuntu 22.04 with both Debian images. For both I can connect via the noVNC browser but not with TigerVNC directly. The rocky-xfce-vnc image works via both connection methods.

Log from docker run -p 5901:5901 -p 6901:6901 consol/debian-xfce-vnc --debug bash with a connection via noVNC at the end (attempting to connect via TigerVNC shows nothing in the container log).

/bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
USER_ID: 1000, GROUP_ID: 0
nss_wrapper location: /usr/lib/x86_64-linux-gnu/libnss_wrapper.so                
                                                              

------------------ DEBUG VNC STARTUP -----------------                                                                      
bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
                                                                                                                            
------------------ update chromium-browser.init ------------------
                                                              
... set window size 1280 x 1024 as chrome window size!
                                                                                                                            
                                                              
------------------ change VNC password  ------------------
                                                                                                                            
------------------ start noVNC  ----------------------------
/headless/noVNC/utils/novnc_proxy --vnc localhost:5901 --listen 6901
start vncserver with param: VNC_COL_DEPTH=24, VNC_RESOLUTION=1280x1024                                
...
vncserver :1 -depth 24 -geometry 1280x1024 PasswordFile=/headless/.vnc/passwd                                                                                                                                                                           
start window manager
...                                                                                                                         
                                                              

------------------ VNC environment started ------------------                                                               
                                                              
VNCSERVER started on DISPLAY= :1                                                                                            
        => connect via VNC viewer with 172.17.0.4:5901
                                                              
noVNC HTML client started:                                                                                                  
        => connect via http://172.17.0.4:6901/?password=...                                                                 
                                                                                                                            

------------------ /headless/.vnc/*:1.log ------------------
tail: cannot open '/headless/.vnc/*:1.log' for reading: No such file or directory
==> /dockerstartup/no_vnc_startup.log <==

Navigate to this URL:

    http://851c1c529fe4:6901/vnc.html?host=851c1c529fe4&port=6901

Press Ctrl-C to exit


NC server.


==> /dockerstartup/vnc_startup.log <==

==> /dockerstartup/wm_startup.log <==

(xfsettingsd:353): Gtk-WARNING **: 12:28:38.799: Locale not supported by C library.
        Using the fallback 'C' locale.
xfsettingsd-Message: 12:28:38.803: Skipping screen 0, it already has an xsettings manager...

(xfsettingsd:353): libupower-glib-WARNING **: 12:28:38.803: Couldn't connect to proxy: Could not connect: No such file or directory
xfsettingsd: Another clipboard manager is already running.
/usr/bin/startxfce4: X server already running on display :1
Another Window Manager (Xfwm4) is already running on screen :1.0
To replace the current window manager, try "--replace"

==> /dockerstartup/wm_startup.log <==

(process:358): Gtk-WARNING **: 12:28:46.810: Locale not supported by C library.
        Using the fallback 'C' locale.

(process:362): Gtk-WARNING **: 12:28:46.914: Locale not supported by C library.
        Using the fallback 'C' locale.

(xfce4-session:314): xfce4-session-WARNING **: 12:28:46.939: failed to run script: Failed to execute child process ?/usr/bin/pm-is-supported? (No such file or directory)

(xfce4-session:314): xfce4-session-WARNING **: 12:28:46.940: failed to run script: Failed to execute child process ?/usr/bin/pm-is-supported? (No such file or directory)

(xfce4-session:314): xfce4-session-WARNING **: 12:28:46.941: failed to run script: Failed to execute child process ?/usr/bin/pm-is-supported? (No such file or directory)

(wrapper-2.0:362): Gtk-WARNING **: 12:28:46.947: Negative content width -1 (allocation 1, extents 1x1) while allocating gadget (node button, owner XfceArrowButton)

(Thunar:368): Gtk-WARNING **: 12:28:54.825: Locale not supported by C library.
        Using the fallback 'C' locale.

(xfdesktop:373): Gtk-WARNING **: 12:29:02.837: Locale not supported by C library.
        Using the fallback 'C' locale.

** (xfdesktop:373): CRITICAL **: 12:29:02.944: xfdesktop: already running, quitting.

** (xiccd:380): CRITICAL **: 12:29:02.952: Failed to connect to colord: Could not connect: No such file or directory
Connection failure: Connection refused
pa_context_connect() failed: Connection refused

(process:379): Gtk-WARNING **: 12:29:02.954: Locale not supported by C library.
        Using the fallback 'C' locale.

(process:378): Gtk-WARNING **: 12:29:02.954: Locale not supported by C library.
        Using the fallback 'C' locale.

** (light-locker:378): ERROR **: 12:29:02.957: session_id is not set, is /proc mounted with hidepid>0?

(polkit-gnome-authentication-agent-1:379): polkit-gnome-1-WARNING **: 12:29:02.958: Error getting authority: Error initializing authority: Could not connect: No such file or directory

(process:383): Gtk-WARNING **: 12:29:02.958: Locale not supported by C library.
        Using the fallback 'C' locale.

(xfsettingsd:385): Gtk-WARNING **: 12:29:02.963: Locale not supported by C library.
        Using the fallback 'C' locale.
system-config-printer-applet: failed to connect to system D-Bus

==> /dockerstartup/no_vnc_startup.log <==
 - [27/Mar/2023 13:05:44] 172.17.0.1: Plain non-SSL (ws://) WebSocket connection
172.17.0.1 - - [27/Mar/2023 13:05:44] 172.17.0.1: Path: '/websockify'
172.17.0.1 - - [27/Mar/2023 13:05:44] connecting to: localhost:5901

Message from the VNC viewer

$ vncviewer localhost:5901

TigerVNC Viewer v1.13.0
Built on: 2023-02-05 03:52
Copyright (C) 1999-2022 TigerVNC Team and many others (see README.rst)
See https://www.tigervnc.org for information on TigerVNC.

Mon Mar 27 14:07:09 2023
 DecodeManager: Detected 20 CPU core(s)
 DecodeManager: Creating 4 decoder thread(s)
 CConn:       Connected to host localhost port 5901
 CConn:       End of stream
 CConn:       The connection was dropped by the server before the session could
              be established.
 DecodeManager:   Total: 0 rects, 0 pixels
 DecodeManager:          0 B (1:-nan ratio)

@ddobei
Copy link

ddobei commented Apr 27, 2023

Hi All,

I also faced with same issue. The cause of this issue is that vnc server must be started with parameter "-localhost no". The author fixed it in debian xfce Dockerfile, but seems he forgot to rebuild and push new docker image to Docker registry. I cloned this project and rebuild it localy and it works fine.

Here it is explained and fixed #165

@sni
Copy link
Member

sni commented Apr 30, 2023

should be fine with :latest now as well.

@sni
Copy link
Member

sni commented Jul 5, 2023

what kind of error do you get? The $STARTUPDIR (/dockerstartup) should be writable und normal conditions.

@4hiziri
Copy link

4hiziri commented Jul 11, 2023

Sorry, that is my misunderstanding. Please forget it.

@sni sni closed this as completed Jul 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants