Posted By

galaxstar on 01/07/11



Versions (?)

Who likes this?

1 person have marked this snippet as a favorite


Make sure the script is run as root

 / Published in: Python

  1. import os
  2. if os.geteuid() != 0:
  3. print "This program must be run as root. Aborting."
  4. sys.exit(1)

Report this snippet  

You need to login to post a comment.