]> Cypherpunks.ru repositories - nncp.git/blob - doc/bundles.texi
Unify @ref and @command usage
[nncp.git] / doc / bundles.texi
1 @node Bundles
2 @cindex bundles
3 @cindex tapes
4 @cindex streaming media
5 @unnumbered Bundles
6
7 Usual @command{@ref{nncp-xfer}} command requires filesystem it can
8 operate on. That presumes random access media storage usage, like hard
9 drives, USB flash drives and similar. But media like CD-ROM and
10 especially tape drives are sequential by nature. You can prepare
11 intermediate directory for recording to CD-ROM disc/tape, but that
12 requires additional storage and is inconvenient.
13
14 Bundles, created with @command{@ref{nncp-bundle}} command are convenient
15 alternative to ordinary @command{@ref{nncp-xfer}}. Bundle is just a
16 collection of @ref{Encrypted, encrypted packets}, stream of packets. It
17 could be sequentially streamed for recording and digested back.
18
19 @itemize
20
21 @item They do not require intermediate storage before recording on
22 either CD-ROM or tape drive.
23 @example
24 $ nncp-bundle -tx SOMENODE | cdrecord -tao -         # record directly to CD
25 $ nncp-bundle -tx SOMENODE | dd of=/dev/sa0 bs=10240 # record directly to tape
26
27 $ dd if=/dev/cd0 bs=2048 | nncp-bundle -rx  # read directly from CD
28 $ dd if=/dev/sa0 bs=10240 | nncp-bundle -rx # read directly from tape
29 @end example
30
31 @item They do not require filesystem existence to deal with, simplifying
32 administration when operating in heterogeneous systems with varying
33 filesystems. No @command{mount}/@command{umount}, @command{zpool
34 import}/@command{zpool export} and struggling with file permissions.
35 @example
36 $ nncp-bundle -tx SOMENODE | dd of=/dev/da0 bs=1M # record directly to
37                                                   # hard/flash drive
38 $ dd if=/dev/da0 bs=1M | nncp-bundle -rx # read directly from drive
39 @end example
40
41 @item This is the fastest way to record outbound packets for offline
42 transmission -- sequential write is always faster, when no
43 metainformation needs to be updated.
44
45 @item This is convenient to use with append-only storages, just
46 sending/appending new bundles.
47
48 @item Bundles could be repeatedly broadcasted in one-way transmission.
49 @ref{Sync, Sync protocol} requires interactive connection, but bundles
50 can contain mix of various recipients.
51
52 @end itemize
53
54 @pindex pax
55 @pindex tar
56 Technically bundle is valid POSIX.1-2001
57 @url{https://pubs.opengroup.org/onlinepubs/9699919799/utilities/pax.html#tag_20_92_13_01, pax archive}
58 with directory/files hierarchy identical to that is used in
59 @command{@ref{nncp-xfer}}: @file{NNCP/RECIPIENT/SENDER/PACKET}.
60 So bundle can also be created by manual tar-ing of
61 @command{@ref{nncp-xfer}} resulting directory.