Monthly Archives: May 2014

Automated WordPress Backup on Uberspace

This is how I backup this site, hosted on Uberspace.

Note: All scripts should be made executable: chmod +x script

I created the following file ~/bin/

NOW=$(date +"%Y-%m-%d-%H%M")



tar -cvf $BACKUP_DIR/$FILE --transform $WWW_TRANSFORM $WWW_DIR

tar --append --file=$BACKUP_DIR/$FILE --transform $DB_TRANSFORM $BACKUP_DIR/$DB_FILE

Created a cronjob (`crontab -e’) with the following content (daily is sufficient for me):

@daily /home/uberspace_user/bin/

To fetch those backups I created a tiny local script (~/bin/

rsync* /home/local_user/backup/uberspace_ip
ssh 'rm backups/*'

Then setup anacron on a local machine (vi /etc/anacrontab as root):

@daily  10      fetch.uberspace.backups nice run-parts /home/local_user/bin/

My local backup folder should now be filling with backups. I also set MAILTO to my email address, so I get noticed a couple of days (as a reminder to verify everything’s ok). After that I will remove it.

Install VLC via rpmfusion on Fedora 20

These are my notes for installing VLC on Fedora 20, using only rpmfusion free:

gpg --keyserver --recv-keys AE688223 B5F29883
yum localinstall$(rpm -E %fedora).noarch.rpm
gpg --fingerprint AE688223 B5F29883
yum install -y vlc mozilla-vlc

The RPM Fusion Keys were as follows during my installation:

pub   4096R/AE688223 2013-01-01
  Key fingerprint = 0017 DDFE FD13 2929 9D55  B1D3 963A 8848 AE68 8223
uid                  RPM Fusion free repository for Fedora (20) <>

pub   4096R/B5F29883 2013-01-01
  Key fingerprint = A84D CF58 46CB 10B6 5C47  6C35 63C0 DE8C B5F2 9883
uid                  RPM Fusion nonfree repository for Fedora (20) <>

If you want to install libdvdcss, you need to add another repo and then install it:

yum localinstall
yum install libdvdcss

This is the fingerprint I observed:

Importing GPG key 0x66534C2B:
 Userid : " (rpm signing key) <>"
 Fingerprint: 7d6a 4524 1d82 5ec2 fde5 9651 508c e5e6 6653 4c2b  
 Package : atrpms-repo-20-7.fc20.x86_64 (@/atrpms-repo-20-7.fc20.x86_64)
 From : /etc/pki/rpm-gpg/RPM-GPG-KEY-atrpms

Switch ALT with CMD on Apple keyboards on Linux with Kernel 3.13

A feature introduced in kernel 3.13 enables you to easily switch alt and cmd keys on apple keyboards. The following is for Fedora 20:

Switch alt and cmd temporarily (as root). Note that GNOME 3 didn’t seem to realize that during my limited testing, whereas Mate picked it up on the fly:

echo "1" > /sys/module/hid_apple/parameters/swap_opt_cmd

Edit/create /etc/rc.d/rc.local with the following contents to make this permanent:

echo "1" > /sys/module/hid_apple/parameters/swap_opt_cmd

Make it executable:

chmod 700 /etc/rc.d/rc.local