February 5, 2016

How to start vnc server for specific users on specific day?

I have an issue that there are total of 40 users for which I have to start vnc server, but only first 20 should get access on Monday and only the rest of 20 should have access on Tuesday. Right now I have to manually edit the /etc/sysconfig/vncservers file each day by commenting out the users which shouldn't have access on that day.

Is there a simple way to automate this process, lets say by writing a script?
BTW I am using Red Hat Linux 5.

Click Here!