[CentOS] which programming language for server-side admin tasks

Mon Jun 15 15:04:27 UTC 2009
Les Mikesell <lesmikesell at gmail.com>

David G. Mackay wrote:
> On Mon, 2009-06-15 at 09:16 +0200, Peter Hopfgartner wrote:
>> Python has become quite common for sysadmin stuff. Indeed, a lot of 
>> RedHat/Fedora (e.g. anaconda, the installer) and Ubuntu tools are really 
>> Python scripts. The code is quite readable and usually, there are Python 
>> bindings for almost every popular C library.
> 
> Python will let you develop programs very quickly, the first time.  The
> problem is that you'll have to go back and redo the code when a
> different version of python is released.  There are major
> incompatibilities between 2.5 and 3.0.  If you have a lot of code and/or
> use the low level C bindings, it can be a major effort to make your code
> run under a new release.  Take a look at the poor folks at zope.org.
> They've been beaten half to death with almost every release.
> 
> Also, there are several engineers at Red Hat that are very unhappy with
> the impact that the 3.0 release is going to have on them.

Yes but it has been obvious for a long time that python does not 
consider backwards compatibility to be important.  This shouldn't have 
come as a surprise.  By comparison, perl has been around longer and 
through more changes and yet about the only thing you might have to 
check on a program written for perl 1.x to run under 5.x would be 
whether you have @ in double-quoted strings that you wanted to remain 
literal.

>> GUI can quickly be made with PyGTK or WxPython.
> 
> And, of course, there's glade to help.
> 
> The bottom line is that you can probably get your project done faster in
> python.  But if you have a lot of code that you're going to need to
> maintain, you're much better off with java, which actually has a lot of
> input from the user community, and respects their user base.

One other consideration is that perl probably has the current advantage 
in terms of available code library modules.  Pretty much anything you 
can imagine doing has already been done and contributed to CPAN so often 
the code you have to write yourself is trivial with the modules doing 
the bulk of the work.  Java may be catching up in this regard but I 
don't think there is a central place to find available code.

-- 
    Les Mikesell
     lesmikesell at gmail.com