* fping help under OSF/1 LOOOONNNNGGGG (fwd)
@ 1995-04-04 22:01 Mike Hatz
0 siblings, 0 replies; 2+ messages in thread
From: Mike Hatz @ 1995-04-04 22:01 UTC (permalink / raw)
To: tru64-unix-managers
In prep for the upcoming Satan release, the fping utility is required for
that. The makefile is short so I will post fping's Makefile. The question
I have is what library call do I need to define? The program compiled okay
but anytime I run it, all hosts come back as being down and the program
tries to hit 255.255.255.255, when I specify a hostname:
The lib for lsocket won't compile as it is in here.
>fping -eds nox.cs.du.edu
255.255.255.255 is unreachable
1 hosts
0 alive
1 unreachable
0 unknown addresses
4 timeouts (waiting for response)
4 pings sent
4 pings received
0 msec (min round trip time)
0 msec (avg round trip time)
0 msec (max round trip time)
10.222 sec (elapsed real time)
It completely ignores the hostname, but runs just fine on the IP address.
It correctly identifies the intended host.
>fping -eds 130.253.192.89
nyx10.cs.du.edu is alive (747 msec)
1 hosts
1 alive
0 unreachable
0 unknown addresses
0 timeouts (waiting for response)
1 pings sent
1 pings received
747 msec (min round trip time)
747 msec (avg round trip time)
747 msec (max round trip time)
1.118 sec (elapsed real time)
The man page shows a -d option for DNS but that doesn't help.
======================================
The makefile:
PROG= fping
OBJS= fping.o
SRC= fping.c
BIN= /usr/local/bin
MAN= /usr/man/manl
MANSRC= fping.man
MANDST= fping.l
#
# Interval is the minimum amount of time between sending a ping packet to
# any host.
#
# Timeout is the minimum amount of time between sending a ping packet to
# a particular host.
#
# Retry is the number of ping packets to send to a host before giving up.
#
DEFAULTS= -DDEFAULT_INTERVAL=25 \
-DDEFAULT_TIMEOUT=2500 \
-DDEFAULT_RETRY=3
#
# some systems need the following:
#LIBS= -lsocket
all: $(PROG)
$(PROG) : $(OBJS)
$(CC) $(OBJS) -o $(PROG) $(LIBS)
$(OBJS) : $(SRC)
$(CC) $(CFLAGS) -c $(DEFAULTS) $(SRC)
# if you don't have install type:
# cp $(PROG) /usr/local/bin
# chown root /usr/local/bin/$(PROG)
# chmod 4555 /usr/local/bin/$(PROG)
# strip /usr/local/bin/$(PROG)
#
install:
install -c -m 4555 -o root -s $(PROG) $(BIN)/$(PROG)
install -c -m 0444 -o root $(MANSRC) $(MAN)/$(MANDST)
clean:
rm -f a.out core *~ *.o $(PROG)
shar:
shar README CHANGES fping.c fping.man Makefile README.VMS > fping.shar
^ permalink raw reply [flat|nested] 2+ messages in thread* Re: fping help under OSF/1 LOOOONNNNGGGG (fwd)
@ 1995-04-05 6:52 Roman Gollent
0 siblings, 0 replies; 2+ messages in thread
From: Roman Gollent @ 1995-04-05 6:52 UTC (permalink / raw)
To: tru64-unix-managers
The problem has nothing to do with fping's makefile. OSF (At least version
3.0 doesn't come with libsocket).
The problem lies in this line of fping.c:
u_long ipaddress = inet_addr(host);
this should actually be:
u_int ipaddress = inet_addr(host);
This change allows fping to work properly with our machine (OSF 3.0).
Being an honest man, I would like to point out that August Wohlt
(wohlt@eniac.seas.upenn.edu) helped me find this "bug/feature/os
quirk". Sorry if this doesn't read like a standard bug report, as I
have never written one before.
Cheers,
Roman
PS: Hope this came in time for the release of satan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~1995-04-05 6:52 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
1995-04-04 22:01 fping help under OSF/1 LOOOONNNNGGGG (fwd) Mike Hatz
-- strict thread matches above, loose matches on Subject: below --
1995-04-05 6:52 Roman Gollent
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox