Hello All,
I recently experimented with the [outputs.file] output plugin. More specifically, I used the compression options for the first time. In the end, I only achieved success with “gzip.”
I was completely unfamiliar with “zstd”. So I first tried “zlib”. This is known to be the compression method used by ZIP. However, the latter is always applied to individual or multiple files and not to a stream of characters.
So I asked myself how I could decompress my compressed Telegraf output data. With “gzip,” it’s easy:
cat [my_compressed_data_file] | gunzip | tee [uncompressed_data_file]
So I tried zlib-flate (from ‘qpdf’ package) and (un)pigz , but nothing worked. The best result was (I think it was with unpigz) that the first line of the data file was decompressed, but for the rest of the file, the program claimed that the remaining data was corrupt.
So at the moment, I’m using the gzip method and can easily recover the data from the output file later. However, due to the supposedly better compression efficiency, I would also give the other two methods a try. Of course, only if I have the chance to get the data back in plain text later.
It should also be mentioned that I work with Linux.
Thanks in advance and best regards,
conne914
