Skip to content

TigerVNC server over SSH problem [USB]

Hi, I'm using tigervnc over ssh on my LAN with parameters:

​

[Server]

->launcher: tigervncserver -geometry 1920x1080 -alwaysshared -dpi 96 -localhost :1

Configuration of ~/.vnc/xstartup in order to don't get black screen when I connect from client to server (I don't know the meaning of the first 2 lines unset SESSION.. and unset DBUS..), I found this setup on an old reddit post:

#!/bin/sh

unset SESSION_MANAGER

unset DBUS_SESSION_BUS_ADDRESS

mate-session

​

[Client]

->ssh forwarding: ssh davide@192.168.1.30 -L 5902:localhost:5901 (using public key authentication)

->launcher: xtigervncviewer -SecurityTypes VncAuth,TLSVnc -passwd /path/to/password localhost:2

​

The Problem: everything works but everytime I plug-in any USB storage device (external HDD or flashUSB) the VNC screen becomes black. I suppose that tigervnc crashes but I don't know why. Sometimes, when I plugin a USB on server machine, not only the vnc server but the full mate desktop on server machine crashes. I suppose that it's the "xstartup" configuration that has a problem with DBUS.. I found this "xstartup" configuration in order to run a mate session (the only D.E. installed on server machine) when using VNC. I can leave the server active for days without the slightest problem, but when I plug in any USB problems start

Should I use a better VNC server because tigervnc is not a good software or my configuration is the problem? How can I solve this problem?

​

Thank you!

Edited 17 Apr 2019. We only hold this version.

25 points6 comments
Open on Reddit
About this post
Posted
Archived
Edited
Score
25 · 100% up
Kind
Text
ID
be4rm9

Author

74
posts
26
comments
3
media
View profile

6 comments

Are there any error messages anywhere? Can you SSH to the machine and run the vnc server in foreground and show us what happens?

1 points

Are there any error messages anywhere?

I don't know where I should read, can you suggest me what log must I see?

Can you SSH to the machine and run the vnc server in foreground and show us what happens?

Is there a way to get past output bash ? I'd like to not "reset" all the server for the 3th time because I've a lot of configurations on the X session where vncservers is running, and pugging usb could crash the whole server.

1 points

I'm not sure I understand how the server is launched now. Can you explain in more detail what you mean by "launcher"?

I haven't used a standalone VNC server in a while but I'd assume if you run tigervncserver in bash via SSH you should get all the error messages from your graphical session in that terminal.

1 points

Finally! Something I can help with XD

Your vncserver has a log file saved somewhere. Usually this log file is saved in ~/.vnc/

What I usually do when I am having issues with my vncserver is, I ssh in to my server and execute tail -f ~/.vnc/YourHostName:Head.log where "YourHostName" is your host name, and "head" is whichever head of the server your using. So for example, if your hostname is "arch-linux-server" and you're using ":1", it would look like this.

tail -f ~/.vnc/arch-linux-server:1.log

That will tell you what is going on with your vncserver.

It would be smart to have a second window open, running something like journalctl -xf to watch your system logs as well.

Edit: Is there a reason you are doing 5902:localhost:5901 instead of just using 5901:localhost:5901? I don't think that is causing an issue here, since you are hitting the correct port via xtigervncviewer -SecurityTypes VncAuth,TLSVnc -passwd /path/to/password localhost:2, just kinda confused me a bit at first glance

1 points

This is one of the only things I didn't get going with arch. Tried with centos 7 - worked first time.

1 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.