Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Auto Shutdown from the login window



I have been trying to find a way to auto shutdown our lab computers (10.3.8) after our school has been dismissed. If a user is logged in, the auto shutdown functions properly, however, if the client computer is at the login screen, auto shutdown will not occur. Does anyone out there have a solution?

You can run this script as a cron job at the time you want all computers to shut down:
------------------------------------


#!/bin/sh
###########################################
# After-hours Shutdown
# by Tyler Loch
# email@hidden
# This script when run as root will check
# for an active user on the system.
# If one exists, the script exits.
# If none exist, the computer is shut down.
###########################################

if [ `ps -auxww | grep Finder | grep CoreServ -c` -ge "1" ]
then
        exit 0
else
        /sbin/shutdown -h now
fi

------------------------------------
-Tyler Loch
Jacobs High School
Algonquin IL

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Client-management mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/client-management/email@hidden

This email sent to email@hidden
References: 
 >Auto Shutdown from the login window (From: Don Redgwell <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.