About using archive programs

Everything that does not fit anywhere else
Post Reply
User avatar
lgillis
Posts: 137
Joined: Mon May 09, 2022 8:40 am

About using archive programs

Post by lgillis »

The use of archivers (zip, tar …) in file sharing is controversial. Some voices, especially in the BitTorrent community, argue that a torrent file is a sufficient archive because it aggregates all files and these files are visible on tracker sites and in peers' BitTorrent clients. This allows individual files to be excluded from the torrents. In addition, unnecessary data compression is often criticized, or better said, assumed, which goes hand in hand with archive programs. They point to the often high internal compression of modern multimedia formats. Another valid argument is the double use of disk space, since an archive usually has to be unpacked first in order to access its contents. (However, this argument is often invalidated by the state of the delivered files, which are not suitable for the maintained archive in this state.)

Archive programs are particularly suitable when other transport routes are chosen. Common websites and file-sharing programs like MuWire are examples of this. Instead of dozens or even hundreds of loose files, as we know them from audio books, you pack files that belong together into an archive and add a meaningful description. These archives should not use compression if a further reduction of the data volume is not to be expected. The reason for this is administration (typical German, isn't it?) and laziness (typical me). The constantly growing amount of data should not be underestimated. From an indefinite amount it can become very time consuming to find certain data and confusing if there are duplicates. It wouldn't be the first time I've done without data if the cost outweighed the benefit.

That was a brief comparison and I hope that future generations will decide on the use of archive programs on a case-by-case basis.
User avatar
lgillis
Posts: 137
Joined: Mon May 09, 2022 8:40 am

Re: About using archive programs

Post by lgillis »

Another reason to use archives is that BitTorrent clients such as Java-I2PSnark are inherently broken. Such clients have insurmountable problems with colons in file and directory names, for example. Although they will accept the corresponding torrent file, which also has colons in its name, all the files and directories it contains will be renamed: Colons become underscores! So you can't use tools like mktorrent because I2PSnark can't find the files you want to seed. I2PSnark is aware of this and works around the problem by encoding such punctuation when creating torrents, but only then. This is where archivers come in: The archive is given its original spelling. The name of the archive and the torrent file no longer matter, they can be CO.ol.Z.2024.1080p.ROTZE.Rip.1400MB.DD5.1.x264-PalaxyRG[YGx] as you are used to in this area.
User avatar
lgillis
Posts: 137
Joined: Mon May 09, 2022 8:40 am

Re: About using archive programs

Post by lgillis »

Here is an example script for creating anonymized tar archives.

Code: Select all

#!/usr/bin/sh
# Time-stamp: "2024-02-25 13:56:39, tar_anonymized.sh"

### Tar archive anonymized, GNU Tar

case $1 in
    -*|'')
        printf "Creation of anonymous tarballs. No compression. Certain file types are not included.\nUsage: %s [source data]\nWithout tar parameter, default is 'cvf'; archive name is derived from the file name.\nDirectory levels are retained (change to the working directory if required).\n" "${0##*/}"
        exit
        ;;
esac

SOURCE="${1}"
TARBALL="$(echo "${SOURCE}" | sed -e 's@:@ @' -e 's@/$@@').tar"
MTIME='2021-01-21 21:21:21'

LC_ALL=C \
    tar --format=posix --sort=name \
    --numeric-owner --owner=0 --group=0 \
    --no-xattrs --no-selinux --no-acls \
    --pax-option 'delete=atime,delete=ctime' \
    --mtime="${MTIME}" \
    --mode='go+u,go-w,a-t' \
    --exclude-backups \
    --exclude='.*' --exclude='*.org' --exclude='*.xmp' \
    --force-local \
    -cvf "${TARBALL}" "${SOURCE}"
Post Reply