Discussion Locked

Creating a batch files in UNIX

0 helpful
9 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I am an NT/Win2000 administrator and have been given the opportunity to work with UNIX. I am trying to create a batch file in Unix that would allow me to delete users in Simeon. Not sure if anyone has heard of Simeon, but it is an email client. Very funky, but we deal with it. Any assistance will help.

9 replies

by cpfeiffe

You need to create a shell script, which is simply a file with execute permissions that runs the same command line commands you would use to perform this task manually. You can execute the file by typing the name or have it run automatically with acron job. Use your man pages to see more about cron jobs. You could even load a list file during the day with users you want deleted and have your script read the list when it is called by the cron job.

Hope this helps

by cybergod

There are many script languages to do this job. I prefer Perl and simple shell script language. It is easy to do anything with them if you are familiar with Unix commands and the C syntax.

by oliviu

If you did batch files in NT then it will be easy for you to begin doing them in Unix.
Plus you will be amazed by the diversity and the possibilities you have in Unix shell scripting comparing with NT batch.

Important: Don't forget to give 'execute' permision to the script file.

You can check: http://www.whereisit.com/shellscript/index2.html

by ghislain.levesque

A shelle script is a text file contaning any Unix command. Used the same command that you normally used from the command prompt. If those command normally ask questions, here is how you could enter the answer within a shell script: Let's assume thatyour main comand is simeon...

simeon << END
all your answers have to be on separate line
and your last command will be END

END is in fact a label.

If there is no command prompt, only GUI, there's nothing you can do.

Good luck!

This discussion is closed to new replies.