Documentation for the setting of a UUCP feed with send-uucp

Julien ÉLIE julien at trigofacile.com
Sun Oct 17 06:58:21 UTC 2021


Hi all,

Just sharing the notes I've taken during my recent migration of my news 
server to another hardware.  I have been running a (very little) UUCP 
feed with Jeffrey for years, just for the sake of testing.  It works 
fine, without any problem.

In case it could help other news admins, or if you have any addition, 
this is what the send-uucp documentation now contains:


SETTING UP UUCP FEEDS

     Here are the steps to follow to set up a UUCP feed over SSH between two
     news servers, using the UUCP implementation available in Debian as the
     "uucp" package.  The mechanisms described below should be transposed if
     you use another UUCP implementation.  (And if you do, please inform the
     INN maintainers about how to set up a feed with another UUCP
     implementation, so that it can be added to this documentation.)

     1.  First of all, make sure rnews is correctly installed setuid "news",
         owned by group "uucp", and mode 4550.  This will allow the UUCP
         subsystem to run rnews to process UUCP batches of news articles.
         The "configure" flag --enable-uucp-rnews takes care of it when
         installing INN.  Otherwise, you'll have to manually change the
         permissions on rnews.

     2.  Install the "uucp" package.  It will notably provide uucico(8) and
         uux(1).

     3.  Configure in /etc/uucp/Poll the remote news servers to poll, 
and the
         hours during which they are to be polled.  For instance, if you 
send
         to "news.server.to.feed" UUCP batches every 4 hours, you can use:

             schedule news.server.to.feed 00
             poll news.server.to.feed 00 04 08 12 16 20

         If sending is hourly, just list all the hours.

     4.  Configure in /etc/uucp/call the credentials (usernames and
         passwords) to use when authenticating against remote news servers,
         one per line.  For instance:

             news.server.to.feed login password

     5.  Configure in /etc/uucp/config the UUCP name of the local news
         server.  For instance:

             nodename my.news.server

     6.  Check that /etc/uucp/expire fits your needs as for the number of
         days batches are retained as well as the configuration of daily
         reports.  Default values are normally fine, though you may want to
         receive a daily report only if unusual things happen (and in that
         case, just set $important_only to 1).

     7.  Configure in /etc/uucp/passwd the credentials (usernames and
         passwords separated by a tabulation) remote news servers use when
         authenticating against the local news server, one per line.  For
         instance:

             login<TAB>password

     8.  Configure in /etc/uucp/sys how remote news servers connect to the
         local news server.  A typical entry to set an SSH connection is the
         following one where *pathbin* should be changed to the real path to
         rnews:

             system news.server.to.feed
             call-login *
             call-password *
             commands <pathbin>/rnews
             time any
             chat "" \d\d\r\c ogin: \d\L word: \P
             chat-timeout 120
             protocol i
             port ssh.news.server.to.feed

     9.  Configure in /etc/uucp/port how to connect to remote news servers.
         A typical entry to set an SSH connection using a private key is:

             port ssh.news.server.to.feed
             type pipe
             command /usr/bin/ssh -a -x -q -i <key_file> -l uucp 
news.server.to.feed
             reliable true
             protocol etyig

         where *key_file* is the private key to use for the SSH connection,
         like for instance /var/spool/uucp/.ssh/id_private_key.

     10. Make sure the administrators of remote news servers have added the
         public key related to id_private_key for connections to the "uucp"
         user of the remote news servers.

     11. Supposing the home directory of the "uucp" user is /var/spool/uucp,
         you need to configure the SSH keys in the .ssh subdirectory. 
First,
         add the public keys of all remote news servers in authorized_keys.
         A typical entry is:

 
no-port-forwarding,no-X11-forwarding,no-agent-forwarding,command="/usr/sbin/uucico 
-l",from="news.server.to.feed" ssh-rsa xxxyyyzzz uucp at news.server.to.feed

         This ensures the SSH connection will not be used for another goal
         than exchanging UUCP batches.

     12. Make sure id_private_key is correctly present, as set in
         /etc/uucp/port, and only readable by the "uucp" user.

     13. Manually run as the "uucp" user the command set in 
/etc/uucp/port so
         as to create the known_hosts file so as to make sure the SSH 
setting
         is fine.

            /usr/bin/ssh -a -x -q -i <key_file> -l uucp news.server.to.feed

     14. Parameter the feed to send to the remote servers.  A typical entry
         in newsfeeds to generate batches in *pathoutgoing* is:

             news.server.to.feed/pathname:*:Tf,Wnb,B4096/1024:

     15. Set up the compression method, batch sizes and when to generate 
them
         in send-uucp.cf located in *pathetc*, as described earlier in this
         documentation.

             news.server.to.feed   bzip2      1048576   3,7,11,15,19,23

     16. Check that send-uucp is started hourly in crontab by the "news"
         user.  For instance in /etc/cron.d/inn2:

             52 * * * * news <pathbin>/send-uucp

     17. Check that UUCP programs are automatically started in crontab
         (usually, uudemon.hr is called hourly in /etc/cron.d/uucp to poll
         remote news servers, and uudemon.day daily in 
/etc/cron.daily/uucp).

         It can be useful to set up a different launch time than your remote
         servers.  For instance, it you connect every hour at minute 10, a
         remote peer may do the same at minute 40.  This way, you will
         exchange articles more frequently.

     18. Check the logs in /var/log/uucp to ensure everything works fine,
         both polling and sending.

         You will see that send-uucp prepares rnews batches named like
         D.0I8Y, which are then sent by uucico.  At the same time, uucico
         takes available batches from the remote sites, which are then
         locally injected by uuxqt through rnews.

         That's all!


-- 
Julien ÉLIE

« C'est une forêt vierge où la main de l'homme n'a jamais mis le pied. »


More information about the inn-workers mailing list