[news.sysadmin] Help with expire - old files still around

robbin@resrch.MoliEnergy.BC.CA (Robbin W. Johnson) (07/27/88)

I *appear* to be having problems with expire leaving old (some very old)
files in the news spool file system and so I seek some help.

Because of tight disk space, I expire news daily (in the wee hours) with
the options "-e 7 -E 21".  For the most part, this removes old articles
and keeps everyone involved happy.  In perusing through the file system
I recently discovered *a lot* of older file that should have been long
ago removed.  One that caught my eye was dated Jan. 22 and received here
on Jan. 26!  There is no Expires: line in amongst the headers.  This is
by no means the only culprit.  Nearly every sub-directory has articles
that are over 1 week old (my explicit expire age), many of which are the
several months old.

Thinking that this was a problem with munged history files, I decided to
run "expire -r".  This made no difference and these old files are still
out there :-(.

I am running 2.11 B news at patch level 14 on an HP9000/500 running
HP-UX version 5.21.  I have not hacked at the sources in any way.

Any help or pointers as to how to attack this problem would be
appreciated.  If you respond by mail I will summarize once the verdict
is in.

Thanks.
-- 
Robbin Johnson					...!ubc-cs!van-bc!resrch!robbin
robbin@MoliEnergy.BC.CA				...!uunet!/
			>> core error : bus dumped <<

det@hawkmoon.MN.ORG (Derek E. Terveer) (08/01/88)

I have had much the same problems on my machines -- also running 2.11.14, and
in rereading the documentation for news (which is something that is good to do
periodically for anything (:-)) i realized that expire should be suid news.  I
knew this, but i assumed that the install script would suid it for me after
reinstallation.  No, it appears not to.  So i went and manually suid to news
all the expires and it seems to be working a lot better!  Check your
permissions on expire and see if changing it helps any....

Good luck -- a cranky expire can *really* ruin one's week !!!

derek
-- 
Derek Terveer		det@hawkmoon.MN.ORG
			w(612)681-6986
			h(612)688-0667

jbuck@epimass.EPI.COM (Joe Buck) (08/01/88)

In article <226@hawkmoon.MN.ORG> det@hawkmoon.MN.ORG (Derek E. Terveer) writes:
>I have had much the same problems on my machines -- also running 2.11.14, and
>in rereading the documentation for news (which is something that is good to do
>periodically for anything (:-)) i realized that expire should be suid news.

No!  No!  No!  It most emphatically should NOT be suid news, and by setting
it up that way you allow any user on your system to zap all articles by anyone
he or she doesn't like, or to just lock up the system.  I strongly recommend
putting it back the way it was.

expire should be RUN by user "news".  If you have System V.2 or later, with
separate cron files for each user, put it in the cron file for "news".  Otherwise,
put an "su news" in the cron file before running expire.



-- 
- Joe Buck  {uunet,ucbvax,pyramid,<smart-site>}!epimass.epi.com!jbuck
jbuck@epimass.epi.com	Old Arpa mailers: jbuck%epimass.epi.com@uunet.uu.net
	If you leave your fate in the hands of the gods, don't be 
	surprised if they have a few grins at your expense.	- Tom Robbins

vanpelt@unisv.UUCP (Mike Van Pelt) (08/03/88)

In article <566@resrch.MoliEnergy.BC.CA> robbin@resrch.UUCP (Robbin W. Johnson) writes:
>
>I *appear* to be having problems with expire leaving old (some very old)
>files in the news spool file system and so I seek some help.

>In perusing through the file system
>I recently discovered *a lot* of older file that should have been long
>ago removed.

>I am running 2.11 B news at patch level 14 on an HP9000/500 running
>HP-UX version 5.21.  I have not hacked at the sources in any way.

I ran into exactly this same problem on a Unisys 7000/40 running
System V.  There is a tag you need to #define in your localize.sh
file when you build news -- HP9K5.  All this seems to do is to tell
News that, even though you're a SYSV site, your file systems are
still Berkeley.  News reads the directories like they're files,
and expects them to look like the kind of file system it expects.

I had worse problems than expire not deleteing the spool/news files -- It
marked most of the messages as non-existant in the newslib/active file! 
Turning on HP9K5 fixed the problems up for me.
-- 
Mike Van Pelt                     Help stamp out Mickey-Mouse 
Unisys Silicon Valley                computer interfaces --
vanpelt@unisv.UUCP                Menus are for Restaurants!

robbin@resrch.MoliEnergy.BC.CA (Robbin W. Johnson) (08/05/88)

In article <543@unisv.UUCP> vanpelt@unisv.UUCP (Mike Van Pelt) writes:
>In article <566@resrch.MoliEnergy.BC.CA> robbin@resrch.UUCP (Robbin W. Johnson) writes:
>>
>>I *appear* to be having problems with expire leaving old (some very old)
>>files in the news spool file system and so I seek some help.
>
>I ran into exactly this same problem on a Unisys 7000/40 running
>System V.  There is a tag you need to #define in your localize.sh
>file when you build news -- HP9K5.  All this seems to do is to tell
>News that, even though you're a SYSV site, your file systems are
>still Berkeley.  News reads the directories like they're files,
>and expects them to look like the kind of file system it expects.
>

I have HP9K5 #defined.  That was not the problem. [BTW- the file system
on the 500 is not Berkeley or SYSV ... it is an HP original that has
caused me more than a few headaches with software off of the net.  Now
that HP has (or is about to) drop the 500 series off the price list
there will *never* be a real native UN*X kernel.  HP-UX on the 500 runs
on top of a little beastie call SUN (No! Not *that* Sun!). Heavy sigh!]

Anyway, back to my problem!

IT SEEMS TO HAVE CURED ITSELF!  I must have read the manual wrong.  I
thought that running 'expire -r' would not only rebuild the history files
but also expire any and all old articles.  Apparently it did not do the
expire!  The next morning I came in and 'df' told me I had 10MB more
disk free than when I left the night before.  I quickly checked the
/usr/spool/news heirarchy and lo' and behold all those nasty files had
disappeared!  I will not ask why, I am just happy that it did.

Thanks for the attention.  It is always nice to know that someone out
there is listening.
-- 
Robbin Johnson					...!ubc-cs!van-bc!resrch!robbin
robbin@MoliEnergy.BC.CA				...!uunet!/
			>> core error : bus dumped <<