======================================================================
BBS <==> News H{ innbbsd 
======================================================================
<1>. \²
<2>. H Server Gateway (innbbsd) w˩Mϥ
   a. ]w bbsname.bbs
   b. ]w nodelist.bbs
   c. ]w newsfeeds.bbs
   d. ]w innbbs.conf
   e.  innbbsd (options )
<3>. H Client Gateway (bbsnnrp) w˩Mϥ
   a. ]w activefile
   b. wɶ] bbsnnrp
<4>. eH{ bntplink w˳]w   
   a. bbaname.bbs P bntplink
   b. nodelist.bbs  P bntplink
   c. newsfeeds.bbs P bntplink
   d.  bntplink
<5>. Server gateway innbbsd { (ctlinnbbsd) 
<6>. activefile and history database
<7>. BBS implementation dependent part: receive_article.c
<8>. H[c
<9>. ~E_ and FAQ
======================================================================
<1>. \²
----------------------------------------------------------------------
A). Dʦ (client gateway) MQʦ (server gateway) H
----------------------------------------------------------------------
ثeP tw.bbs H BBS ҥΤ{̷ӶǫH覡
iϤ:
1. DʨH, κ٬ client gateway.
   @g modem qܼ BBShΦ覡DʥH
   news client V news server wŪ.
   NSYSU Formosa BBS ҥΤH{O@ client gateway.
2. QʵH, κ٬ server gateway.
   BBS ]@ server, uQʦaݤW寸e,
   O@ news server ΨӶǰe news article k.
   Phoenix BBS Ҫ in.bntpd NO@ server gateway.

  o gateway UuI. RpU:
1. client gateway  maintain ŪO, P@
   news reader  newsrc .  client ۥDʰ, iH
   DʨMwɥhH, nǰQװ.
2. server gateway L maintain ŪO, unQʦaݤW寸
   sHeL. server gateway ۥD, eHɾMeQװ.
   ѤW寸]w.

BBS ŶqݨDM@x, HMwĥΨ@ gateway.
1. QװϦh.
   Yh, client gateway XA. pGܦh, Ҽ{ĥ server gateway.
   ŪOn@, רO news server w| renumber active 
   ʧ@, client i~P.
2. O_QsuPBH, Y@sHeX, LWiݨ.
   oӥu server gateway F.
3. O_n󯸬H. Y client gateway Ӱ.
   pGn౵OeӪHT,
   a. ٭n@ ٬ "control"  "control.cancel"  news Qװ.
      q`oӰϪq۷j, i໷j BBS Q઺`.
   b. O artno P BBS article path Y, A stat news server.
   c. extract header (xhdr Control)
   server gateway ΦAB~QװϧYi󯸬H.
4. ӤHϥΩΨϥΪ̤h BBS ĳĥ client gateway.
   Τh, H`vTj,
   ĳĥ server gateway.
5. QnۥDʰ client gateway.
   QnK۳s, s@uPı̥ server gateway.

----------------------------------------------------------------------
B). innbbsd 
----------------------------------------------------------------------
۹ mfchen  bbsinnd ( perl) server gateway,
Ms BBS  news-bbs client gateway, ڥ C N
G̾X, 䴩 Sun-OS 4.x, Sun Solaris, HP-UX, IRIX, 
AIX M Linux. 

innbbsd X server gateway M client gateway. 
ƱSHbۦP. SʦpU:
  1. H C implement.
  2. 䴩h OS.
  3. server gateway M client gateway æs.
     ih news server feed M h client gateway
     process PɹB@.
     client gateway process ib䥦D BBS server .
     ۦPQװϥiPɥѦh news server e, αqP
     news server .
  4.  host load vTbյ.
  5. server gateway M client gateway Bz󯸬H.
  6. |쭫ƪ峹.
  7. server gateway ig news server ϤG BBS H.
  8. standalone single process concurrent server(uI ?.)
  9  server gateway M bbsinnd ۮe.
                             
 I:
  1.  maintain @ 1MB k dbz .
  2. client gateway ntX server gateway ϥ. YϤ
      news server feed, ]n] server gateway.
     ثe client gateway process NO@@
     user D feed ӷ.  client gateway process ib
     BBS server g unix-domain socket feed  server gateway
     ΦbP host g inet/tcp  BBS server.
     i mfchen  bbsinnd tX client gateway.
  3. standalone process (I ?.)
  4. BBS -> News  mfchen  bntplink. אּ䴩
     client gateway.
 ----------------------------------------------------------------------
======================================================================
<2>. H Server Gateway (innbbsd) w˩Mϥ
   a. ]w bbsname.bbs

b. ]w nodelist.bbs
   innbbsd  nodelist.bbs su.
   p
#sitename hostname                 PROT(port) comments
bbsroute  bbsroute.xxx.nctu.edu.tw POST(119) xxxx news server

   h bbssroute.xxx.nctu.edu.tw ~ connect.
   
c. ]w newsfeeds.bbs
d. ]w innbbs.conf
e.  innbbsd (options )
 ----------------------------------------------------------------------
!!! ĵi !!!
իeгƥQ BBS .
!!!!!!!!!!!!

You can get from 

ftp://ftp.csie.nctu.edu.tw/pub/bbs/misc/innbbsd/innbbsd-??.tar.gz

patch from the previous version, use
patch -p1 < innbbsd-patch.xx-xx

A. FEATURES:
   1. support Sun-OS, Solaris, Linux, AIX, IRIX, HP-UX 
   2. carry(receive) news from mulitple servers
      by mulitple client gateways or server gateways.
   3. feed multiple servers (BBS or News) by post or ihave protocol to
      different port number (nntp ,7777, ....)

B. Test and Install

   1. Please read innd/README and 
      change your newsfeeds.bbs, nodelist.bbs, and bbsname.bbs
   2. read innd/src/modify.doc

   3. edit Makefile and change these two lines:
   BBSHOME=/u/staff/bbsroot/csie_util/bntpd/home
   BBS_SRC=/u/staff/bbsroot/bbs_src
     
      into

   BBSHOME=/tmp/bbs
   BBS_SRC=/your/bbs-src-directory

   4. make
   5. mkdir /tmp/bbs/boards /tmp/bbs/boards/test /tmp/bbs/innd
      copy your newsfeeds.bbs, nodelist.bbs and bbsname.bbs to /tmp/bbs/innd
   6. add to newsfeeds.bbs
      tw.bbs.test test test-news
   7. add to nodelist.bbs
      test-news news-server-your-want-to-post POST(119) 
      your-site-name your-host-domainname     IHAVE(7777)
   8. add a line to innd/test-news.active
      tw.bbs.test 0000000000 0000000001 y
   9. run 
      innbbsd
      bbsnnrp news-server-your-can-read innd/test-news.active
  10. examine if /tmp/bbs/boards/test has some files and make sure if
      OK.  

C. Install and Run your Server Gateway
   HWխYٺN. Ч Makefile 
   BBSHOME=\"/tmp/bbs\"
   BBS_SRC = /your/bbs-src-directory
   ]wT BBSHOME. 
   make clean
   make
   kill `cat /usr/tmp/innbbsd-7777.pid`
   
   su  bbsuser (M bbs P uid)
   1. ϶]L mfchen  in.bntpd, ഫ history pU:
      hisconvert ~bbs/usr/tmp/history ~bbs/usr/tmp/history.z > ~bbs/innd/history 
      mkhistory ~bbs/innd/history
   2. innbbsd port-no (default=7777) 
    
D. ] client (bbsnnrp) gateway
   1. C bbsnnrp process ΤP active file.  active file
      Q bbsnnrp process ϥή, Фŭק. קe() bbsnnrp process.  
   2. active file format pU:
      newsgroup-name high-number low-number y
      ....... 
      
      Ҧp:
      tw.bbs.test 0000000000 0000000001 y
      tw.test 0000000000 0000000001 y
      
   3. ] news server O news.csie.nctu.edu.tw, 
      active file b ~bbs/innd/news.csie.nctu.edu.tw.active
      
      bbsnnrp news.csie.nctu.edu.tw ~bbs/innd/news.csie.nctu.edu.tw.active
      
   4. Yn󯸬H, news server  control.cancel h[J  
      control.cancel 0000000000 000000001 y
      YL control.cancel h 
      control 0000000000 000000001 y
      
      ]@ 
        bbsnnrp -c server control-active-file
      
      bbsnnrp  control  control.cancel |SOBz, un header.
      
   5. YĤ@] bbsnnrp, ĳn¤峹, u reset active file, 
      bbsnnrp -c server-to-receive active-file   
      
   6. iNHWʧ@[ crontab wɧ,  Υ   
      bbsnnrp -w wait-time ......... &
      h bbsnnrp C wait-time @.
      
   7. bbsnnrp ib䥦], Ҧp 
      BBS host: bbs.dorm10.nctu.edu.tw
      bbsnnrp host: ccsun1.cc.nctu.edu.tw
     
      b bbs.dorm10.nctu.edu.tw ] innbbsd 7777 ñN 
      ccsun1.cc.nctu.edu.tw [J nodelist.bbs, p
      bbsnnrp-ccsun1 ccsun1.cc.nctu.edu.tw
      
      ]
      bbsnnrp -r bbs.dorm10.nctu.edu.tw -p 7777 server active-file
            
E. Feed h news servers  BBS server
   ק nodelist.bbs, newsfeeds.bbs ,
   Ҧp nodelist.bbs
   news-server1 news-server1-full-domain IHAVE(119) comment .. server gateway
   news-server2 news-server2-full-domain POST(119)  comment .. client gateway
   bbs-server1  bbs-server1-full-domain  IHAVE(7777) comment .. server gateway
   bbs-server2  bbs-server2-full-domain  IHAVE(7777) comment .. server gateway
   
   newsfeeds.bbs
   tw.bbs.test test news-server1 news-server2 bbs-server1 bbs-server2
   tw.test     twtest news-server2 bbs-server1
   ........
   
                          
F. Related commands
   innbbsd [portno]
   bbsnnrp [options]
   mkhistory history-file
   makedbz history-size

G. 䥦
   innbbsd u]@, বh news server M bbs server feed.
   bbsnnrp ]h, Ʀܦb䥦XiH.
   
   innbbsd M bbsnnrp  newsgroups i.
   
H. BBS zL News server    
   nodelist.bbs [J
   bbs-server1 bbs-server1-host-name IHAVE(7777)
   bbs-server2 bbs-server2-host-name IHAVE(7777)
   
   newsfeeds.bbs
   newsgroups  board-name name1 name2 ...
   tw.bbs.test test       bbs-server1 bbs-server2
 ------------------------------------------
 innbbsd options:
 Usage: ./innbbsd [options] [port [path]]
        -v (verbose log)
        -h|? (help)
        -n   (not to use in core dbz)
	-i   (start from inetd with wait option)
        -c connection  (maximum number of connections accepted)
======================================================================
<3>. H Client Gateway (bbsnnrp) w˩Mϥ
   a. ]w activefile
   b. wɶ] bbsnnrp
o client gateway A "î news".
Pɥi
1.  A server  a group,  B server  b group.
   a M b iHۦPΤP.
   Ҧp,  netnews.ntu.edu.tw  ntu.dep.csie,ntu.dep.ee,tw.bbs.*
          aidebbs.edu.tw  csie.bbs.aidesysop,tw.bbs.*
          news.mgt.ncu.edu.tw  ncu.mgt.*
   ]nP active file, p act1, act2, act3
   ]
   bbsnnrp netnews.ntu.edu.tw act1
   bbsnnrp aidebbs.edu.tw act2
   bbsnnrp news.mgt.ncu.edu.tw act3
                                       
2.  load, κc], @x bbsnnrp M host, uΨӶ] bbsnnrp,
   A䥦 BBS servers  news servsers.
   (Ψ "" news)
   bbsnnrp -r bbs1.domain1 -p 7777 newsa.domainb bbs1.newsa.active
   bbsnnrp -r bbs2.domain2 -p 7777 newsb.domainb bbs2.newsb.active
      bbsnnrp -r newsc.domainc -p 119 newsx.domainx newsc.newsx.active
   (q newsx  news A newsc, a gateway ? )
   ............................
         
MjqŪɥ§axD server PN.
---------------------
bbsnnrp options:
Usage: ./bbsnnrp [options] nntpserver activefile
       -h|? (help) 
       -v (verbose protocol transactions)
       -c (reset active files only; don't receive articles)
       -r remotehost(send articles to remotehost, default=local)
       -p port|(send articles to remotehost at port, default=7777)
          path(send articles to local at path, default=~bbs/innd/.innbbsd)
       -w seconds ( > 1 wait for seconds and run infinitely, default=once)
       -n (don't ask innbbsd server and stat articles)
       -a max_art(maximum number of articles received for a group each time)
          default=100
       -s max_stat(maximum number of articles stated for a group each time)
          default=1000
       -t stdin|nntp (default=nntp)
       -g newsgroups

Please E-mail bug to skhuang@csie.nctu.edu.tw or
post to tw.bbs.admin.installbbs
======================================================================
<4>. eH{ bntplink w˳]w   
   a. bbaname.bbs P bntplink
   b. nodelist.bbs  P bntplink
   c. newsfeeds.bbs P bntplink
   d.  bntplink
bbsnnrp uΨӨ news,  news Xh٭nt~] "bntplink".
ܩpSM.  bntplink ΪkаѦ bbsnnrp-??/innd/README
( README O Phoenix BBS innd , 䤤 nodelist.bbs M newsfeeds.bbs
 gkP, Ч innbbsd . in.bntpd ]ά[,  innbbsd)
 
Ĥ@] bntplink e (] BBS home b /home/bbs/)
cmd> bbspost visit /home/bbs       # Ĥ@|D`[
     New article listed:
     test    M.770323413.A   SYSOP   դ峹 ...
     ....                                    # CXҦeH峹
     UӨ test board post @gդ峹, MUCRO
cmd> bntplink /home/bbs
bntplink n bbsnnrp-??/innd/bntplink ӫD Phoenix BBS .
t newsfeeds.bbs M nodelist.bbs gk]M Phoenix BBS  innd P.
                                                             
======================================================================
<5>. Server gateway innbbsd { (ctlinnbbsd) 
  ctlinnbbsd reload   : reload datafiles for innbbsd
  ctlinnbbsd shutdown : shutdown innbbsd gracefully
  ctlinnbbsd mode     : examine mode of innbbsd
  ctlinnbbsd addhist <mid> path: add history
  ctlinnbbsd grephist <mid>: query history
  ctlinnbbsd hismaint : maintain history
  ctlinnbbsd getrusage: get resource usage (-DGETRUSAGE)
  ctlinnbbsd mallocmap: get malloc map     (only Sun-OS supported)
======================================================================
<6>. activefile and history database
a. pGn bbsnnrp [ crontab ӫ]
Mb command line @.
for example, CQ@:
10,20,30,40,50 * * * * /home/bbs/innd/bbsnnrp news-server \
  /home/bbs/innd/active-file > /dev/null 2>&1
  
 bbsnnrp t@ӦnBOi̿MQװϯS (MP server), P active-file
  AHPWvh: Ҧp
  1. active1: tw.bbs.rec.rail (Ҧp K)
  2. active2: tw.bbs.comp.* 
  3. active3: tw.bbs.rec.* 
  3. active4: control  control.cancel
  
 i]C active1, C active2,
 CQ active3, Cѧ active3 @:
* * * * * bbsnnrp news-server active1 > /dev/null 2>&1
0,5,10,15,20,25,30,35,40,45,50,55 * * * * bbsnnrp news-server active2 > /dev/null 2>&1
2,12,22,32,42,52 * * * * bbsnnrp news-server active3 > /dev/null 2>&1
14 3 * * * bbsnnrp news-server active4 > /dev/null 2>&1

:   ٦ NOڧ^Ӫ峹򳣬O@ӤHeO !!pGu̷s..Bn
:    ƤSӥOO......
  
Default C̦h@ group u 1 ʫ, קKy news server tL,
ĳpU:
1. խYn«H, ն]@
   bbsnnrp -c news-server active-file
   o˱Nu reset active-file Ӥ news. HA] -c, ̷s.
