tigervnc - behavior weird
-
- Posts: 5
- Joined: 2017/11/10 07:39:58
tigervnc - behavior weird
Hi,
We have just install tiger vncserver on our centos 7 server.
When we start the vncserver session using the user "admin" and use vnc viewer to access it, the VNC GUI screen comes out nicely.
However when we configure to start with systemctl the VNC GUI is missing the top menu and background is blank.
I am attaching here the VNC GUI screen capture that have the issue.
My setting for /etc/systemd/system/vncserver@:1.service
Any ideas?
[Unit]
Description=Remote desktop service (VNC)
After=syslog.target network.target
[Service]
Type=forking
User=admin
# Clean any existing files in /tmp/.X11-unix environment
ExecStartPre=-/usr/bin/vncserver -kill %i
ExecStart=/usr/bin/vncserver %i
PIDFile=/home/admin/.vnc/%H%i.pid
ExecStop=-/usr/bin/vncserver -kill %i
[Install]
WantedBy=multi-user.target
We have just install tiger vncserver on our centos 7 server.
When we start the vncserver session using the user "admin" and use vnc viewer to access it, the VNC GUI screen comes out nicely.
However when we configure to start with systemctl the VNC GUI is missing the top menu and background is blank.
I am attaching here the VNC GUI screen capture that have the issue.
My setting for /etc/systemd/system/vncserver@:1.service
Any ideas?
[Unit]
Description=Remote desktop service (VNC)
After=syslog.target network.target
[Service]
Type=forking
User=admin
# Clean any existing files in /tmp/.X11-unix environment
ExecStartPre=-/usr/bin/vncserver -kill %i
ExecStart=/usr/bin/vncserver %i
PIDFile=/home/admin/.vnc/%H%i.pid
ExecStop=-/usr/bin/vncserver -kill %i
[Install]
WantedBy=multi-user.target
- Attachments
-
- vncgui.jpg (72.57 KiB) Viewed 6334 times
Re: tigervnc - behavior weird
Hey, I just wanted to show you that I had the same issue here: viewtopic.php?f=47&t=64949&p=273150#p273150
Could you please list what versions of Centos (7.3, 7.X) you are trying to use, and also what version of tigervnc you are using? To find the tigervnc version you may want to use yum list and grep for installed packages.
Also, let me know what vncviewer you are using. I used a few (tigervnc vncviewer, tightvnc viewer) and had the same results. I'm sure this is an issue with the server configuration.
I have issues using centos 7.4 and tigervnc 1.8. I'm wondering what we have in common that's causing the issue.
Could you please list what versions of Centos (7.3, 7.X) you are trying to use, and also what version of tigervnc you are using? To find the tigervnc version you may want to use yum list and grep for installed packages.
Also, let me know what vncviewer you are using. I used a few (tigervnc vncviewer, tightvnc viewer) and had the same results. I'm sure this is an issue with the server configuration.
I have issues using centos 7.4 and tigervnc 1.8. I'm wondering what we have in common that's causing the issue.
-
- Posts: 5
- Joined: 2017/11/10 07:39:58
Re: tigervnc - behavior weird
Hi,
Below are the information.
[root@PENLNXTEST2 ~]# rpm -qa | grep tiger
tigervnc-license-1.8.0-1.el7.noarch
tigervnc-server-minimal-1.8.0-1.el7.x86_64
tigervnc-server-1.8.0-1.el7.x86_64
[root@PENLNXTEST2 ~]# more /etc/redhat-release
CentOS Linux release 7.4.1708 (Core)
Using TigerVnc viewer.
Below are the information.
[root@PENLNXTEST2 ~]# rpm -qa | grep tiger
tigervnc-license-1.8.0-1.el7.noarch
tigervnc-server-minimal-1.8.0-1.el7.x86_64
tigervnc-server-1.8.0-1.el7.x86_64
[root@PENLNXTEST2 ~]# more /etc/redhat-release
CentOS Linux release 7.4.1708 (Core)
Using TigerVnc viewer.
-
- Posts: 1
- Joined: 2017/11/13 10:05:52
Re: tigervnc - behavior weird
I have the same problem.
My configuration is nfs home directory and NIS (yp) enabled. Proper SELinux Boolean (use_nfs_home_dirs) are set to allow nfs home dirs.
The problem exists for both local and remote (vncserver).
For local display, gdm goes black and bounces back to login screen for all NIS users, only root can go into the desktop.
For remote desktop through vncserver, only systemctl start vncserver@:1.service will work, and results in black background with no menu bar, and no status bar. A direct start of vncserver from user account will result in vnc with all black screen with a mouse cursor.
The problem can be reproduced on multiple fresh installed centos 7.4 machines right after nfs and nis are setup.
I have tried that
local user + nfs home is normal
nis user + local home is normal
So only NIS user with nfs home dir cause the problem. Could someone help me get through this issue?
Thank you.
My configuration is nfs home directory and NIS (yp) enabled. Proper SELinux Boolean (use_nfs_home_dirs) are set to allow nfs home dirs.
The problem exists for both local and remote (vncserver).
For local display, gdm goes black and bounces back to login screen for all NIS users, only root can go into the desktop.
For remote desktop through vncserver, only systemctl start vncserver@:1.service will work, and results in black background with no menu bar, and no status bar. A direct start of vncserver from user account will result in vnc with all black screen with a mouse cursor.
The problem can be reproduced on multiple fresh installed centos 7.4 machines right after nfs and nis are setup.
I have tried that
local user + nfs home is normal
nis user + local home is normal
So only NIS user with nfs home dir cause the problem. Could someone help me get through this issue?
Thank you.
Re: tigervnc - behavior weird
I was able to mess around with this a bit today, and my hunch is that something is not being initialized correctly. I found this post https://askubuntu.com/questions/453490/ ... tion-error and added mutter --replace to my ~/.vnc/xstartup file. I found that I still don't have the top start bar, but I can start gnome-terminal by right clicking and selecting "open terminal". Using mutter my windows behave more normally and I can actually close out and put them in the foreground/background. This is not a fix but may give a clue as to what is going wrong.
Here is my complete ~/.vnc/xstartup file.
Here is my complete ~/.vnc/xstartup file.
Code: Select all
#!/bin/sh
unset SESSION_MANAGER
unset DBUS_SESSION_BUS_ADDRESS
exec mutter --replace &
exec /etc/X11/xinit/xinitrc
Re: tigervnc - behavior weird
For anyone still searching, I recommend installing XRDP to access your desktop remotely. Follow this guide to install:http://www.itzgeek.com/how-tos/linux/ce ... hel-7.html
Re: tigervnc - behavior weird
The error is related to an incorrect template file. The instructions in RHEL Administrator's Guide tell to copy /usr/lib/systemd/system/vncserver@.service as a starting point for the server configuration. This file does not set the right user for running the server, however.
Simply replace the lines
with
And all should be well. As a bonus, the modified config file sets the default resolution when starting a session.
Simply replace the lines
Code: Select all
ExecStartPre=-/usr/bin/vncserver -kill %i
ExecStart=/usr/bin/vncserver %i
PIDFile=/home/<USER>/.vnc/%H%i.pid
ExecStop=-/usr/bin/vncserver -kill %i
Code: Select all
ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
ExecStart=/usr/sbin/runuser -l <USER> -c "/usr/bin/vncserver %i -geometry 1920x1080"
PIDFile=/home/<USER>/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
Re: tigervnc - behavior weird
Or just add PAMName=login to the existing file just below the line that currently says User=
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Re: tigervnc - behavior weird
Mostly new at Linux, new at Centos 7. I have the same problem as the OP. I tried these suggestions but it didn't worked.
When using this modification to the service file
ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
ExecStart=/usr/sbin/runuser -l <USER> -c "/usr/bin/vncserver %i -geometry 1920x1080"
PIDFile=/home/<USER>/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
I get this error runuser: may not be used by non-root users.
Instead, using this
PAMName=login - I get an SELinux error.
After searching and reading, I can't find any way to fix the problems. Help is appreciated.
I am curious, has either of these modifications fixed the issue for the original OP?
When using this modification to the service file
ExecStartPre=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
ExecStart=/usr/sbin/runuser -l <USER> -c "/usr/bin/vncserver %i -geometry 1920x1080"
PIDFile=/home/<USER>/.vnc/%H%i.pid
ExecStop=/bin/sh -c '/usr/bin/vncserver -kill %i > /dev/null 2>&1 || :'
I get this error runuser: may not be used by non-root users.
Instead, using this
PAMName=login - I get an SELinux error.
After searching and reading, I can't find any way to fix the problems. Help is appreciated.
I am curious, has either of these modifications fixed the issue for the original OP?
Re: tigervnc - behavior weird
Where? What error?PAMName=login - I get an SELinux error.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke