How to return from shutdown command
D-Man
dsh8290 at rit.edu
Fri Feb 9 09:34:56 EST 2001
If you have just shutdown the system, how is the script supposed to
continue running? ;-)
-D
On Fri, Feb 09, 2001 at 03:01:54PM +1100, Craig Findlay wrote:
| I want to execute a Unix shutdown command from a python script, but
| have control return to the script, and I'm having trouble doing it.
|
| I've tried:
|
| commands.getstatusoutput('shutdown -h +1')
| and
| commands.getstatusoutput('/bin/sh -c "shutdown -h +1" \&')
|
| but neither of these commands return.
|
| Any help greatly appreciated!
|
| Craig
|
More information about the Python-list
mailing list