Hi,

i have a problem with freeradius executing the checkrad script.
I get "Check-TS: unknown error in waitpid()"

child_pid = -1;
for (n = 0; n < 10; n++) {
        sleep(1);
        radlog(L_ERR, "pid: %d", pid);
        child_pid = waitpid(pid, &status, WNOHANG);
        radlog(L_ERR, "child_pid: %d, %s", child_pid, strerror(errno));
        /*if ((child_pid < 0) || (child_pid == pid)) {
                found = 1;
                break;
        }*/
}

For testing purposes i replaced the call to rad_waitpid with waitpid.
As soon as the checkradius script is exiting the call returns with -1
and errno set to "No child processes".

here is the output from the above loop (checkrad has a sleep(5) in it):

pid: 3831
child_pid: 0, Success
pid: 3831
child_pid: 0, Success
pid: 3831
child_pid: 0, Success
pid: 3831
child_pid: 0, Success
pid: 3831
child_pid: 0, Success
pid: 3831
child_pid: -1, No child processes
pid: 3831
child_pid: -1, No child processes
pid: 3831
child_pid: -1, No child processes
pid: 3831
child_pid: -1, No child processes
pid: 3831
child_pid: -1, No child processes

System is Linux 2.6.9.

Regards

Stephan Jaeger


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

Reply via email to