2. Yn«H, ru server load, hH,  -a w̦hHq:
   pC̦h 500 ,
   bbsnnrp -a 500 news-server active-file
                
   `pYϦVh server ۦP group ]|.
======================================================================
<7>. BBS implementation dependent part: receive_article.c
Rabit Ʊ innbbsd 䴩 Palm BBS, Samson ]Ʊڼg@
dbz server 䴩 Power BBS, K Secret BBS, Pivot BBS
ݯ_@ָѨM,  Samson dbz server nD, ڬOƱ
PBBS Ҽ{ϥ innbbsd. ] innbbsd үӥΪ귽DnNO
bBz dbz. un PBBS (Palm, Secret,  Pivot) 
receive_article() M cancel_article_front(mid)  routine.
ΥHU覡Bz:

   innbbsd  article N峹 header s extern char *HEADER[]
                                 body        extern char *BODY;
   (Subject s HEADER[SUBJECT_H], From s HEADER[FROM_H], 䥦)
   A call receive_article()  cancel_article_front(mid)
   PBBS, Palm, Pivot  Secret BBS ung:
    1. receive_article: N char *HEADER M char *BODY ̨峹xs覡gJ.
       A call storeDB() N article path s dbz.
    2. cancel_article_front(mid):  call fetchDB(mid) o article filename
       (to be cancelled), A̦U BBS  cancel 覡Bz.
NFHU\:
1.  multiple feeds (duplicated feed is OK)
2. only single process (won't fork)
3.  bbsnnrp feed   (bbsnnrp M BBS L, ]iH feed News server)

 innbbsd |íw, ĲvMt load vT|b, Hᶷnק諸a褣,
 ڤӧƱP maintain dbzserver M innbbsd  source.
 (] innbbsd DnNO@ dbzserver)
 
 jaY౵, ڦAN innbbsd zn, X BBS implementation
 dependend M independent ,  PBBS, Palm, Pivot, M Secret BBS ϥ.
   
======================================================================
<8>. H[c
[Q.1]: ۥѭ (skylark@Venus.Dorm9.nctu.edu.tw) :
   p̳̪][F@ӯ(ϥ Phoenix 4.0)AӥBwgH\
   (ϥΤ innd {)CpQn innbbsd , bbsnnrp
   {ӹFHتAb}aeH]wUnp]wG
ơ wg@ news server HڧڤQn}aکMH
   AȡCboرpUڭnp]wH

[A.1]:
Ywíw, ګĳn innbbsd. x Phoenix innd B@, 
innbbsd ]íFA. 

innbbsd 򥻤WɶqM Phoenix bbsinnd ۮe, 令䴩 client gateway,
Yew] bbsinnd, HUഫ:
1. ഫ history
   Х disable b inetd.conf  in.bntpd, kill -1 pid-of-inetd
   cd ~bbs/usr/tmp
   hisconvert history history.z > ~bbs/innd/history 
   (hisconvert b innbbsd, ~bbs/usr/tmp iS history.z)
   cd ~bbs/innd
   mkhistory history 
   (innbbsd make |ͤ@ mkhistory )
   mv history history.o
   mv history.n history
   mv history.n.dir history.dir
   mv history.n.pag history.pag
2. newsfeeds.bbs, nodename.bbs .
3. nodelist.bbs 
name          hostname & domainname                    full name
  אּ
name          hostname & domainname   protocol(port)   full name

Ҧp
ccnews        ccnews.nctu.edu.tw      IHAVE(119)       News server in CC

4. bntplink  innbbsd/innd  bntplink
5.  innbbsd [port-no]
un port-no Me in.bntpd ] port @, news server ΰ.

[Q.2]:
Ƣ ڷQM䥦 bbs H(zL news server )AڪD
   innbbsd iHFonDAOnp]w~|}aeH
   ]wH
[A.2]   
] bbs-1.domain1 bbs-2.domain2 bbs-3.domain3 Qg news server H,
1. T] innbbsd  innbbsd M bntplink  
2. TN[JU۪ nodelist.bbs, p
#[nodelist.bbs]
bbs-1 bbs-1.domain1 IHAVE(7777) bbs-1 server
bbs-2 bbs-2.domain2 IHAVE(7777) bbs-2 server
bbs-3 bbs-3.domain3 IHAVE(7777) bbs-3 server
news-1 news-1.domain4 IHAVE(119) news-1 server
3. newsfeeds.bbs ]w, bbs-1.domain1  newsfeeds.bbs
   (] bbs-1 ] news-1)
# newsgroup    board      server1 server2 ....
localbbs.group board-name bbs-2 bbs-3
tw.bbs.test    test       news-1 bbs-2 bbs-3 

bbs-2.domain2  newsfeeds.bbs
# newsgroup    board      server1 server2 ....
localbbs.group board-name bbs-1 bbs-3

bbs-3.domain3  newsfeeds.bbs
# newsgroup    board      server1 server2 ....
localbbs.group board-name bbs-1 bbs-2

Awɶ] bntplink. 䤤 localbbs.group iۦW, unT
nYi. 

innbbsd nBO, bbs-1, bbs-2, bbs-3 ٥iAۦ汵Nƶq news server
feed, ζ]h bbsnnrp  news.

======================================================================
<9>. ~E_ and FAQ
--------------------
a) BBS M News Server bP@xW, wˮ, O_nSOdN ??
un innbbsd ]b port 119 (nntp) ӨSD.

٦Ъ`N active file high, low number @wnOd
10 (> 10)  digit. Ҧp:
tw.bbs.test 0000000000 0000000001 y

