INNXBATCH(8)
π innxbatch, sendxbatches β Send xbatched Usenet articles to a remote NNTP server
Okay bestie, so this page is from INNXBATCH(8) in the InterNetNews Documentation section of the manual, and it's literally all about yeeting xbatched Usenet articles over to a remote NNTP server. Slay. Let's get into it β¨
π SYNOPSIS π
innxbatch [-Dv] [-t timeout] [-T timeout] host file [file ...]
innxbatch -i [-Dv] [-t timeout] [-T timeout] host
sendxbatches sitename host file [file ...]
π DESCRIPTION π
So innxbatch connects to port 119 of the NNTP server running at the host you specify, and then sends it the xbatch files you gave it, using the XBATCH extension to the NNTP protocol. Where do those files come from? Either straight off the command line, or from standard input if i is used. Easy.
Each file is removed after it has been successfully transferred. Bye boo π
If a communication error happens β like a write(2) failure, or the remote server replies with something unexpected β innxbatch will stop sending and leave all the remaining files untouched so you can retry them later. No data loss, we love that for us π«Ά
If authentication credentials are present for the remote server in the passwd.nntp file in pathetc, then innxbatch will use them to authenticate. iykyk π
Real talk: innxbatch does not use itself any file locking. At worst, a batch could be transmitted twice in parallel by two independent invocations of innxbatch. π To prevent this, it should be invoked by a script run out of cron(8) that uses shlock(8) to lock the host name, followed by a "ctlinnd flush" command to flush the batch file. And guess what β sendxbatches is such a wrapper around innxbatch. It will ensure only one instance is run, flush sitename (as used in the newsfeeds entry) and send to host the files given as arguments. Iconic behaviour, honestly π
Heads up bestie: the XBATCH extension is not a standardized NNTP command, so some news servers just don't recognize it. π And to accept batches from remote peers via XBATCH, you have to explicitly enable the capability with thexbatchsetting inincoming.conf. Instead of usinginnxbatch, you may considerinnfeed, or if that's not possible,nntpsend.
β¨ OPTIONS β¨
-Dβ Prints debugging information on standard error. This will show the protocol transactions betweeninnxbatchand the NNTP server on the remote host. Spy mode activated π-iβ Reads batch file names from standard input. For each successfully transmitted batch, an"OK"is printed on stdout to indicate that another file name is expected. Feed me more, it says π-t timeoutβ Specifies a timeout in seconds on how long to try to make the connection. Otherwise,innxbatchnormally blocks until the connection is made. Long wait energy π-T timeoutβ Specifies the total amount of time in seconds that should be allowed for article transfers.
The default is to wait until an I/O error occurs, or all the articles have been transferred. If this flag is used, the time is checked just before each article is started; it will not abort a transfer that is in progress. So no, it won't snatch the rug mid-flight π
-vβ Upon exit,innxbatchreports transfer and CPU usage statistics viasyslog(3). If this flag is used, they will also be printed on the standard output. Receipts! π§Ύ
π¦ EXAMPLES π¦
A sample newsfeeds entry to produce appropriate xbatch files is:
nase\
:*\
:Tc,Wnb\
:<pathbin>/batcher -p "(<$COMPRESS in <pathlib>/innshellvars>\
> <pathoutgoing>/nase.\$\$)" nase.do.main
A sample script to invoke innxbatch(8) is:
#! /bin/sh
# Send xbatches for a site, wrapped around innxbatch.
if [ $# -lt 3 ]
then
echo "usage: $0 <sitename> <hostname> <xbatch file name> ..."
exit 1
fi
. <pathlib>/innshellvars
site="$1"; host="$2"; shift; shift
ctlinnd flush "$site" \
&& sleep 5 \
&& exec ${NEWSBIN}/innxbatch -v -D "$host" $*
You can use sendxbatches, already shipped with INN, doing locking. An example of call is:
sendxbatches nase remote.news.server.name <pathoutgoing>/nase*
πΈ HISTORY πΈ
Written by Stefan Petri <petri@ibr.cs.tu-bs.de>, modelled after innxmit and the XBATCH patch for the NNTP reference implementation. Examples from Karsten Leipold <poldi@dfn.de>. Rewritten into POD by Julien Elie. Shoutout to the OGs π«‘
π SEE ALSO π
ctlinnd(8), incoming.conf(5), innxmit(8), newsfeeds(5), nntpsend(8), passwd.nntp(5), shlock(8).
βΏ and that's the whole page, bestie βΏ This edition is from INN 2.7.4, dated 2025-05-09 β catch you in the next manpage, mwah ππ
π
π¦ where this page comes from
- arch rolling: inn 2.7.4-4 Β· ISC
- epel 10: inn 2.7.4-5.el10_3 Β· ISC AND BSD-3-Clause AND BSD-4-Clause AND FSFAP AND (GPL-1.0-or-later OR Artistic-1.0-Perl) AND GPL-3.0-or-later WITH Bison-exception-2.2 AND LicenseRef-Fedora-Public-Domain AND MIT AND NTP
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms