Click to See Complete Forum and Search --> : Xinetd service (afbackup) stops working after kernel update


tguignar
09-28-2004, 11:17 AM
Hi eveyone

I just upgraded my kernel to 2.4.27. Among other things that needed to be fixed, there is something I don't quite understand.

I was using the afbackup service, and since the new kernel it doesn't work anymore because the server-side service doesn't work (afbackup is based on a client-server model, in my case my box acts both as client and server, the server process must be started by xinetd).

If I type xinetd -d to see debug info, this is what I get:

[root@lemapc77 root]> xinetd -d
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/afbackup [line=15]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/chargen [line=10]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/chargen-udp [line=18]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/cups-lpd [line=17]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/daytime [line=11]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/daytime-udp [line=15]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/echo [line=15]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/echo-udp [line=14]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/ktalk [line=15]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/rsync [line=12]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/servers [line=13]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/services [line=13]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/sgi_fam [line=13]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/time [line=16]
04/9/28@17:04:57: DEBUG: 6495 {handle_includedir} Reading included configuration file: /etc/xinetd.d/time-udp [line=17]
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing chargen
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing chargen
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing printer
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing daytime
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing daytime
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing echo
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing echo
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing ntalk
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing rsync
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing servers
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing services
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing time
04/9/28@17:04:57: DEBUG: 6495 {remove_disabled_services} removing time
Service defaults
Instances = 60
CPS = max conn:25 wait:30
Bind = All addresses.
Only from: All sites
No access: No blocked sites
Logging to syslog. Facility = authpriv, level = info
Log_on_success flags = HOST PID
Log_on_failure flags = HOST

Service configuration: afbackup
id = afbackup
flags = REUSE NAMEINARGS IPv4
socket_type = stream
Protocol (name,number) = (tcp,6)
port = 2988
Groups = no
PER_SOURCE = -1
Bind = All addresses.
Server = /usr/local/backup/server/bin/afserver
Server argv = /usr/local/backup/server/bin/afserver /usr/local/backup/server/etc/backup.conf
Only from: All sites
No access: No blocked sites
Logging to syslog. Facility = authpriv, level = info
Log_on_success flags = HOST PID
Log_on_failure flags = HOST

Service configuration: sgi_fam
id = sgi_fam
flags = IPv4
type = RPC UNLISTED
socket_type = stream
Protocol (name,number) = (tcp,6)
Groups = no
PER_SOURCE = -1
Bind = localhost.localdomain
Server = /usr/bin/fam
Server argv = fam
RPC data
program number = 391002
rpc_version = 2
Only from: All sites
No access: No blocked sites
Logging to syslog. Facility = authpriv, level = info
Log_on_success flags = HOST PID
Log_on_failure flags = HOST

04/9/28@17:04:57: ERROR: 6495 {activate_normal} bind failed (Address already in use (errno = 98)). service = afbackup
04/9/28@17:04:57: ERROR: 6495 {activate_rpc} pmap_set failed. service=sgi_fam program=391002 version=2
04/9/28@17:04:58: DEBUG: 6495 {activate_rpc} Registered 0 versions of sgi_fam
04/9/28@17:04:58: DEBUG: 6495 {cnf_start_services} mask_max = 0, services_started = 0
04/9/28@17:04:58: CRITICAL: 6495 {init_services} no services. Exiting...

So it seems I have to problems here.

1. What is this business about the address being already in use? And how can it be fixed? I should have only one service answering to afbackup.

2. What on earth is this sgi_fam thing? What's broken?

Here are my xinetd.conf and xinetd.d/afbackup files:

xinetd.conf:
#
# Simple configuration file for xinetd
#
# Some defaults, and include /etc/xinetd.d/

defaults
{
instances = 60
log_type = SYSLOG authpriv
log_on_success = HOST PID
log_on_failure = HOST
cps = 25 30
}

includedir /etc/xinetd.d

xinetd.d/afbackup:

service afbackup
{
flags = REUSE NAMEINARGS
socket_type = stream
protocol = tcp
wait = no
user = tguignar
server = /usr/local/backup/server/bin/afserver
server_args = /usr/local/backup/server/bin/afserver /usr/local/backup/server/etc/backup.conf
}

I'm running RedHat 9.

[root@lemapc77 root]> uname -a
Linux lemapc77 2.4.27 #1 SMP Fri Sep 10 11:30:47 CEST 2004 i686 i686 i386 GNU/Linux

JohnT
09-28-2004, 11:25 AM
When upgrading your kernel did you use "make oldconfig"?

tguignar
09-29-2004, 03:24 AM
I'm sorry but the actual kernel update was done by someone else, who is currently away.

Is there another way to find out?

Thanks,
T.

Hayl
09-29-2004, 08:28 AM
the address already in use means that the port is taken by another process.

are you absolutely sure that the person did not inadvertantly upgrade some other packages as well when they were upgrading the kernel? those errors look like an upgrade to xinetd was done and added a bunch of services that were previously disabled/not there and now one or more are conflicting with afbackup. it doesn't look to me like a kernel thing at all. OR it may be a daemon that is not running through xinetd that happens to use the 2988 port that afbackup uses.

What port(s) does afbackup use? NM -- reread it and found it. NM reread it and i found it - 2988.

Find out what else has that port open that is stopping afbackup from getting it.

You can try to use nmap, ps, and fuser to determine which process has the port open.

tguignar
09-29-2004, 08:35 AM
Well, I am sure of nothing. Since I don't know a lot about Linux, I usually let this guy sort it out. But now, he is away and firstly I kinda need this backup thing and secondly I thought I may be able to solve this myself.

If some tools need to be updated, I will do it, but in the mean time, I don't understand how updating or not updating a package has to do with xinetd. Shall I upgrade xine? I thought this kernel update stuff wasn't such a big deal for already installed apps...

Is there no way to find out then WHICH process is blocking the port that was free for afbackup in the old kernel?

Thanks for your help, folks, and sorry for being unable to answer you... :-(

JohnT
09-29-2004, 12:01 PM
Try running "strace" on the application. (See "man strace)

tguignar
09-30-2004, 07:11 AM
On which application?

The server? I cannot run it (it must be started by xinetd).

The client? I already know the source of the error: it is because the server is not running...

Or can xinetd be started manually?

JohnT
09-30-2004, 09:54 AM
"All you wanted to know about xinted, but were afraid to ask" :D
http://www.openna.com/documentations/articles/xinetd/index.php