oO] bbsnnrp Q mmap N active file  map 
memory. Y digit Ƥ|Q truncated.
Y޲z news server g, ӴND active file
 high, low ]ndQ digits F.

S]O mmap, Yb bbsnnrp  active file N|
G@o. oM INN news server  active DzۦP.
Х bbsnnrp process.

w active l, C update active |ͨ backup active
activefile.BAK M activefile.BAK.OLD.
] innbbsd s history, Y active l, N active reset A
]L.

] server gateway , i bbsnnrp Ӯ " article".
ĳ bbsnnrp  cron ӱҰ. n -w. iN newsgroups Ϥ
Xӳ, p tw.bbs.hot.active, tw.bbs.2ndhot.active,....
[tw.bbs.hot.active]
tw.bbs.talk.love 0000000000 0000000001 y
tw.bbs.comp.unix 0000000000 0000000001 y

[tw.bbs.2ndhot.active]
tw.bbs.admin.installbbs 0000000000 0000000001 y
tw.bbs.talk.lady 0000000000 0000000001 y

[crontab]
10,20,30,40,50 * * * * /home/bbs/innd/bbsnnrp your-news-server \
/home/bbs/innd/tw.bbs.hot.active
35 * * * * /home/bbs/innd/bbsnnrp your-news-server /home/bbs/innd/tw.bbs.hot.active

