Hey, all -

I'm attempting to write a script to put in cron.weekly that will find
the 25 users who use the most disk space and email them a warning.

My relatively simple question is:

Is there anything in bash that is the equivelent to the old basic
mid/left/right way of cutting down a variable?  If I have a line from
the du output, basically I'm trying to define a variable for the
corresponding username (in other words, given: "1234M /home/USER" I want
'USER" so as to then turn around and email that user. (I already have
way of removing non-user directories in /home).

Any thoughts?

Oh, and this is fora RH7.2 system and really does not need to be all
that portable.


Thanks,

Brian

---------------------------------------------------------------
|  [EMAIL PROTECTED]                Spam me and DIE!       |
|                 http://www.datasquire.net                   |
|                 Co-Founder & Co-Owner of                    |
|              Data Squire Internet Services                  |
---------------------------------------------------------------


*****************************************************************
To unsubscribe from this list, send mail to [EMAIL PROTECTED]
with the text 'unsubscribe gnhlug' in the message body.
*****************************************************************

Reply via email to