Auto backup last n days on an usb stick

This is a simple script which automatically backups files modified in the last n days on a usb stick. It can be run from cron and will require the usb stick to be present only at backup times: <pre lang="bash">#!/bin/bash USB_DEV=/dev/sdb1 MOUNT_POINT=/media/backupusb DAYS=60 SYNC_DIR=/home/tomcat/backup/ find $SYNC_DIR -mtime +$DAYS | sed "s|$SYNC_DIR||" > $SYNC_DIR/exclude mount $USB_DEV $MOUNT_POINT if [ $? -eq 0 ]; then mkdir -p $MOUNT_POINT/backup rsync -rtDxL --safe-links --delete --exclude-from=$SYNC_DIR/exclude --delete-excluded --modify-window=1 -vP $SYNC_DIR $MOUNT_POINT/backup/ umount $MOUNT_POINT else echo Could not mount $USB_DEV on $MOUNT_POINT fi Some explanation on the rsync params:...

June 23, 2011 · len

Printing a large number of pdf files

All you hear about the next big improvement in Linux distributions seems to be screen oriented: “It will have a new button which will be more Mac like”. I don’t say that having a button to click isn’t nice but don’t forget the power of the command line. Take the following example: “you need to print 50 pdf files in a folder”. You can either open them one by one in evince and print them (1 click to open, one for the print icon print, one to click ok * 50) or you can issue a single command which does this job while you read the next review on linux usability:...

February 9, 2011 · len

E6410 summary

After a few days play with my new Dell Latitude E6410 I was expecting more from the “Ubuntu on the new laptop” combination. Here is a short summary for what to expect if installing Ubuntu 10.10 Maverick Meerkat on a E6410 (check the previous post on the subject). Video card – nVidia Corporation GT218 [NVS 3100M] (rev a2). Works with default version Nvidia driver from Ubuntu but the log is full of errors:...

January 14, 2011 · len

FB4 on linux

Since 01.01.2011 Adobe has stopped support for Flex Builder 3 alpha on Linux. After this date the plugin effectively stopped working even if you had a valid, payed license as it was my case. This was a very sad news since I do a lot of flex development. I don’t need much of the Builder since I use ant for the compilation but at least code completion in .as and ....

January 7, 2011 · len

Ubuntu 10.10 on a Dell Latitude E6410

Did I missed the old times when installing Linux on a laptop was a bit tricky? I seems so since installing the latest Ubuntu (10.10 Maverick Meerkat) on a Dell Latitude E6410 (with Nvidia graphics card) was by no means a breeze. Update 20100115: I summarized/updated all the hardware part in a separate article, check for updates. Installation All started when, full of confidence, I booted the usb stick with the Linux install expecting everything to work as a charm and ended up staring at a black screen....

December 18, 2010 · len

Ubuntu 10.10 netbook first impressions

As always I’ve been waiting with curiosity the new Ubuntu 10.10 release which this year was auspiciously launched on 10.10.10. I had also heard some rumors about the new netbook “Unity” interface so I’ve decided to give it a try. I own since a few years a Acer Aspire One which despite the very slow SSD drive I still use for bedtime book reading, watching some internet recorded tv shows (mainly envoyee special) and morning news reading....

October 12, 2010 · len

The long awaited migration from Qmail to Postfix

I’ve been running qmail based mail servers for years. And you can imagine how many if I am planning this migration from at least 3 years. To be very honest qmail does a very very good job. This is the reason it took so much time to actually do it. In fact qmail has only one problem: it’s stuck in the past. If you want to install something new: say SPF of DKIM you need to patch, recompile....

August 20, 2010 · len

Tethered capture with ubuntu and D450

Shooting a photo and the imediately seeing it on a large monitor is a feature I’ve always wished. I don’t say live view on a display but instant copy and display would suffice. And actually, as I found out, it’s quite easy to achieve on Ubuntu Linux (10.04) with a Canon D450. Required software Make sure gphoto2 and geeqie (former gqview) is installed. An apt will do the trick: sudo apt-get install gphoto2 geeqie Scripts I’ve written 2 scripts....

July 8, 2010 · len

Ubuntu Lucid Lynx

There was not much I expected from the new ubuntu Lucid Lynx as I was happy enough with the existing version already. But I a good tradition and because I woke up at 8:30 this Saturday I decided to go ahead and install it on my Dell D820. The install The install went smoothly, everything was detected, installed the upgrades, the nvidia drivers and some day to day packages: mozilla-thunderbird, pidgin, emacs....

May 8, 2010 · len

Linux encrypted file(system)

Searching for a way to encrypt your files or filesystem on Linux can be an overwhelming choice. At a simple search you find different terms and solutions such as: encfs, dm-crypt, truecrypt, loopback crypt, aespipe, LUKS, etc. The answer is obviously historical. There are a lot of solutions some of them deprecated. I remember a few years ago I solved a similar problem using a tool (can’t remember which) which I was unable to find 2 years later thus remaining with a large file and lost data....

January 27, 2010 · len