I’m new to Rocky linux, and also returning to linux system administration after many years. My goal is to allow a user to be logged in locally (and leave their session logged in locally) to the console gnome desktop and also have a VNC session (separate desktop) that they can use (and leave active) for when they are at home or on the road. In the past on other machines I have never had an issue with this. Console is logged in at :0, and any number of VNC sessions could be started on :1, :2, etc. There is really only one user for this machine, and they would like to easily access it from home and office and leave their sessions logged in to be able to return to work in progress.
On this Rocky 8 box (running 8.9), I do not seem to be able to do that, and in some other threads I have read that this is not even supported (which seems odd to me since I have been using VNC sessions like this for years on other linux boxes).
The other sysadmin installed the Nvidia drivers because Wayland was causing hiccups, but I don’t believe that is related to the VNC issue, as I could not get the VNC to work as I wanted to before that switch. Everything works fine on the machine, but if logged in to the console, a VNC session cannot be started for the same user. If logged out of the console, a VNC session can be started and works fine, but then the user cannot log in at the console while the VNC session is active.
The VNC server installed is TigerVNC. I start a VNC session using this command: “sudo systemctl start vncserver@:1”. The vncserver.users file looks like this (comment lines removed):
:1=actualusername
Based on some advice I found elsewhere, I’ve tried adding (or uncommenting) the following to /etc/gdm/custom.conf file:
WaylandEnable=false
DefaultSession=gnome-xorg.desktop
And I’ve tried commenting/uncommenting the following lines in the vnc config (and mandatory config) files
alwaysshared
localhost
But none of this has had any affect. I would appreciate any advice on how to have a VNC session and a desktop session (different desktops) for the same user simultaneously. Thanks.
-J