Re: Freeradius hangs after a HUP

2005-02-01 Thread Joe H
I was tired of trying to find a quick way to fix this so I ended up
basically formatting the box and reinstalling.  Everything works fine now.
Not sure what the problem was but it's now resolved.

Joe H.

On Fri, 28 Jan 2005, Joe H wrote:

> On Thu, 27 Jan 2005, Alan DeKok wrote:
>
> > Joe H <[EMAIL PROTECTED]> wrote:
> > > I am new to using gdb so if I did something wrong let me know.
> >
> >   See doc/bugs
> I did read the bugs and it looked like it was only for core files, this
> doesn't generate a core file.
>
> >
> >   Type 'bt' in gdb, which will tell you where in the code it's
> > currently executing.
> >
> After your suggestion, I ran a bt on the radiusd process before and after
> the restart and both showed:
>
> #0 0x10250654 in __sys_poll () from /usr/lib/libc_r.so.4
> #1 0x1024fb39 in _thread_kern_sched_state_unlock () from /usr/lib/libc_r.so.4
> #2 0x1024f4ee in _thread_kern_scheduler () from /usr/lib/libc_r.so.4
> #3 0x0 in ?? ()
>
> Joe H.
>
> >   Alan DeKok.
> >
> >
> > -
> > List info/subscribe/unsubscribe? See 
> > http://www.freeradius.org/list/users.html
> >
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-28 Thread Joe H
On Thu, 27 Jan 2005, Alan DeKok wrote:

> Joe H <[EMAIL PROTECTED]> wrote:
> > I am new to using gdb so if I did something wrong let me know.
>
>   See doc/bugs
I did read the bugs and it looked like it was only for core files, this
doesn't generate a core file.

>
>   Type 'bt' in gdb, which will tell you where in the code it's
> currently executing.
>
After your suggestion, I ran a bt on the radiusd process before and after
the restart and both showed:

#0 0x10250654 in __sys_poll () from /usr/lib/libc_r.so.4
#1 0x1024fb39 in _thread_kern_sched_state_unlock () from /usr/lib/libc_r.so.4
#2 0x1024f4ee in _thread_kern_scheduler () from /usr/lib/libc_r.so.4
#3 0x0 in ?? ()

Joe H.

>   Alan DeKok.
>
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-27 Thread Alan DeKok
Joe H <[EMAIL PROTECTED]> wrote:
> I am new to using gdb so if I did something wrong let me know.

  See doc/bugs

  Type 'bt' in gdb, which will tell you where in the code it's
currently executing.

  Alan DeKok.


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-27 Thread Joe H
I have tried running the gdb program and it didn't mean much to me.  Here
is the output I got:

(gdb) attach 53964
Attaching to program: /usr/local/sbin/radiusd, process 53964
Symbols already loaded for /usr/lib/libcrypt.so.2
Symbols already loaded for /usr/lib/libcipher.so.2
Symbols already loaded for /usr/lib/libcrypto.so.3
Symbols already loaded for /usr/lib/libssl.so.3
Symbols already loaded for /usr/local/lib/libradius-1.0.1.so
Symbols already loaded for /usr/local/lib/libltdl.so.4
Symbols already loaded for /usr/lib/libc_r.so.4
Symbols already loaded for /usr/lib/libc.so.4
Symbols already loaded for /usr/local/lib/libldap_r.so
Symbols already loaded for /usr/local/lib/liblber-2.2.so.7
Symbols already loaded for /usr/local/lib/libsasl.so
Symbols already loaded for /usr/local/lib/libdb3.so.3
Symbols already loaded for /usr/lib/libpam.so.1
Symbols already loaded for /usr/local/lib/compat/pkg/libldap.so.2
Symbols already loaded for /usr/local/lib/compat/pkg/liblber.so.2
Symbols already loaded for /usr/lib/libssl.so.2
Symbols already loaded for /usr/lib/libcrypto.so.2
Symbols already loaded for /usr/local/lib/rlm_ldap-1.0.1.so
Symbols already loaded for /usr/local/lib/rlm_preprocess-1.0.1.so
Symbols already loaded for /usr/local/lib/rlm_realm-1.0.1.so
Symbols already loaded for /usr/local/lib/rlm_files-1.0.1.so
Symbols already loaded for /usr/local/lib/rlm_detail-1.0.1.so
Symbols already loaded for /usr/libexec/ld-elf.so.1
0x10250654 in __sys_poll () from /usr/lib/libc_r.so.4
(gdb) cont
Continuing.