nΦ쪺 group Wv@I, 峹֪NC@I. ę̀t load
pվ. CC group ̦h 100 g article.
( innbbsconf.h: # define MAX_ARTS 100)
--------------------
b. pGSѻPHiiH innbbsd.....
--------------------
innbbsd OΨӱ Internet Net News .
pGAF tw.bbs.* Qװ, NO[JU٪ TW.BBS su.
pGA] bntplink, NOVH.
w﮳ innbbsd , LĵiU쪺O, innbbsd b
նq. ϥ bbsnnrp ɤ]̦n§ʦa| news server ޲z.
--------------------
[c]. innbbsdnnק inetd.conf Mservices!!
innbbsd O standalone server, ҥHΧ inetd.conf M services.
unw port number Τw default=7777.
Ҧp:
1. ]b port 5555

 innbbsd 5555
 
   telnet localhost 5555 .
  
2.  default 7777
  
   innbbsd
   
   䥦Ϊk:
   
3. w unix domain socket path
innbbsd 5555 /home/bbs/innd/.innbbsd.5555

 local bbsnnrp 
   
bbsnnrp -p /home/bbs/innd/.innbbsd.5555 server-host active-file
      
remote bbsnnrp 
bbsnnrp -r bbs-server-hostname -p 5555 news-server-hostname active-file
         
            
innbbsd su
1. local socket
   Y socket file b /home/bbs/innd,   mode אּ 700.
