<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN">
<html><body>
<p>Joseph писал 24.11.2012 07:54:</p>
<blockquote type="cite" style="padding-left:5px; border-left:#1010ff 2px solid; margin-left:5px; width:100%"><!-- html ignored --><!-- head ignored --><!-- meta ignored -->
<pre>I'm running asterisk on a small box, <a href="mailto:Intel-R-_Atom-TM-_CPU_330_@_1.60GHz">Intel-R-_Atom-TM-_CPU_330_@_1.60GHz</a>
and when I try to restart the asterisk it fails.

/etc/init.d/asterisk restart
  * Caching service dependencies ...           [ ok ]
  * Killing wrapper script ...                 [ ok ]
  * Stopping asterisk PBX gracefully ...

* Waiting for asterisk to shutdown .............................................................
  * Failed.

When I run /etc/init.d/asterisk status
I get: "* status: started"

At this point I have to kill the process ID
"zap" it (/etc/init.d/asterisk zap)
and restart it.

Why asteriks can not shut down properly?
How can I monitor this process and restart it?
</pre>
</blockquote>
<p>I don't know what's in your startup script, for I never used one, but it says about graceful shutdown.</p>
<p>It might be executing "core stop gracefully" or maybe "core stop when convenient"</p>
<p>In the first case, Asterisk will stop receiving new commands and calls, will wait for all current calls to disconnect and then shutdown.</p>
<p>In the second case, Asterisk will continue receiving new calls (not sure about commands), and as soon as there are 0 active calls, it will shutdown.</p>
<p>As you can see, in the second scenario you'll rarely get to the shutdown on active server.</p>
<p>Not sure why do you kill the zap process. Does it hang up? For when you kill it and drop all Zap calls, asterisk may already rest in piece, if my above guess is right.</p>
<div>
<pre><span class="sig"><span style="color: #999999;">-- </span><br /><span style="color: #999999;">With Best Regards</span><br /><span style="color: #999999;"><a title="mailto:mlischuk@itx.com.ua" href="mailto:mlischuk@itx.com.ua">Mikhail Lischuk</a></span><br /><span style="color: #999999;"><br /></span></span></pre>
</div>
</body></html>