** this is where I issued the restart **

Error accessing memory address 0x1029430c: No such process.


I am new to using gdb so if I did something wrong let me know.

Joe H.



On Wed, 26 Jan 2005, Alan DeKok wrote:

> Joe H <[EMAIL PROTECTED]> wrote:
> > The total controls that we use for dialup access seem to make one
> > connection to the radius server and hold it.
>
>   RADIUS is UDP.  There is no connection.
>
> > Seems like it's waiting for the connection to end before it closes.
>
>   Find out *where* in the code it's waiting.  That will tell you *why*.
>
>   Alan DeKok.
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-26 Thread Alan DeKok
Joe H <[EMAIL PROTECTED]> wrote:
> The total controls that we use for dialup access seem to make one
> connection to the radius server and hold it.

  RADIUS is UDP.  There is no connection.

> Seems like it's waiting for the connection to end before it closes.

  Find out *where* in the code it's waiting.  That will tell you *why*.

  Alan DeKok.

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-26 Thread Joe H
Looks like someone needs to read the rules.  Don't steal my thread, start
your own.

On Wed, 26 Jan 2005, [iso-8859-1] Fabio Viração wrote:

> Hi ;
>
> How can I send all these information to a Mysql Database ??
>
> Does anyone have any ideia that can help me ??
>
> Thanks
> Fabio
>
> Mon Aug 30 14:38:18 2004
> NAS-IP-Address = 192.168.115.4
> Cisco-NAS-Port = "CAS 1:0"
> NAS-Port-Type = Async
> User-Name = "351289767299"
> Called-Station-Id = "17863045678"
> Calling-Station-Id = "351212362299"
> Acct-Status-Type = Stop
> Service-Type = Login-User
> h323-gw-id = "h323-gw-id=Test0909"
> Cisco-AVPair = "h323-incoming-conf-id=D397A0 F9CA11D8 9519C3E7
> 31564DA6"
> h323-call-origin = "h323-call-origin=originate"
> h323-call-type = "h323-call-type=Telephony"
> h323-setup-time = "h323-setup-time=14:45:00.680 GMT Mon Aug 30 2004"
> h323-connect-time = "h323-connect-time=14:45:23.482 GMT Mon Aug 30
> 2004"
> h323-disconnect-time = "h323-disconnect-time=14:46:06.352 GMT Mon
> Aug 30 2004"
> h323-disconnect-cause = "h323-disconnect-cause=10"
> h323-voice-quality = "h323-voice-quality=0"
> h323-conf-id = "h323-conf-id=D397A0 F9CA11D8 9519C3E7 31564DA6"
> Acct-Session-Id = "EDD9"
>
>
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>

-
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-26 Thread Fabio Viração
Hi ;
How can I send all these information to a Mysql Database ??
Does anyone have any ideia that can help me ??
Thanks
Fabio
Mon Aug 30 14:38:18 2004
   NAS-IP-Address = 192.168.115.4
   Cisco-NAS-Port = "CAS 1:0"
   NAS-Port-Type = Async
   User-Name = "351289767299"
   Called-Station-Id = "17863045678"
   Calling-Station-Id = "351212362299"
   Acct-Status-Type = Stop
   Service-Type = Login-User
   h323-gw-id = "h323-gw-id=Test0909"
   Cisco-AVPair = "h323-incoming-conf-id=D397A0 F9CA11D8 9519C3E7 
31564DA6"
   h323-call-origin = "h323-call-origin=originate"
   h323-call-type = "h323-call-type=Telephony"
   h323-setup-time = "h323-setup-time=14:45:00.680 GMT Mon Aug 30 2004"
   h323-connect-time = "h323-connect-time=14:45:23.482 GMT Mon Aug 30 