2. remote access
    hostname [ nodelist.bbs
   
t~Yn inetd Ұ, Цb inetd.conf [J:
innbbsd stream  tcp wait  bbs  /home/bbs/innbbsd innbbsd -i
                    ^^^^^
æb service wq innbbsd. ЯSO`N, O "wait" ӫD "nowait".

standalone  inetd.conf u@. [b inetd.conf kثe
|íw, yϥ. íw|˨ϥ.
--------------------
[d]. bbsnnrp bbs-server hostname test-news.active
     GX{HUT:
     NNRP server not ok
   
bbsnnrp O@ client gateway, ϥήɤ@wnw@ "news server"
( news  server). ҥHA@ news server, ]O
ccnews.nctu.edu.tw (TwAsW), A:

       bbsnnrp ccnews.nctu.edu.tw test-news.active
       
HWO bbsnnrp b bbs server WɪΪk. Y bbsnnrp b䥦 host
, Ҧp ccsun1.cc.nctu.edu.tw, bbs server O bbs.dorm10.nctu.edu.tw,
hN ccsun1.cc.nctu.edu.tw [ nodelist.bbs, ] innbbsd,
b ccsun1.cc.nctu.edu.tw ]
    bbsnnrp -r bbs.dorm10.nctu.edu.tw -p 7777 ccnews.nctu.edu.tw test-news.active   
--------------------
[e]. pG] bbsnnrp , D BBS shutdown , o active file 
     ||?
     
bbsnnrp Ұʮɷ|ճsW server
1. news server   (default to port nntp)
2. innbbs server (default to unix domain socket ~bbs/innd/.innbbsd or
                  -r host -p port)
G̳su\ bbsnnrp ~|ʧ@. pð, ոճs䥦D BBS server
(S] innbbsd)  News server, Ҧp
bbsnnrp -r ftp.edu.tw -p 7777 ccnews.edu.tw bbs1.newsa.active
 active file ||.
--------------------
[f]. ٦NO] innbbsd tΦpGQn shutdown, Ӫ`NǤ?
     pGOp߷,  innbbsd O_vT?
     
pGnbgJ history Τ峹ɷi঳ǼvT. Y]
~bbs/innd/history  P history.pag, history.dir @P, Х
mkhistory ~bbs/innd/history  history ( innbbsd).
U@ history F,  history.o (Ϧ^Xѫe). ثe innbbsd
 shutdown SOBz, оiߺD
  ctlinnbbsd shutdown
     
  kill `cat /usr/tmp/innbbsd-xxxx.pid`
n kill -9 ......
o innbbsd |వ@ǵ.
  
history, history.dir M history.pag Tɤs, ФŪ
editor ק.  history ƫeХ innbbsd.
--------------------
[g]. ثe dbz maintain 覡?

b innbbsconf.h wq
EXPIREDAYS, HIS_MAINT_HOUR M HIS_MAINT_MIN.

C EXPIREDAYS x 2 , b HIS_MAINT_HOUR , HIS_MAINT_MIN ,
innbbsd |N > EXPIREDAYS x 1.5 Ѫ entries .
        
dbz õLл\ remove  entries \, uq source (history)
XOd entries A rebuild dbz. j|y@ peak load.
wN EXPIREDAYS, HIS_MAINT_xx  innbbs.conf. 
----------------------------
[h]. pb Palm BBS ϥ innbbsd
ڭ PalmBBS  innd-palm.tgz ݹLP Phoenix BBS  bbsinnd Ӥ@f,
o{b post M cancel WõLP. ثeϥ PalmBBS ̤}@ӪOݬ.
n諸apU:
1. innbbsd-0.xx/innd/bbspost.c  PalmBBS innd-palm.tgz  bbspost.c
2. innbbsd-0.xx/innd/bntplink  sub save_article אּ
########
sub save_article
{
    local       ($target) = @_;
    $now = time;
        
    open( FN, $target );
    print FN "oHH: $poster, H: $board\n";
    print FN "  D: $subject\n";
    print FN "oH: $mysite ($date)\n";
    print FN "H: $path\n";
    print FN "\n";
    print FN @BODY;
    close( FN );
    utime $mtime, $mtime, $target;
    utime $now, $now, "$bbshome/.bcache/$board"
}
###################
            
iO PalmBBS ]Ū M.xxxx.A ɦW. M BBS_SRC n], bbs.h
M record.c n PalmBBS . ڨSL. ̴⵲GiD, 
ƻntXק諸.
----------------------------
[i]. bbsnnrp H

1. Tw BBS board w}.
2. newsfeeds.bbs, bbsname.bbs M nodelist.bbs , innbbsd ].
3. innbbsd  uid M bbs user ۦP.
4. YĤ@Ұ, X{HU message, B峹,
GROUP groupname
211 1453 11644 13105 groupname
    ^^^^ ^^^^^ ^^^^^
    total low  high
        
ե[W -s Ѽ:   bbsnnrp -s total news-server active-file
        
Y٦, ե bbsnnrp -s very-large-number news-server active-file
5. ˬd active-file format O_T
groupname high-no low-no y
6. compile  BBSHOME O_T.
-----------------------------
[j]. bntplink eXh 

none (kuq.bbs@csie.nctu.edu.tw) :
:  аݭnqBBS HXhbntplink Ӫ`N!1ڸչL@....Luݨ
:   try to send article  iOڥh HݦnSLhC....oO
:   D!!

1. T{ҥΪ bntplink O innbbsd Ҫ.
2. Tw nodelist.bbs  news server M protocol ]wT, 
   (protocol: POST(119) for client gateway)
   newsfeeds.bbs server M nodelist.bbs w۲.
   TwA host  post A]w news server v.
3. ˬd ~bbs/out.going 
4. H BBS @wW, iOAe news server ]
   䥦]ȮɵLk.
-----------------------------
[k]. W[@ӰQװϥ[JHBJ,
     pGQn«H, iH bbsnnrp -c
     iOoˤON|즳HϤ峹 lost ()F?

A1: 
NQװϳWb@ activefile, Ҧp
[act1]
tw.bbs.test 0000000000 0000000001 y

bbsnnrp -c news-server act1

A append act1 쥭`Ϊ activefile.
Ҧp cat act1 >> activefile
(T{Lϥ activefile  bbsnnrp process)

t@ؤkpU:
telnet news-server 119
group tw.bbs.test

211 27 7162 7594 tw.bbs.test
       ^^^^ ^^^^
       low  high
              
N low, high  activefile
tw.bbs.test 0000007594 0000007162
            ^^^^^^^^^^ ^^^^^^^^^
            high        low
            dQ digit
                                                  
A2:
t@ӧֳt reset active kpU:
% telnet news-server 119 > tmp-active
list
quit
% grep ^tw.bbs tmp-active
Υ editor u즳줧 newsgroups.

-----------------------------
[l] pGQn news server ӫ@ ?
ĳpU:
1. N news.active reset  0000000000 0000000001
   s server, ] bbsnnrp -c new-server news.active
2.  tin ss server, AҦ峹Ms server t,
   bʪ峹e[ tag (t), A pipe  bbsnnrp -t stdin
   q` article ɶ, үʪ峹Os.
   pGs server 峹, BJ 2 iٲ.
3. H] bbsnnrp 覡,  server Yi.

  pG 2 B·, pQװϪ峹q, Y news.active QװϤ@
   10 ʫH, N bbsnnrp -c ]L news.active  high-no h
  50 A]` bbsnnrp Yi.
  (Υ tin pʤ֪峹, A news.active  high-no h۷
   ƥ)
  Ҧp bbsnnrp -c ᪺ news.active
tw.bbs.xxx 3246 1234

 tin P BBS board , Y 30 , hN news.active אּ
tw.bbs.xxx 3200 1234
	   ^^^^^
           P 3246 ۮt@ӻP 30 thjƦr.

-----------------------------
[m] [p«H] bbsnnrp ]Φb in.bntpd

ܤ[HeLp batch file ӭeH. BJcƤ.
{b˨ϥ innbbsd  bbsnnrp. SOO in.bntpd ϥΪ.
(Phoenix BBS mfchen's bbsinnd)
innbbsd ϥΪ̷M]A.

0. ާAOάƻ BBS, in.bntpd p. 
   bbsnnrp O BBS implementation independent.
   (unH NNTP, CNEWS nntpd, INN1.4 innd, pbbsnnrpd,... ӳiH)
1.  ftp.csie.nctu.edu.tw:/pub/bbs/misc/innbbsd/innbbsd-0.43.tar.gz
2. unyX bbsnnrp Yi. 䥦i.
    Makefile  BBS_SRC M BBSHOME
   (oӨShjNq, uOFF bbsnnrp M make, @wnT, |Ψ)
   make depend   (ignore any error)
   make sys-type (ܧA sys-type,  make YCXҦ sys-type) 
   L{~κ, ̭nOyX "bbsnnrp".
3. MwNe newsgroups, Ҧp tw.bbs.comp.mac,.... 
y activefile, Ҧp,
tw.bbs.comp.mac 0000000000 0000000001 y
.....

4. b news server (Υ in.bntpd ౵ feed  host) 
bbsnnrp -r your-bbs-host -p bbsinnd-port news-server activefile

For example, news.cis.nctu.edu.tw Qe tw.bbs.talk.feeling,
tw.bbs.talk.ladytalk  bbs.cis.nctu.edu.tw (in.bntpd in port 7777),

#edit news-cis-active
tw.bbs.talk.ladytalk 0000000000 0000000001 y
tw.bbs.talk.feeling  0000000000 0000000001 y

 news.cis.nctu.edu.tw 
bbsnnrp -r bbs.cis.nctu.edu.tw -p 7777 news.cis.nctu.edu.tw news-cis-active

`NO bbsnnrp C̦hue 100 ,  "-a max-art" i override 
default, Φh]XYi.  bbsnnrp -h iݩҦѼ. 
b`pU -r  -p NF.

bbsnnrp |h@ ~bbs/innd U config . гy@ǰHFL bbsnnrp.

{bt@ӰDӤF, ڤQ, uQೡ峹. bbsnnrp iH ?
 "tin" , iJQ઺Qװ, bҦP쪺峹e[ tag ( t),
J "|", "T", "bbsnnrp -t stdin -r bbs.cis.nctu.edu.tw -p 7777"
(oɫNΫw news server M activefile)

(̦n mfchen post  קK bbsinnd ЦHק patch [W,
 []iH. [FNi] bbsnnrp LFɭPƪ峹Ӧh) 
------------------- from mfchen@csie.nctu.edu.tw  --------------------------
FĲv bbsinnd HɨèSˬdӫHO_, bípU,
iಣͭЦHD, ѨMkpU:

ק inntobbs (line 73), Cʤ峹ˬdӤ峹O_wgsb:

sub receive_article
{
    if( &find_history( $msgid ) ) {
	&bbslog( ":Err: duplicate article $msgid\n" );
        return;
    }
	 ...
 }
 -----------------------------------------------------------------------------
 ---
======================================================================
[n]. bbsnnrp  bntplink feed ɲ broken pipe εLk feed
ˬd boards permission mode  bbslog . i innbbsd Lk write.
