<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<style>
<!--
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:Arial;
        color:windowtext;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
</head>
<body lang=EN-US link=blue vlink=purple>
<div class=Section1>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>While simulating a database failure (stopping the service),
I noticed that OpenSER would also crash (see log below). While I don’t
mind the OpenSER crash since in our configuration its highly dependent upon the
database, what I would like to do is send a 5xx series message to the client so
that it would be forced to look at one of our other proxies to complete its
call. As the client continued to send the INVITE to the original server.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'>How can I send a 500 Server Internal Error message back to
the client in the event of a database failure?<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=2 face=Arial><span style='font-size:10.0pt;
font-family:Arial'><o:p> </o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8134]: PG[get_result]:
0x81af628 Warning: Probable invalid query<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8134]: PG[get_result]:
0x81af628 Warning: PGRES_FATAL_ERROR<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8134]: PG[get_result]:
0x81af628 Warning: server closed the connection unexpectedly This
probably means the server terminated abnormally before or while processing
the request.<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8147]: ERROR: receive_fd:
EOF on 23<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8105]: child process 8134
exited by a signal 11<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8105]: core was not
generated<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8105]: INFO: terminating
due to SIGCHLD<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8147]: INFO: signal 15
received<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8140]: INFO: signal 15
received<o:p></o:p></span></font></p>
<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Dec 8 22:36:11 terra /usr/local/sbin/openser[8137]: INFO: signal 15
received<o:p></o:p></span></font></p>
</div>
</body>
</html>