Tigervnc on LMDE 6, seems to lose the HOME variable when the user process is spawned.

100 views
Skip to first unread message

Robert Granger

unread,
Jan 25, 2024, 2:46:30 AM1/25/24
to TigerVNC User Discussion/Support
Bug description
When trying to span a tigervnc session from systemctl it appears that the "exec" function is not sending a complete environment to the session. The HOME variable is not being set for normal users, root seems to work.
root@lmdetest:~# journalctl -fu tigervncserver@:2.service
Jan 24 00:22:58 lmdetest vncserver[9417]: Tigervncserver starting:
Jan 24 00:22:58 lmdetest tigervncsession[9430]: pam_unix(tigervnc:session): session opened for user rgranger(uid=1000) by (uid=0)
Jan 24 00:22:58 lmdetest systemd[1]: Started tigervncserver@:2.service - Remote desktop service (VNC).
Jan 24 00:22:59 lmdetest tigervncsession[9430]: tigervncsession: tigervncserver exited with status=255
Jan 24 00:22:59 lmdetest tigervncsession[9430]: pam_unix(tigervnc:session): session closed for user rgranger
Jan 24 00:22:59 lmdetest vncserver[9545]: vncserver: The HOME environment variable must be set.
Jan 24 00:22:59 lmdetest vncserver[9545]: Tigervncserver starting:
Jan 24 00:22:59 lmdetest systemd[1]: tigervncserver@:2.service: Control process exited, code=exited, status=1/FAILURE
Jan 24 00:22:59 lmdetest systemd[1]: tigervncserver@:2.service: Failed with result 'exit-code'.

Steps to reproduce
run as root:
This works
    eval /usr/sbin/tigervncsession root :3
This does not
    eval /usr/sbin/tigervncsession rgranger :2
Funny, I remember something similar back in the 80s with "su" or "sudo" it was stripping too much of the environment when shelling out. Probably not the same...
But if anyone is pulling their hair out trying to figure out what is stopping Tigervnc from working for normal users on Debian 12... this may be a clue.
Rob


Pierre Ossman

unread,
Jan 25, 2024, 9:46:19 AM1/25/24
to Robert Granger, TigerVNC User Discussion/Support
On 24/01/2024 17:52, Robert Granger wrote:
> Bug description
> When trying to span a tigervnc session from systemctl it appears that the
> "exec" function is not sending a complete environment to the session. The
> HOME variable is not being set for normal users, root seems to work.

The error messages suggest this is not standard TigerVNC, but rather
Debian's version. Do you think you could try with our packages?

Regards
--
Pierre Ossman Software Development
Cendio AB https://cendio.com
Teknikringen 8 https://twitter.com/ThinLinc
583 30 Linköping https://facebook.com/ThinLinc
Phone: +46-13-214600

A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

Rob Granger

unread,
Jan 26, 2024, 3:41:46 AM1/26/24
to Pierre Ossman, Robert Granger, TigerVNC User Discussion/Support

If you send me a link to the version you want me to try ,  I will give it a run. I suspect it is a core bug in the system EXEC / EXCEL calls to spawn the new process. Being retired from IT , I have time 😊

 

 

---------------------

Rob Granger

rgra...@grangersr.us

281.507.2407

Breaking more things by 8:00AM than most people break all day.

Pierre Ossman

unread,
Jan 26, 2024, 3:43:21 AM1/26/24
to Rob Granger, Robert Granger, TigerVNC User Discussion/Support
On 26/01/2024 09:01, Rob Granger wrote:
> If you send me a link to the version you want me to try , I will give it a run. I suspect it is a core bug in the system EXEC / EXCEL calls to spawn the new process. Being retired from IT , I have time 😊
>

We don't have anything specifically for Linux mint, but one of the
Ubuntu packages from the release page might be compatible:

https://github.com/TigerVNC/tigervnc/releases
Reply all
Reply to author
Forward
0 new messages