LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-04-2013, 12:21 AM   #1
farazinux
LQ Newbie
 
Registered: Dec 2012
Posts: 23

Rep: Reputation: Disabled
asterisk in restartd


I installed asterisk on debian server and I want to put this service in "restartd.conf" that if asterisk was stopped , start automatically.
please help me.

I test with following configuration but it didn't work correctly! :
1- asterisk "/usr/sbin/asterisk" "/bin/echo 'Asterisk is not running! at `date`' >/var/log/asterisk/asterisk_restartd.log"; /etc/init.d/asterisk start" true
2- asterisk "asterisk" "/bin/echo 'Asterisk is not running! at `date`' >/var/log/asterisk/asterisk_restartd.log"; /etc/init.d/asterisk start" true
 
Old 05-04-2013, 04:56 PM   #2
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 26,634

Rep: Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965Reputation: 7965
Quote:
Originally Posted by farazinux View Post
I installed asterisk on debian server and I want to put this service in "restartd.conf" that if asterisk was stopped , start automatically.please help me.
The best help would be for you to check Google before posting a question. From a VERY quick search:
http://blog.jerodsanto.net/2008/09/s...oot-in-debian/
Quote:
I test with following configuration but it didn't work correctly! :
1- asterisk "/usr/sbin/asterisk" "/bin/echo 'Asterisk is not running! at `date`' >/var/log/asterisk/asterisk_restartd.log"; /etc/init.d/asterisk start" true
2- asterisk "asterisk" "/bin/echo 'Asterisk is not running! at `date`' >/var/log/asterisk/asterisk_restartd.log"; /etc/init.d/asterisk start" true
No idea what these lines are supposed to be doing, where you put them, or what context any of this is in.
 
Old 05-12-2013, 03:27 AM   #3
farazinux
LQ Newbie
 
Registered: Dec 2012
Posts: 23

Original Poster
Rep: Reputation: Disabled
I solved it with following configuration :
asterisk ".*asterisk" "/bin/echo 'Asterisk is not running! at `date`' >/var/log/asterisk/asterisk_restartd.log; /etc/init.d/asterisk start"

Thanks
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
CentOS-Asterisk- /var/spool/asterisk/monitor How to decipher who's call is who's? tananthulus Linux - Newbie 2 12-08-2009 04:50 AM
LXer: Installing The Asterisk PBX And The Asterisk Web-Based Provisioning GUI On Linu LXer Syndicated Linux News 0 09-25-2007 02:50 PM
asterisk configuration to make a call PC - PC through asterisk priya001 Linux - Server 0 11-08-2006 06:06 AM
LXer: VoIPowering Your Office with Asterisk: Shiny New Asterisk 1.4 LXer Syndicated Linux News 0 11-03-2006 06:54 AM
anyone use Asterisk? nadroj General 6 05-27-2006 02:12 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 10:47 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration