The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
test skooly5 UNIX for Dummies Questions & Answers 1 04-07-2008 06:38 AM
TAHI Test Suite 3.0.13 (IPv6 Conformance Test Tool branch) iBot Software Releases - RSS News 0 04-06-2008 09:20 AM
test and .test in same directory vikashtulsiyan SUN Solaris 14 12-27-2007 10:25 PM
Test : Which OS are you ? sysgate What's on Your Mind? 8 08-29-2007 03:36 PM
Keithley Introduces Linux-Based RF Parametric Test Systems - Test and Measurement.com iBot UNIX and Linux RSS News 0 07-23-2007 07:30 AM

Closed Thread
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-31-2001
Registered User
 

Join Date: Aug 2001
Location: NY
Posts: 3
Question BDF test for > 90%

I am trying to write a script that will allow me to do a bdf then do a test for a percentage that is 90% or greater. If the test is true then i want to send a message to myself and one other person.

Any suggestions ? ? ?

Thanks.

....svp
__________________
Success !!
Forum Sponsor
  #2 (permalink)  
Old 09-04-2001
Neo's Avatar
Neo Neo is offline
Administrator
 

Join Date: Sep 2000
Location: Asia Pacific
Posts: 4,147
Create an aliase in /etc/aliases and add the users you want.

Write a simple script that does a BDF and cuts the percentage field and uses that result in your test case. I suggest PERL, but others might suggest sed or awk. Either way, pipe the result with your own words to a mail program and mail the result (when the test condition is met) to the aliase you created in /etc/aliases.
  #3 (permalink)  
Old 09-04-2001
Registered User
 

Join Date: Aug 2001
Location: NY
Posts: 3
Thank you for the suggestion. However I do not know Perl, sed, or awk. Is there a way I can do this using Unix commands? I tryed building a script that does a simple BDF and grep for 90%. I figured I would get my logic down first than expand the condition testing. I havn't been to successful so far. I have just recently become aquainted with Unix. My back ground is NT/2000 and HP MPE.


.....svp
__________________
Success !!
  #4 (permalink)  
Old 09-05-2001
patvdv's Avatar
Registered User
 

Join Date: Jul 2001
Location: Belgium
Posts: 83
You will need some sort of utility to transform the 'awkward' bdf output into an usable format. Using awk would be easiest, do some reading on the awk command. It is not that hard.
__________________
Patrick Van der Veken - UNIX consultant (c) 2001 - 2001 http://www.baanboard.com - http://www.ux-core.com
'True strength lies in gentleness' - Irish proverb
  #5 (permalink)  
Old 09-05-2001
Neo's Avatar
Neo Neo is offline
Administrator
 

Join Date: Sep 2000
Location: Asia Pacific
Posts: 4,147
Perl, sed, or awk are all either UNIX command line utilities or can be used in command line mode. So, they are all UNIX commands. What we described is how things are done in the UNIX enviroment. UNIX is not point and click (which translated to slow and buggy), it is crisp and robust.

You must learn UNIX command line utilities to perform UNIX system administration (or hire people who do).
  #6 (permalink)  
Old 09-05-2001
Registered User
 

Join Date: Aug 2001
Location: NY
Posts: 3
Thank you. I will do some digging into AWK and PERL.
....svp
__________________
Success !!
  #7 (permalink)  
Old 09-05-2001
Neo's Avatar
Neo Neo is offline
Administrator
 

Join Date: Sep 2000
Location: Asia Pacific
Posts: 4,147
Great. Please post your solution or problems you run into when you try different approaches.
Google UNIX.COM
Closed Thread

Thread Tools
Display Modes




All times are GMT -7. The time now is 02:01 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0