cockpit-session-recording
cockpit-session-recording copied to clipboard
Storage / resource usage of cockpit-session-recording
Hi, I'd like to know, how much storage and system resources a session recording approximately uses, as I am trying to decide if I should have recordings for everything or exclude certain sessions.
Hi,
There is no way to calculate the resource usage as there are too many other factors involved, but I suspect disk space is the most limiting factor.
I would recommend enabling recording only for a group of users and monitoring the system before enabling recording for everyone.
You can also enable I/O rate limiting to somewhat control how fast the space is consumed.
Is there any way I could check how much disk space is used, so I could see for myself what config I'd go with?
Unless you set the rate limit, ultimately it could be anything at all, only limited by your CPU speed and memory/storage bandwidth.
IIRC, the rate limit is specified in encoded (JSON) bytes, so the "rate" setting would give you an upper limit (default is 16KB/s). You can also set the burst limit to e.g. allow a quick display of a long program output.
If you want to know the average encoding overhead, start something like tlog-rec -o test.log dd if=/dev/urandom bs=1024 count=1024 > /dev/null. This would encode 1MB of random data into the test.log file.
Also, try taking @justin-stephenson's advice and just record a few sessions to get a feel of what sizes you get.
Actually, encoding random binary data wouldn't be representative of a typical shell session in overhead, but rather closer to the worst case, so please disregard that. Take a big text file, or a log, and print it under tlog to see something close to reality.