Results 1 to 4 of 4
  1. #1
    Join Date
    May 2003

    Unanswered: Shell Script help needed

    Hello Script gurus,

    I am supposed to write an script that does some tasks like below:

    I am not a newbie. However, I am looking for a quick input from you before
    I can delve into the language features. Can somebody please help me what kind of scripting language
    I should use? Should it be perl or Shell scripting? I think there is also some "awk" work.
    The shell that I am using is bourne/hp-ux. So, how do I know if bourne supports all the features?
    There could be some more tasks in future. What is the best way to implement it? Some of the portions
    may be reuseable. Could you please comment if there is anything that cannot be done (from below)?

    Here are some tasks:

    Monitor disk space, Notify (via email) when something wrong (bdf -bi)
    Monitor free blocks via unix, Notify (via email)when something wrong (df -k)
    select count(*) from a few tables in oracle, notify (via email)when something wrong
    Changing file name extension (file name extension has a number that needs to be calculated)
    Moving files to a different directory
    Monitor processes .. ( 3 processes must always be running otherwise notify (via email))
    Search a file for keywords (Need to monitor the content of file)
    Creating a file
    killing processes
    su as root, (some notifications depending on condition)
    issue a command
    check date and time on processes
    issue ls -l, if files with .XXX ext'n are found, notify
    change dir, if files older than today, notify

    I would greatly appreciate any suggestions/comments/questions from you. Will appreciate if you can suggest a good tutorial/book for generic shell programming

  2. #2
    Join Date
    May 2003

    Any suggestions please?

  3. #3
    Join Date
    May 2003

    Any suggestions please?

  4. #4
    Join Date
    Jan 2004
    Bordeaux, France
    You can do all in shell xith the help of somle commands like axk, sed, sqlplus ...

    Sun Microsystems has a great archive of useful scripts at:

    Perhaps same things on HP site...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts