Linux

Run X programs through ssh

A easy way to run remote X programs (from another host) on your local linux installation is to connect to it via ssh using the -Y switch. For instance if you would like to run up2date in graphical mode on a remote machine but the server doesn’t have X installed. Then this is a great […]

Read More
Linux

Rotate logs manually

Today I had to manually rotate a couple of logs since they had generated a filesize of over 1.8GB of pure text. This was done by issuing the command logrotate /etc/logrotate.d/file_to_be_rotated In my case I had to rotate my firewall log /var/log/firewall described in a custom made file, /etc/logrotate.d/firewall logrotate -v -f /etc/logrotate.d/firewall -v Verbose […]

Read More
Scripting

Set photo filedate and time according to EXIF info

Sometimes a image files creation date is wrong and have to be corrected. This is a script I use to set a files creation date to the photos date retrieved from EXIF tags. The exiftool program should be available to run this script. #!/usr/bin/env perl use strict; $|++; use Image::ExifTool qw(ImageInfo); use Time::Local; for my […]

Read More