The UNIX and Linux Forums  
Hello and Welcome from United States to the UNIX and Linux Forums! Thank You for Visiting and Joining Our Global Community.

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
.
google unix.com



Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Can we send email with C program on Unix? whatisthis High Level Programming 3 07-07-2006 11:18 AM
help request for sending email from unix to internet sbabuts BSD 1 09-14-2005 04:48 PM
sending email from KSH unix script. rosh0623 Shell Programming and Scripting 3 07-26-2005 03:36 AM
sending email in unix. need help! tads98 Shell Programming and Scripting 2 05-16-2005 08:33 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 04-28-2005
chino_52284 chino_52284 is offline
Registered User
  
 

Join Date: Apr 2005
Posts: 1
unix - c program sending error from DB to email

hi,

i have a database table that automatically logs the errors in the database every 5 mins.

what i want to happen is to come up with a program using unix-c that gets all the information from the log table, i have a flag initially set to zero which means that the error is not yet sent, the flag will automatically be changed to 1 once the error is already sent.

i hope you can help me regarding this matter.
thank you so much!

you can also email me on this address:
Removed

Last edited by Perderabo; 04-28-2005 at 01:47 PM.. Reason: Remove email address
  #2 (permalink)  
Old 04-28-2005
Perderabo's Avatar
Perderabo Perderabo is offline Forum Staff  
Unix Daemon
  
 

Join Date: Aug 2001
Location: Ashburn, Virginia
Posts: 9,111
Please read our rules and note:
(10) Don't post your email address and ask for an email reply. The forums are for the benefit of all, so all Q&A should take place in the forums.
  #3 (permalink)  
Old 04-28-2005
bhargav's Avatar
bhargav bhargav is offline Forum Advisor  
Registered User
  
 

Join Date: Sep 2004
Location: USA
Posts: 511
Here is some thing to start with ...
Loop this for every 5 minutes.

Or setup cron to run every 5 minutes ...



Code:

grep "error string"  logfile
if test $? -eq 0
then
    flag=1
fi
Sponsored Links
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 04:47 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0