2004"
   h323-disconnect-time = "h323-disconnect-time=14:46:06.352 GMT Mon 
Aug 30 2004"
   h323-disconnect-cause = "h323-disconnect-cause=10"
   h323-voice-quality = "h323-voice-quality=0"
   h323-conf-id = "h323-conf-id=D397A0 F9CA11D8 9519C3E7 31564DA6"
   Acct-Session-Id = "EDD9"


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-26 Thread Joe H
Is it possible that an active connection to the radius server could hold
the radius process from stopping or restarting properly?

The total controls that we use for dialup access seem to make one
connection to the radius server and hold it.  I'm wondering if this could
be causing the problem with what looks like looping.  Seems like it's
waiting for the connection to end before it closes.  If this is the case,
is there a way to make it force the close of the connection, kind of like
how a kill -9 does, only more graceful.

Joe H.

On Tue, 25 Jan 2005 [EMAIL PROTECTED] wrote:

> Joe H schrieb:
> > I updated all the server to freebsd 4.10
> (snipp)
> > Program received signal SIGTERM, Terminated.
> > 0x10250654 in __sys_poll () from /usr/lib/libc_r.so.4
> >
> > I'm not sure how helpful that will be to anyone but it's
> > all the information it showed.
>
> Sounds like it's telling you that everything is OK...
> Some very wild guessing:
> I'm wondering if there might be some problem with
> signal handling. IIRC there are some subtle differences
> between BSD and System V signal handling.
> Maybe ignoring the TERM signal during cleanup
> doesn't work quite as intended or something similar?
> Doing some experiments  with other signal
> processing functions (sigprocmask,sigaction) to
> replace "signal(SIGTERM, SIG_IGN);" or adding
> some output to the signal handling functions so
> you do see when they are called during shutdown
> might turn up something...
>
>  HTH,
>   Stefan
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-25 Thread Stefan . Neis
Joe H schrieb:
> I updated all the server to freebsd 4.10 
(snipp)
> Program received signal SIGTERM, Terminated.
> 0x10250654 in __sys_poll () from /usr/lib/libc_r.so.4
> 
> I'm not sure how helpful that will be to anyone but it's
> all the information it showed.

Sounds like it's telling you that everything is OK...
Some very wild guessing:
I'm wondering if there might be some problem with
signal handling. IIRC there are some subtle differences
between BSD and System V signal handling.
Maybe ignoring the TERM signal during cleanup
doesn't work quite as intended or something similar?
Doing some experiments  with other signal 
processing functions (sigprocmask,sigaction) to
replace "signal(SIGTERM, SIG_IGN);" or adding
some output to the signal handling functions so
you do see when they are called during shutdown
might turn up something...

 HTH,
  Stefan

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-24 Thread Joe H
I updated all the server to freebsd 4.10 with the latest patch release,
rebuilt world and kernel and I am still having the same issue when I
attempt to restart or HUP the radiusd process.  It seems to be looping as
Alan said.  I did do the gdb and when it I issue the radiusd.sh restart
command, it prints this to the screen and stops.

Program received signal SIGTERM, Terminated.
0x10250654 in __sys_poll () from /usr/lib/libc_r.so.4

I'm not sure how helpful that will be to anyone but it's all the
information it showed.

Let me know if this rings any bells.

Joe H.



On Wed, 19 Jan 2005, Alan DeKok wrote:

> Joe H <[EMAIL PROTECTED]> wrote:
> > With my situation, doing the restart of the process causes radius to stop
> > working and the radius process climbs to about 90% CPU usage.
>
>   It sounds like it's in a busy loop.
>
>   My suggestion is to use gdb to attach to the running process, and
> see where in the source it's busy-looping.
>
>   Alan DeKok.
>
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-19 Thread Alan DeKok
Joe H <[EMAIL PROTECTED]> wrote:
> With my situation, doing the restart of the process causes radius to stop
> working and the radius process climbs to about 90% CPU usage.

  It sounds like it's in a busy loop.

  My suggestion is to use gdb to attach to the running process, and
