Home: Perl Programming Help: Advanced:
Daemon



Vlhadv
Novice

Oct 17, 2007, 2:14 AM


Views: 2723
Daemon

I wanted to make a daemon in linux to check files having .csv file extension on a certain directory and parse them afterwhich. This should be done every time the directory is updated or added with a new file. I haven't started my code yet and i had already found several examples pertaining to daemon in the web. Those examples uses the same routine in entering the actual daemon mode, which is

while(1){

<statements>

sleep(10);

}

Question: Is this the standard? Are there any other ways in entering the actual daemon code? Your opinion will be of much help...


KevinR
Veteran


Oct 17, 2007, 3:05 AM


Views: 2721
Re: [Vlhadv] Daemon

That is a very common way to make a perl program that runs continuously (a deamon). It might be considered "the standard" way of doing it. It is not somehing I have ever needed to do very often but it is the way I do it when I want to keep a perl program running.
-------------------------------------------------


Vlhadv
Novice

Oct 17, 2007, 10:48 PM


Views: 2713
Re: [KevinR] Daemon

I don't have any choice then. thanks again kevin.... is there anyway i can also help here in this forum??? can i answer inquiries here??


KevinR
Veteran


Oct 17, 2007, 11:14 PM


Views: 2712
Re: [Vlhadv] Daemon

There are no active moderators or administrators of this forum to ask how you could help in other ways, so aswering questions is the only way.
-------------------------------------------------