(RADIATOR) [BUG] radiator diing on sql db timeout
Mike McCauley
mikem at open.com.au
Thu Jun 28 16:32:08 CDT 2007
Hello Alexander,
On Thursday 28 June 2007 21:29, Hartmaier Alexander wrote:
> Hi!
>
> I've looked at 15.1 but it doesn't contain an init script example.
> I know the syntax of restartWrapper it just won't work together with the
> init script from the goodies directory.
>
> Currently I don't have the time for a test environment and also no Oracle
> test database.
>
> Can you look at the source to verify that the session dbi statements are
> wrapped in an eval?
> It seems that only happens for sql statements accessing the session table.
All the database calls used by SessSQL.pm have timeouts and evals associated
with them.
>
> I traced the db calls in Radiator code to Radius::Util::exec_timeout.
> Is it possible that the sigaction call just before the eval force Radiator
> to die ($action includes a die call)?
No, the sigaction does not actually call die. It says to call die if there is
a timeout. The resulting die is what makes the eval terminate.
This is the normal and traditional way to enforce timeouts in perl.
I think we really need to see what Perl emits on stdout and stderr when it
dies to be sure we know what the problem is.
Cheers.
>
> -Alex
>
> > -----Original Message-----
> > From: Hugh Irvine [mailto:hugh at open.com.au]
> > Sent: Thursday, June 28, 2007 12:43 AM
> > To: Hartmaier Alexander
> > Cc: radiator at open.com.au
> > Subject: Re: (RADIATOR) [BUG] radiator diing on sql db timeout
> >
> >
> > Hello Alex -
> >
> > As mentioned previously, for testing you are much better off simply
> > running radiusd from the command line so you can see what is happening.
> >
> > To use restartWrapper in an init script, the whole command must be
> > run in the background, but "radiusd" itself must be run in the
> > foreground attached to restartWrapper.
> >
> > See section 15.1 in the Radiator 3.17.1 reference manual.
> >
> > regards
> >
> > Hugh
> >
> > On 27 Jun 2007, at 18:58, Hartmaier Alexander wrote:
> > > I upped the trace level to 4 last time and it happened again this
> > > night.
> > > The only error message is the SQL Timeout like last time.
> > > FYI the database is Oracle 10.2 so I use DBD::Oracle 1.16.
> > > The linux is RedHat 9, will be soon reinstalled on VMWare with
> > > RedHat Server 5.0.
> > >
> > > I tried to use restartwrapper but wasn't able to make it work.
> > > The init script for RedHat uses daemon which seems to not like
> > > restartwrapper.
> > > Do you have a complete linux init script example using
> >
> > restartwrapper?
> >
> > > Thanks, Alex
> > >
> > >> -----Original Message-----
> > >> From: Hugh Irvine [mailto:hugh at open.com.au]
> > >> Sent: Tuesday, June 12, 2007 1:28 AM
> > >> To: Hartmaier Alexander
> > >> Cc: radiator at open.com.au
> > >> Subject: Re: (RADIATOR) [BUG] radiator diing on sql db timeout
> > >>
> > >>
> > >> Hello Alexander -
> > >>
> > >> Yes you can use restartWrapper with an init script - keep in mind
> > >> that restartWrapper remains attached to radiusd, but from the init
> > >> script point of view restartWrapper detaches itself.
> > >>
> > >> See the example in section 15.1 of the Radiator 3.17.1 reference
> > >> manual ("doc/ref.html").
> > >>
> > >> To test your database connectivity problem I suggest you set up a
> > >> test machine with Radiator and a copy of the database, then Radiator
> > >> like this:
> > >>
> > >> cd /your/Radiator/distribution
> > >>
> > >> perl radiusd -foreground -log_stdout -trace 4 -config_file /your/
> > >> configuration/file
> > >>
> > >> You can then use radpwtst to generate test requests and stop the
> > >> database to see what happens.
> > >>
> > >> Please let us know what you discover.
> > >>
> > >> regards
> > >>
> > >> Hugh
> > >>
> > >> On 11 Jun 2007, at 19:31, Hartmaier Alexander wrote:
> > >>> Hi Hugh!
> > >>>
> > >>> Thanks for the quick response and the hint at the restartWrapper.
> > >>> Does the restartWrapper play nice with the init script?
> > >>>
> > >>> As this was on our production radius servers I only have a trace 3
> > >>> logfile
> > >>> from that time period.
> > >>> I don't really know how to reproduce the problem, maybe you can
> > >>> look in the
> > >>> DBI code and see something obvious around the session DBI execute.
> > >>>
> > >>> -Alex
> > >>>
> > >>>> -----Original Message-----
> > >>>> From: Hugh Irvine [mailto:hugh at open.com.au]
> > >>>> Sent: Sunday, June 10, 2007 12:14 PM
> > >>>> To: Hartmaier Alexander
> > >>>> Cc: radiator at open.com.au
> > >>>> Subject: Re: (RADIATOR) [BUG] radiator diing on sql db timeout
> > >>>>
> > >>>>
> > >>>> Hello Alexander -
> > >>>>
> > >>>> I suggest you use the restartWrapper utility we supply with
> > >>>> Radiator
> > >>>> to make sure that radiusd gets restarted in case of a crash.
> > >>>>
> > >>>> You can also configure restartWrapper to send mail with any Perl
> > >>>> error messages so you can see what caused the crash.
> > >>>>
> > >>>> See section 15.1 in the Radiator 3.17.1 refrerence manual ("doc/
> > >>>> ref.html").
> > >>>>
> > >>>> You will find restartWrapper in the "goodies" directory of the
> > >>>> distribution.
> > >>>>
> > >>>> To say any more I will need to see a trace 4 debug from Radiator
> > >>>> together with any error messages from radiusd.
> > >>>>
> > >>>> I will also need to see your configuration file and any other
> > >>>> relevant information such as hardware/software platform and so on.
> > >>>>
> > >>>> regards
> > >>>>
> > >>>> Hugh
> > >>>>
> > >>>> On 10 Jun 2007, at 19:44, Hartmaier Alexander wrote:
> > >>>>> Hi!
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>> The Radiator processes on our radius servers died yesterday night
> > >>>>> after this message (different timestamp on both servers):
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>> Sat Jun 9 22:09:56 2007: ERR: do failed for 'DELETE FROM
> > >>>>> radonline
> > >>>>> WHERE nasidentifier='x.x.x.x' AND nasport='954'': SQL Timeout
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>> It seems that the SQL Timeout triggered it.
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>> With best regards
> > >>>>>
> > >>>>> Alexander Hartmaier
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>> T-Systems Austria GesmbH
> > >>>>>
> > >>>>> Rennweg 97-99
> > >>>>>
> > >>>>> A-1030 Vienna
> > >>>>>
> > >>>>>
> > >>>>>
> > >>>>> phone: +43-(0)57057-4320
> > >>>>>
> > >>>>> mobile: +43-(0)676-8642-4320
> >
> > *"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
> >
> > >>>> "
> > >>>>
> > >>>>> *"*"*"*
> > >>>>> T-Systems Austria GesmbH Rennweg 97-99, 1030 Wien
> > >>>>> Handelsgericht Wien, FN 79340b
> >
> > *"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
> >
> > >>>> "
> > >>>>
> > >>>>> *"*"*"*
> > >>>>> Notice: This e-mail contains information that is confidential and
> > >>>>> may be privileged.
> > >>>>> If you are not the intended recipient, please notify the sender
> > >>>>> and
> > >>>>> then delete this e-mail immediately.
> >
> > *"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
> >
> > >>>> "
> > >>>>
> > >>>>> *"*"*"*
> > >>>>
> > >>>> NB:
> > >>>>
> > >>>> Have you read the reference manual ("doc/ref.html")?
> > >>>> Have you searched the mailing list archive
> > >>
> > >> (www.open.com.au/archives/
> > >>
> > >>>> radiator)?
> > >>>> Have you had a quick look on Google (www.google.com)?
> > >>>> Have you included a copy of your configuration file (no secrets),
> > >>>> together with a trace 4 debug showing what is happening?
> > >>>> Have you checked the RadiusExpert wiki:
> > >>>> http://www.open.com.au/wiki/index.php/Main_Page
> > >>>>
> > >>>> --
> > >>>> Radiator: the most portable, flexible and configurable RADIUS
> > >>>> server
> > >>>> anywhere. Available on *NIX, *BSD, Windows, MacOS X.
> > >>>> Includes support for reliable RADIUS transport (RadSec),
> > >>>> and DIAMETER translation agent.
> > >>>> -
> > >>>> Nets: internetwork inventory and management - graphical,
> > >>>> extensible,
> > >>>> flexible with hardware, software, platform and database
> > >>
> > >> independence.
> > >>
> > >>>> -
> > >>>> CATool: Private Certificate Authority for Unix and Unix-like
> > >>
> > >> systems.
> > >>
> > >>
> > >>
> > >>
> > >>
> > >>
> > >> NB:
> > >>
> > >> Have you read the reference manual ("doc/ref.html")?
> > >> Have you searched the mailing list archive
> >
> > (www.open.com.au/archives/
> >
> > >> radiator)?
> > >> Have you had a quick look on Google (www.google.com)?
> > >> Have you included a copy of your configuration file (no secrets),
> > >> together with a trace 4 debug showing what is happening?
> > >> Have you checked the RadiusExpert wiki:
> > >> http://www.open.com.au/wiki/index.php/Main_Page
> > >>
> > >> --
> > >> Radiator: the most portable, flexible and configurable RADIUS server
> > >> anywhere. Available on *NIX, *BSD, Windows, MacOS X.
> > >> Includes support for reliable RADIUS transport (RadSec),
> > >> and DIAMETER translation agent.
> > >> -
> > >> Nets: internetwork inventory and management - graphical, extensible,
> > >> flexible with hardware, software, platform and database
> >
> > independence.
> >
> > >> -
> > >> CATool: Private Certificate Authority for Unix and Unix-like
> >
> > systems.
> >
> >
> >
> >
> > *"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"
> >
> > > *"*"*"*
> > > T-Systems Austria GesmbH Rennweg 97-99, 1030 Wien
> > > Handelsgericht Wien, FN 79340b
> >
> > *"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"
> >
> > > *"*"*"*
> > > Notice: This e-mail contains information that is confidential and
> > > may be privileged.
> > > If you are not the intended recipient, please notify the sender and
> > > then delete this e-mail immediately.
> >
> > *"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"
> >
> > > *"*"*"*
> > >
> > > --
> > > Archive at http://www.open.com.au/archives/radiator/
> > > Announcements on radiator-announce at open.com.au
> > > To unsubscribe, email 'majordomo at open.com.au' with
> > > 'unsubscribe radiator' in the body of the message.
> >
> > NB:
> >
> > Have you read the reference manual ("doc/ref.html")?
> > Have you searched the mailing list archive (www.open.com.au/archives/
> > radiator)?
> > Have you had a quick look on Google (www.google.com)?
> > Have you included a copy of your configuration file (no secrets),
> > together with a trace 4 debug showing what is happening?
> > Have you checked the RadiusExpert wiki:
> > http://www.open.com.au/wiki/index.php/Main_Page
> >
> > --
> > Radiator: the most portable, flexible and configurable RADIUS server
> > anywhere. Available on *NIX, *BSD, Windows, MacOS X.
> > Includes support for reliable RADIUS transport (RadSec),
> > and DIAMETER translation agent.
> > -
> > Nets: internetwork inventory and management - graphical, extensible,
> > flexible with hardware, software, platform and database independence.
> > -
> > CATool: Private Certificate Authority for Unix and Unix-like systems.
--
Mike McCauley mikem at open.com.au
Open System Consultants Pty. Ltd Unix, Perl, Motif, C++, WWW
9 Bulbul Place Currumbin Waters QLD 4223 Australia http://www.open.com.au
Phone +61 7 5598-7474 Fax +61 7 5598-7070
Radiator: the most portable, flexible and configurable RADIUS server
anywhere. SQL, proxy, DBM, files, LDAP, NIS+, password, NT, Emerald,
Platypus, Freeside, TACACS+, PAM, external, Active Directory, EAP, TLS,
TTLS, PEAP etc on Unix, Windows, MacOS, NetWare etc.
--
Archive at http://www.open.com.au/archives/radiator/
Announcements on radiator-announce at open.com.au
To unsubscribe, email 'majordomo at open.com.au' with
'unsubscribe radiator' in the body of the message.
More information about the radiator
mailing list