see where in the source it's busy-looping.

  Alan DeKok.


- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-19 Thread Joe H
> > Message: 8
> > Date: Wed, 19 Jan 2005 12:17:05 -0500 (EST)
> > From: Joe H <[EMAIL PROTECTED]>
> > To: freeradius-users@lists.freeradius.org
> > Subject: Freeradius hangs after a HUP
> > Reply-To: freeradius-users@lists.freeradius.org
> >
> > We have two seemingly identical freeradius servers, for this email lets
> > call them radius-1 and radius-2.  Both are FreeBSD 4.9 systems running
> > freeradius 1.0.1 with an Openldap 2.2.18 authentication method.  Both
> > machines run freeradius without a problem.  When I send a HUP to reload
> > the config files on radius-1, the radiusd process hangs and needs to be
> > killed and started.  If I do the same process on radius-2, it reloads
> > fine.  I have diffed all the configs and the only thing that is different
> > in them is the listen statements in the radiusd.conf, as they should be.
> > My question is, has anyone seen this before and if so, how was it fixed?
> >
> > Troubleshooting already done:
> > Checked configs for errors.
> > reinstalled freeradius
> >
> > Thanks.
> >
> >
> > --__--__--
> >
>
> We had this problem with two different versions (pre 1) to the point
> were we just gave up on HUP.  we just force a restart each time.  the 30
> second reload time doesn't affect the users as far as we can see and we
> ensure we get a clean load each time.  BTW, we are/were running this on
> Sol 8 and now Sol 9.
> --
> Terry J Fike Jr
> System Administrator
> MTA Solutions
> 907-793-4100
> [EMAIL PROTECTED]
>
> -
> List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html
>
With my situation, doing the restart of the process causes radius to stop
working and the radius process climbs to about 90% CPU usage.  It just
displays the process number over and over.  I have let it set for up to a
couple minutes with it never actually restarting.  Here is what I see:

# ./radiusd.sh restart
Stopping radiusd.
Waiting for PIDS: 366, 366, 366, 366, 366, 366, 366, 366, 366, 366, 366,
366, 366, 366^C

This is just an example for about 10 seconds worth of waiting but it does
the exact same thing whether I wait 10 seconds or 2 minutes.  I am
planning to do a fresh reinstall of all the ports along with a source
update unless I can figure out a solution for this.  We do quite a few
changes to the configs so this is becoming a problem.

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html


Re: Freeradius hangs after a HUP

2005-01-19 Thread Terry J Fike Jr


Message: 8
Date: Wed, 19 Jan 2005 12:17:05 -0500 (EST)
From: Joe H <[EMAIL PROTECTED]>
To: freeradius-users@lists.freeradius.org
Subject: Freeradius hangs after a HUP
Reply-To: freeradius-users@lists.freeradius.org
We have two seemingly identical freeradius servers, for this email lets
call them radius-1 and radius-2.  Both are FreeBSD 4.9 systems running
freeradius 1.0.1 with an Openldap 2.2.18 authentication method.  Both
machines run freeradius without a problem.  When I send a HUP to reload
the config files on radius-1, the radiusd process hangs and needs to be
killed and started.  If I do the same process on radius-2, it reloads
fine.  I have diffed all the configs and the only thing that is different
in them is the listen statements in the radiusd.conf, as they should be.
My question is, has anyone seen this before and if so, how was it fixed?
Troubleshooting already done:
Checked configs for errors.
reinstalled freeradius
Thanks.
--__--__--
We had this problem with two different versions (pre 1) to the point 
were we just gave up on HUP.  we just force a restart each time.  the 30 
second reload time doesn't affect the users as far as we can see and we 
ensure we get a clean load each time.  BTW, we are/were running this on 
Sol 8 and now Sol 9.
--
Terry J Fike Jr
System Administrator
MTA Solutions
907-793-4100
[EMAIL PROTECTED]

- 
List info/subscribe/unsubscribe? See http://www.freeradius.org/list/users.html