Lock files would be a better way of preventing multiple copies running.

http://php.net/manual/en/function.flock.php




On 21 June 2013 07:49, Nyamul Hassan <nyamul@gmail.com> wrote:
What I use is this:

=== start of file ===
#!/bin/sh
FILETORUN="/data/fs/cdr.php"
if ps -ef | grep -v grep | grep ${FILETORUN} ; then
        exit 0
fi
/usr/bin/php ${FILETORUN}
=== end of file ===

Regards
HASSAN


On Fri, Jun 21, 2013 at 12:27 PM, Abdullah <abdullah@smonte.com> wrote:
hi ,

thanks again ,,

can you provide me the example . ??

regards.


Abdullah



--
View this message in context: http://freeswitch-users.2379917.n2.nabble.com/How-create-customize-CDR-in-free-Switch-tp7591980p7592032.html
Sent from the freeswitch-users mailing list archive at Nabble.com.

_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com

FreeSWITCH-powered IP PBX: The CudaTel Communication Server
http://www.cudatel.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://wiki.freeswitch.org
http://www.cluecon.com

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org


_________________________________________________________________________
Professional FreeSWITCH Consulting Services:
consulting@freeswitch.org
http://www.freeswitchsolutions.com

FreeSWITCH-powered IP PBX: The CudaTel Communication Server
http://www.cudatel.com

Official FreeSWITCH Sites
http://www.freeswitch.org
http://wiki.freeswitch.org
http://www.cluecon.com

FreeSWITCH-users mailing list
FreeSWITCH-users@lists.freeswitch.org
http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
http://www.freeswitch.org