linux-l: leafnode Problem

Jens Dreger dreger at physik.fu-berlin.de
Mo Nov 1 00:08:43 CET 1999


Hallo Mukunda !

> > Try telnet localhost 119 ...
> 
> Da sagt er sowas wie 
> 
> Trying 127.0.0.1...
> Connected to debian.
> Escape character is '^]'.
> Connection closed by foreign host

Solange Du auf "telnet localhost 119" obige Antwort bekommst, brauchst Du
Dir um slrn oder NNTPSERVER keine Gedanken zu machen. Dass fetch
funktioniert besagt auch nichts, weil es sogar funktionieren wuerde, wenn
Du den Rest von leafnode loeschen wuerdest (vielleicht bis auf die
config-Dateien). Leafnode von der Konsole zu starten, kann nicht
funktionieren, weil es nicht einmal _versucht_, ein bind auf port 119
durchzufuehren. Daher kannst Du auch so viele leafnodes gleichzeitig von
der Kommandozeile starten, wie Du Lust hast. Ob leafnode _unabhaengig_ von
der inet.d-Konfiguration funktioniert, kannst Du so aber immerhin
feststellen:

|root> leafnode          ( ohne '&' !)
|200 Leafnode NNTP Daemon, version 1.8.1 running at watson.tp.jmd
|help
|500 Read RFC 977 and 1036 for elucidation
|list
|alt.1d 1 1 0 One-dimensional imaging, & the thinking behind it.
|alt.2600 1 1 0 The magazine or the game system.  You decide.
|alt.2600hz 1 1 0 Like alt.mag.2600, only different.
|...

Diese Liste ist der Inhalt von /var/spool/news/leaf.node/groupinfo. Sollte
sie nicht da sein, hat fetch irgendwas vermasselt. Die Pfade koennen bei
Dir natuerlich auch anders lauten.

Wenn sich Dein leafnode auf der Konsole meldet (bei Eingabe von eben
"leafnode"), dann sollte es folgendermassen moeglich sein, dies auch dem
"telnet localhost 119" beizubringen:

Beteiligte Programme: inetd, tcpd, leafnode, (syslogd)

1) Funtioniert inetd richtig ?

Zeile in /etc/inetd.conf eintragen:
nntp	stream	tcp	nowait	news	/bin/echo /bin/echo here we are

inetd.conf bitten, dies auch zu beherzigen:
|root> kill -HUP `pidof inetd`

testen:
|root> telnet localhost 119
|Trying 127.0.0.1...
|Connected to localhost.
|Escape character is '^]'.
|here we are                                              <---- OK
|Connection closed by foreign host.

Du kannst auch inetd ganz stoppen und dann in einem Fenster mittels 
"inetd -d" starten. Dann siehst Du (u.a.) beim Aufruf von telnet:
|someone wants nntp
|accept, ctrl 6
|9538 execl /bin/echo
|9538 reaped

2) Funtioniert tcpd richtig ?

Zeile in /etc/inetd.conf aendern:
nntp    stream  tcp     nowait  news  /usr/sbin/tcpd /bin/echo here we are

inetd.conf bitten,...
|root> kill -HUP `pidof inetd`

testen:
|root> telnet localhost 119
|Trying 127.0.0.1...
|Connected to localhost.
|Escape character is '^]'.
|here we are                                           <---- OK
|Connection closed by foreign host.

Diesmal sagt das inetd-Fenster:
|someone wants nntp
|accept, ctrl 6
|9543 execl /usr/sbin/tcpd
|9543 reaped

tcpd loggt auch, jedoch mittels syslogd. Wohin das dann genau geht, steht
in /etc/syslog.conf. Du kannst auch kurz mal eine Zeile ala
*.*     /var/log/everything
in /etc/syslog.conf reinschreiben (Vorsicht: TABs), syslogd ein -HUP
schicken und dann sollte beim Aufruf von telnet in /var/log/everything die
Zeile:

|Oct 31 23:55:29 watson echo[9543]: connect from 127.0.0.1

auftauchen. Diese kommt nun von tcpd.

3) Funktioniert leafnode richtig ?

Zeile in /etc/inetd.conf aendern:
nntp    stream  tcp     nowait  news  /usr/sbin/tcpd /usr/sbin/leafnode

inetd.conf bitten,...
|root> kill -HUP `pidof inetd`

testen:
|root> telnet localhost 119
|Trying 127.0.0.1...
|Connected to localhost.
|Escape character is '^]'.
|200 Leafnode NNTP Daemon, version 1.8.1 running at watson.tp.jmd   <-- OK
|quit
|205 Always happy to serve!
|Connection closed by foreign host.

Im Fenster von inetd hat sich nichts veraendert, weil inetd immernoch nur
tcpd startet, aber tcpd loggt jetzt:

|Nov  1 00:03:48 watson leafnode[9566]: connect from 127.0.0.1
|Nov  1 00:03:48 watson leafnode[9566]: config:server is news.fu-berlin.de

So, da jetzt "telnet localhost 119" gehen sollte, kannst Du anfangen,
ueber slrn und NNTPSERVER usw. nachzugruebeln.

Jens.

________________________________________________________________________
Jens Dreger                     | Freie Universitaet Berlin
Cauerstrasse 35a                | Fachbereich Physik, WWW Administration
10587 Berlin                    | Arnimallee 14
Tel: (030)342-3616              | 14195 Berlin
Fax: (089)66617-10770           | Tel.: (030)838-4774
                                | Raum: 0.4.08
jens.dreger at physik.fu-berlin.de | webadmin at physik.fu-berlin.de






Mehr Informationen über die Mailingliste linux-l