Next Previous Contents

4. The news server

4.1 Installing the news server

You need to install a news server. I used inn but others are available (somewhere).

Preferably just check the "News Server" box during your initial install, but alternatively if your distribution uses RPM (RedHat package manager), then use something like...

rpm -i inn-2.2.9.i386.rpm

4.2 Running the newsserver

To manually start or stop the news server, use a command like

/etc/rc.d/init.d/innd start
or
/etc/rc.d/init.d/innd stop
or
/etc/rc.d/init.d/innd restart

To have the news server start at boot you could add a command like this to end of /etc/rc.d/rc.local, but that is not the best. Many distributions have a graphical tool for choosing which daemons run. You can also try the command line program

setup
or
chkconfig --add innd

4.3 Creating the newsgroup

innd is pretty picky about permissions and ownership. For much of the news config you will need to be the user news. To become this user from root...

        su - news

Using ctlinnd, create the newsgroup on your news server. Remember, the newsgroup will be local, so start it with a distinctive name so you can filter it out from your news distributions if you do that stuff. I shamelessly named my newsgroup ietf.confctrl. The words from left to right go from less to more specific.

You also need to tell innd that the group is moderated (by using ctlinnd). Indicating a moderated group is done by specifying m to the newgroup command. For example...

        ctlinnd newgroup ietf.confctrl m confctrl@isi.edu

The newsgroup is set up as a moderated group, as this allows us to take advantage of the email capabilities of innd. Any messages posted to a moderated group are not immediately submitted to the group. Instead, messages are emailed to the moderator of the group. In our example confctrl@isi.edu is the address which is resent by the remailer.

If you are sharing news with other servers, remember to edit your newsfeeds so that this group is not not distributed (unless you specificaly wish this to occur).

4.4 Unrestricting access

By default the news server, doesn't let any clients read news, so I needed to disable the user authentication of innd. This was done in the /etc/news/nnrp.access. Check out the nnrp.access man page to learn the syntax of this file. I changed the first non-comment line to ...

*:Read Post:::*

If you want a username/password, fill in the 3rd and 4th (colin separated) fields. For more information on the syntax, check the man page...

man nnrp.access

4.5 Changing permissions of /usr/bin/rnews

I had to change the permissions of /usr/bin/rnews. It was not world read/executable, but sendmail runs scripts as nobody.

chmod a+rx /usr/bin/rnews

4.6 Testing article posting

If you copy the following article to a file named rick.article...


Path: rick
From: rick@fdd.com
Message-ID: <199907120548.AAA05475@fdd.com>
Subject: test
Date: Mon, 12 Jul 1999 00:48:49 -0500 (CDT)
Newsgroups: ietf.confctrl
Approved: ietf-confctrl@kepler.hedland.edu.au
NNTP-Posting-Host: localhost
Organisation: (mail2news gateway)


test

Then you should be able to post a file with...

/usr/bin/rnews -r localhost <rick.article

4.7 Did it work?

You don't need to wait for the article to show up as unread, just look at the /var/spool/news/articles/ subdirectories for files being created.

4.8 Increasing expiration times

You may want to increase the expiration time for articles of your new newsgroup. In my case I wanted them never to expire, so I added the following line....

ietf*:A:never:never:never
....to the /etc/news/expire.ctl file.

To learn more about the syntax of this file type...

man expire.ctl


Next Previous Contents