LinuxQuestions.org
Support LQ: Use code LQCO20 and save 20% on CrossOver Office
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 04-14-2004, 10:17 AM   #1
enkrypter
LQ Newbie
 
Registered: Apr 2004
Posts: 4

Rep: Reputation: 0
File or direcroty watcher and emailer


Greetings all,

I need some sort of linux toy, script (perl or shell) or C code, that can monitor a directory to see when new files arrive. I need it to be able to send an email to a person or group of persons when the change is detected. I also need this program to be able to monitor multiple directories and be able to have a different email list for each directory monitored if I so desire. It doesn't have to be fancy, just so I can send an email to a person saying "You've got new Files", and then possible list the names of the new files in the email, but that is not a priority. Emailing is though.

I tried to look for tools that can do this, but couldn't find any to fit my needs. If anyone has suggestions, please suggest! If something needs to be written in C I would kindly ask you make the source available via GPL. After all, Linux was founded on it...


I considder myself an intermediate Linux Admin. I know shell and perl fairly well, but don't claim to know it all. I am primarily a Slackware user. I hate GUI clutter. CLI all the way! My servers don't even have KDE or X installed.

This programming help is going to be used to notify people when files are available for download on an FTP site. So, it must be flexible to be able to monitor and notify many different directories and people.

Thanks in advance.
 
Old 04-15-2004, 07:08 AM   #2
andguent
Member
 
Registered: Sep 2003
Distribution: Woody, SuSE, RH, LAS
Posts: 55

Rep: Reputation: 15
tripwire.org is well known OSS designed to watch files for changes. I have not used it but I will be shortly when I teach myself how to use it. Other software options include http://osiris.shmoo.com and http://sourceforge.net/projects/aide/
These links are provided thanks to the Automating Unix and Linux Adminstration book.

From there, the way I email logs (thanks to a previous post) is

cat /var/log/mylog | mutt someusertonotify@pizzashack.net -s "My log file from $HOSTNAME"

I'm sure you could setup an if statement that if tripwire noticed there was a new file created, it would cat PrettyNotifyUserLetter to mutt instead of the log. If the email address that the letter was sent to was a mailing list instead of an individual user, that would take care of your group notify issues.

Hopefully some of that will get you walking in the right direction. Good luck. Sounds like a nice project. Please post your script if you get it working.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Internet watcher mrspcs Linux - Software 5 10-20-2005 10:51 AM
Command line emailer sendas4 Linux - Software 3 07-03-2005 09:54 PM
Direcroty listing using UserDir using Apache 2? sikandar Linux - Software 1 06-06-2005 11:27 AM
Sendmail Remote Emailer littlenicker Slackware 3 05-03-2005 11:36 AM
file watcher job bmeckle Programming 1 07-27-2004 03:40 PM


All times are GMT -5. The time now is 12:16 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration