Article delegate-en/4039 of [1-5169] on the server localhost:119
  upper oldest olders older1 this newer1 newers latest
search
[Top/Up] [oldest] - [Older+chunk] - [Newer+chunk] - [newest + Check]
[Reference:<_A4038@delegate-en.ML_>]
Newsgroups: mail-lists.delegate-en

[DeleGate-En] Re: NNTP-Delegate will not cache in Linux
03 Aug 2008 21:26:55 GMT feedback@delegate.org (Yutaka Sato)
The DeleGate Project


Hi,

In message <_A4038@delegate-en.ML_> on 08/04/08(04:28:56)
you Jeff <pyqhqbdyi-jfjnzgnpvonr.ml@ml.delegate.org> wrote:
 |Can you confirm that when you made the change it did indeed cache properly?
 |I'm still getting the situation where my CACHEDIR is only 32.0KB after
 |having downloaded > 10MB through the NNTP-Delegate proxy. It just does not
 |seem to write anything at all.
 |
 |Is there anything else I can try? I'm quite reliant on the caching function
 |to work :-)

If you see "islocal = 1" after "newServer = nntp://server" in your
LOGFILE, it is the reason why the cache is disabled.
DeleGate suppresses caching of articles from a local newsserver
(a server running on the same host on which DeleGate is running),
or if you specify a filter with the server like FSV.
The enclosed patch introduces "nonlocal" option to be used as
follows to enable caching even with local server.

  MOUNT="= nntp://server nonlocal"

If it is not the case, testing with the simplest configuration
like follows will give us hints.  (Running DeleGate under super-user
is never recommended in any case.)

  % delegated \
  -P9999 \
  SERVER=nntp \
  MOUNT="= nntp://news.delegate.org/" \
  DGROOT=/tmp/nndg \
  CACHE=do \
  -vd 

  % telnet localhost 9999
  GROUP mail-lists.delegate-en
  ARTICLE 1
  QUIT

Cheers,
Yutaka
--
  9 9   Yutaka Sato <y.sato@delegate.org> http://delegate.org/y.sato/
 ( ~ )  National Institute of Advanced Industrial Science and Technology
_<   >_ 1-1-4 Umezono, Tsukuba, Ibaraki, 305-8568 Japan
Do the more with the less -- B. Fuller


*** delegate9.8.4-pre4/src/nntp.c	2007-11-05 17:11:16.000000000 +0900
--- src/nntp.c	2008-08-04 05:58:43.000000000 +0900
***************
*** 5499,5504 ****
--- 5499,5510 ----
  	if( strstr(opt1,"ro") == opt1 && (opt1[2]==0 || opt1[2]=='=') ){
  		nm->nm_flags |= MF_RO;
  	}else
+ 	if( strstr(opt1,"nonlocal") ){
+ 		if( ns->ns_islocal ){
+ 			sv1log("## nonlocal: %s\n",ns->ns_host);
+ 			ns->ns_islocal = 0;
+ 		}
+ 	}else
  	if( strstr(opt1,"rewaddr=") ){
  		nm->nm_rewaddr = stralloc(opt1+8);
  		ns->ns_rewaddr = nm->nm_rewaddr;

  admin search upper oldest olders older1 this newer1 newers latest
[Top/Up] [oldest] - [Older+chunk] - [Newer+chunk] - [newest + Check]
@_@V