Python Admin Scripts

Dave Brueck dave at pythonapocrypha.com
Thu Mar 27 14:13:23 EST 2003


On Thu, 27 Mar 2003, Norm wrote:

> Many of you must be Linux/NT admins.  What I am looking for are
> projects to try out on Python.
>
> How have you found Python to be useful in making the job easier?

Of course!

> What tasks have you automated with Python?

I admin several Linux boxes but I'm definitely not a "real" admin. Still,
I use it for:

- processing (parsing, summarizing, dividing) cache logs
- sending automated e-mails (e.g. from a daily cron job, or notifying me
when a DHCP IP address has changed)
- doing automated backups
- various system checks
- grabbing CVS updates and trimming the output
- automated, distributed builds and releases
- automated testing

Basically it's useful for building little utilities that you'd use the
same way as grep, sed, gzip, etc. as well as higher-level tasks that use
those lower-level tools. I'm not very fond of bash scripting, so I tend to
write little Python scripts anytime I need to do several tasks or need
control flow or do filename and path manipulations.

-Dave





More information about the Python-list mailing list