1

If I am a junior UNIX/Linux system administrator, and I want to make automation tasks for the server.

I know Shell script, Perl, and Python. All of these are used to make automation tasks.

Which one I can use to make the scripts?

Answer should be according to these conditions: 1. less lines of code. 2. high performance. 3. Portable source code, even I use KSH or BASH shell.

If there is no dedicated answer, so when I can use perl and when python and when shell-script?

closed as primarily opinion-based by Mat, manatwork, jordanm, Anthon, slm Aug 18 '13 at 15:46

Many good questions generate some degree of opinion based on expert experience, but answers to this question will tend to be almost entirely based on opinions, rather than facts, references, or specific expertise. If this question can be reworded to fit the rules in the help center, please edit the question.

  • Consider perl and python interchangeable. Shell is when you want to get something done quickly but performance is less of a concern. – jordanm Aug 18 '13 at 15:42
  • You're concerned about the execution performance of a shell script (as opposed to whatever gets called by that shell script, which you likely have limited influence over anyway)? Just what are you doing in that shell script that makes its performance a concern?! – a CVn Aug 18 '13 at 19:51
1

If you want Perl, try (R)?ex: http://rexify.org/

If you want Python, try fabric: http://docs.fabfile.org/en/1.7/

Both can deploy with less line of code, better performance than shell. Try and make your choice.

I use both.

  • Python 2.5 disqualifies RHEL/CentOS 5. That's not very portable. – jordanm Aug 18 '13 at 15:40
  • I know both of them, but my question about there is conditions prevent me to use one of them in some cases or not ? – Mahmudemam Aug 18 '13 at 15:41
  • No, I think it depends on your skill. If you are good at what, just use it for your work. – cuonglm Aug 18 '13 at 16:03

Not the answer you're looking for? Browse other questions tagged or ask your own question.