Hi Larry,
> Let me see if I've got this straight. Your wanting cron to run a script that will
> log an idle user off the system and return to the gui startup screen. Right? I'm
> not sure if cron is the best method though. How will it determine that the user
> is not active and log them out while their working on something?
Wrong 23:00 is time little girls were in bed. I just want it to chuck her off
the system no matter what she is doing otherwise the little darling will sit up
all night playing games.
Line one locks her password so she can't get back onto the system when she has
been chucked off
Line two should return to the gui startup screen but I don't know how.
Line three enables her password again in the morning
Thanks for your help on this.
Richard Davies wrote:
I have written the following logged in as root crontab -e
59 22 * * * root passwd -l katrina
00 23 * * * root halt
00 8 * * * root passwd -u katrina
The first line works and locks katrina's password
The second line does nothing at all. What I really want this to do if to drop
back to the login screen but I can't find the command for that. I thought that
halt, shutdown now, shutdown -n, poweroff, init 0, while being overkill
should do the job. They don't
The third line works.
I have checked this by logging in as user and doing su katrina at 22:59 the
command stops working and at 08:00 starts again.
Any ideas what I have done wrong?
What I want this command to do is throw someone called katrina off the system
at 23:00 irrespective of what they are doing and keep them off the system until
08:00 the next day.
Katrina is a young girl who likes to get up at 02: and play computer games
making herself too tired for school in the morning. At present I just turn the
system off and take the power cord but there has to be an easier answer than
that.
--
Regards,
Richard
Tollyboy Products International
http://www.tollyboy.com
--
Regards
Richard
http://www.tollyboy.com