oo nga e. my problem is 85% is text, i find it difficult to use if
construct.

On Tue, 2003-01-14 at 15:50, Ariz Jacinto wrote:
> don't wait for the 99%
> 
> why not try setting it at  >= 85%
> an amount which can already  be
> considered as critical.
> 
> 
> 
> 
> lito lampitoc wrote:
> 
> >I wrote a very simple bash script to check the capacity of my swap space
> >for I have a problem of swap space getting full, the script will delete
> >it's content when it reached 99%, my problem is sometimes it can't
> >detect 99% because of time interval in cron, I don't want to execute the
> >script every second because i think it will burden my processor, what do
> >you think is the possible solution. Here is my simple script:
> >
> >#!/usr/local/bin/bash
> >
> >use=`/usr/bin/df -h|grep swap|awk -F" " '{print $5}'`
> >if use="0%";
> > then
> >   cat /dev/null 2>&1;
> > elif use = "99%";
> > then
> >   /usr/bin/rm /tmp/* > /dev/null 2>&1;
> >fi
> >
> >Thanks.
> >
> >
> >  
> >
> 
> 
> _
> Philippine Linux Users Group. Web site and archives at http://plug.linux.org.ph
> To leave: send "unsubscribe" in the body to [EMAIL PROTECTED]
> 
> Fully Searchable Archives With Friendly Web Interface at http://marc.free.net.ph
> 
> To subscribe to the Linux Newbies' List: send "subscribe" in the body to 
>[EMAIL PROTECTED]
> 
-- 
Lito A. Lampitoc                :  http://www.codewan.com.ph
Systems/Network Administrator   :  CountryWide Wide Area Network, Inc.

As we enjoy great advantages from inventions of others, we should be
glad of an opportunity to serve others by any invention of ours; and 
this we should do freely and generously - Benjamin Franklin                     

_
Philippine Linux Users Group. Web site and archives at http://plug.linux.org.ph
To leave: send "unsubscribe" in the body to [EMAIL PROTECTED]

Fully Searchable Archives With Friendly Web Interface at http://marc.free.net.ph

To subscribe to the Linux Newbies' List: send "subscribe" in the body to 
[EMAIL PROTECTED]

Reply via email to