setting up vncserver for different users
I have a main computer and I would like users to VNC into it so that they can have the graphical desktop.
The VNC software is installed and running fine, however, I would like joe to have his own vncserver display. I would like jane to have her own vncserver display. And I would like tom, dick, and harry to have their own vncserver display. How can I set this up for them, under their accounts? Currently I created a "global" vnc user and created displays :1-9, all the with the same password. As you can see, if a user forgot his or her display, they would end up on another person's desktop!
Also, how do I set it so that the vncserver will start itself when the computer boots up? Imagine if a power outage happened and I rebooted the computer. Vncserver should start itself, ideally under each user's account.
To summarize, your users have separate displays, and you want them to have separate passwords. They will still all be running under your user ID, i.e., in a shell in an xterm, they can do anything you could (including setting everyone's VNC passwords). Is that what you want?
According to man vnc, the password is in $HOME/.vnc/passwd; so you need vary $HOME. I'd set up some directory VNC where they live, e.g., assuming bash,
I'm not sure what's the best technique to have it always available, and I haven't done this.
In man Xvnc, read the section on usage with inetd -- it might solve your needs, without actually starting vncserver when the computer boots. I'd try that first, because apparently it's supposed to work this way.
To have some service running whenever my computer is up, I generally use daemontools. It supervises the program and restarts it if it accidentally dies. But I haven't done this with vncserver.
Yet another approach would be to write a new script in /etc/init.d (take an existing script as template) and symlink it to the appropriate /etc/rc?.d. Beware that those scripts are executed by root (at startup), and you will want to run the vncserver as a harmless user. You could even create separate Unix users for Joe, Jane etc.
|All times are GMT -5. The time now is 10:17 AM.|