[OpenSIPS-Users] locating a core file

Iñaki Baz Castillo ibc at aliax.net
Wed Jan 20 18:21:55 CET 2010


El Miércoles, 20 de Enero de 2010, Jeff Pyle escribió:
> Hello,
> 
> Opensips 1.6 dumped on me.  I see the following in the syslog:
> 
> /usr/local/sbin/opensips[27560]: INFO:core:handle_sigs: core was generated
> 
> Where might this file be, and what might it be called?  I'm having trouble
>  locating it.  I start Opensips with the Fedora init.d file, calling the
>  daemon like this:
> 
> daemon $oser -m 128 $OPTIONS 2>/dev/null | tail -1
> 
> There is nothing in $OPTIONS.  $oser = /usr/local/sbin/opensips
> 
> I've seen cores dump into /tmp before but that's not the case this time. 
>  Any suggestions would be appreciated it.


Check "cat /proc/sys/kernel/core_pattern". It says the path and format of the 
coredump.
Opensips init scripts sets it (/etc/init.d/opensips):

if test "$DUMP_CORE" = "yes" ; then
  # set proper ulimit
  ulimit -c unlimited

  # directory for the core dump files
  COREDIR=/tmp
  #[ -d $COREDIR ] || mkdir $COREDIR
  #chmod 777 $COREDIR
  echo "$COREDIR/core.%e.sig%s.%p" > /proc/sys/kernel/core_pattern  # <-- HERE
fi
 

For that you need to set DUMP_CORE=yes in /etc/default/opensips (not sure if 
Fedora uses this location).


If the content of /proc/sys/kernel/core_pattern is just the default "core" 
then the coredump file is called "core" and it's located on the directory from 
where opensips was started (I hope).


-- 
Iñaki Baz Castillo <ibc at aliax.net>



More information about the Users mailing list