Articles in Files
Finding Duplicate Photos
Being a shutterbug and a digital hoarder can get expensive. A couple of days ago, my
TerraMaster D5-300 5-bay DAS crashed. Again. This time it was the power supply. I replaced it only to discover that …
Focus Stacking with Lightroom and Photoshop
Not the usual topic for this blog and not the most comprehensive guide on the subject out there, but here I go anyway. Focus stacking combines multiple photos taken at different focal distances into an …
Generating Honeypot Data Structure
I’ve been fiddling with my inotifywatch scripts to make a better “early-warning” system for ransomware detection and realized I needed a more realistic honeypot data structure. Ransomware is getting more clever and is no longer …
Joining Text Files and Data Columns
When working with application logs and other text files, it is often useful to view the contents of different source files side-by-side. Here we will take a quick look at various command-line methods for joining …
Generating Random Text Files for Testing
Sometimes you need dummy folder structures populated with random data for testing your various scripts and processes – backups, file transfers, encryption, compression, etc. Every time I need something like this, I end up writing …
Renaming Files with exiftool
Recently I exported a whole bunch of files from Lightroom to a NAS share and filenames like 2E570434-67B7E0489CA2-39354-000017CF24DD8ACD.jpg are not very informative. It would’ve been nice if the filename contained some useful information like date, …
Appending Filenames
If you google how to append, say, current timestamp to the filename in Bash, almost every suggestion boils down to something really basic along the lines of mv $somefile $somefile_$(date +’Y%-%m-%d’). Technically, this is correct …
Copying File Attributes Across Servers
To make long story short, had to fix someone’s chmod -R 777 /. A late-night copy-paste fail, it would seem. Needless to say, console access is required, as SSH will not work with permissions on …
Copying Data in a Restricted Environment
Consider this not-so-hypothetical scenario: you have some data on server_a that you would like to copy to server_b. Unfortunately, these two servers cannot communicate with each other. Nor do they have access to any common …
Squeezing Video Files
All that crap I’ve been saving from YouTube, Facebook and whatnot tends to add up. As quality is not a huge concern here (not that it was very high to begin with), optimizing those video …
File Compression Testing
For some reason I haven’t used zip much on Linux, sticking to the standard tar/gzip combo. But zip seems to be a viable alternative. While not as space-efficient, it is definitely faster; syntax is simple; …
Find Large Folders
When you get a filesystem space alert (and they tend to arrive at 3:37 on Saturday morning), deleting various supersized log files is one option I already covered in adequate detail. That is if you get so lucky as to find such a file to delete…
Document Conversion with Unoconv
The other day I ran into the “Flexible Import/Export” article by Bruce Byfield in the March 2018 issue of Linux Pro Magazine and thought it could use some more detail. So here’s some more detail.
Find Large Files
Every time a filesystem is running out of space and I need to find something to delete, I end up googling the syntax for the find command to make sure it stays off NFS and …
Agedu – Finding Old Files
I almost never delete anything (not on purpose anyway). Having said that, sometimes I do need to find old data on a server and offload it to a NAS. Agedu has been around for ages. …
Deleting Lots of Files Quickly
I am not talking about hundreds or thousands of files. I am talking about hundreds of thousands. The usual “/bin/rm -rf *” may work, but will take a while. Or it may fail with the …
Numeric File Permissions in Unix
Suppose you are working with a Web server and your task is to make sure that no files or directories have permissions “777”. It would be easy to just recursively change permissions for all files …
Dealing With Disk Hogs
Some users and application developers believe that any free disk space on the server belongs to them. Suddenly you get an email alert saying that a server “xyz” ran out of disk space in /home. …
To display file’s modification, last access, etc
Display a file’s modification, last access and other attributes on Solaris.

Latest Comments