Remove title from Firefox when maximized(Chrome style)

Add this to CompizConfig under “Window Decorations” in the field “Decoration windows”:


Toggle maximize with Alt-F10. If you hide the “Menu Bar”, you can show it with Alt Gr-F10. This allows for semi-full-screen-mode.

This was tested with Firefox 4 on Linux Mint 10. Install with:

sudo add-apt-repository ppa:mozillateam/firefox-stable
sudo apt-get update
sudo apt-get install firefox ubufox


encfs over sshfs on Linux Mint 10

With standard config you get:
fusermount: bad mount point /folder/name: Permission denied

Uncomment user_allow_other from /etc/fuse.conf, and add user to fuse(get read access to /etc/fuse.conf):

sudo nano /etc/fuse.conf
sudo adduser your_username fuse

Log out, and log back in. Check that you’ve got added to fuse:

id | grep fuse


sshfs -oallow_other host:/folder/to/mount /mountpoint
encfs /folder/to/encrypted /mountpoint/decrypted

Automated encrypted backup with Back In Time

Install encfs and zenity:

apt-get install encfs zenity

Create encrypted directory:

cd /whole/path/to
mkdir .backintime_encfs
mkdir backintime
encfs /whole/path/to/.backintime_encfs /whole/path/to/backintime

If you would like support for hard links(backintime incremental backups), choose the standard mode, not paranoia mode.

Script to mount and run backup:

# Script to mount encrypted directory and run backup.
extpass="zenity --title 'Encrypted backup' --entry 
--text 'Please type password for encrypted backup storage' --hide-text"

#set display for password prompt
export DISPLAY=:0.0
#check if directories exists
if [ -d $enc_path/$enc_directory ] && [ -d $enc_path/$directory ]
  # check if encrypted directory already is mounted
  mountpoint $enc_path/$directory > /dev/null
  if [ "$?" != "0" ]; then
    encfs --extpass="$extpass" $enc_path/$enc_directory $enc_path/$directory
  # check if mount was successful
  mountpoint $enc_path/$directory > /dev/null
  if [ "$?" = "0" ]; then
     echo "Running backup..."
     nice -n 19 /usr/bin/backintime --backup-job >/dev/null 2>&1
     # optional umount of encrypted storage:
     # fusermount -u $enc_path/$directory
     exit 0
    echo "Unable to mount encrypted directory"
    exit 1
  echo "Encrypted directory not found"
  exit 1

Disable schedule in Back In Time, and add script to crontab:

crontab -e
# add this line and save
@hourly /usr/local/bin/encrypted_backup_script


NFS4, hard links and backintime

After a kernel update, I noticed my backups in backintime took very long time. The backups also didn’t increment, every single backup used the same space -> several GB. Incremental backups should only take some MB, the amount of data that have been changed.

First I thought this was a bug in BIT, then zfs-fuse, but the error was in NFS4. When logged in to the server, I could create hard links. NFS4 could not do hard links. If I changed mount options to NFS3, hard links worked. But I don’t want to use NFS3 since NFS4 got username/id linking, so you don’t need the same userids on all of your systems. Seems like this is also why hard links didn’t work. Not sure if the error is because the new kernel does not enable idmapd by default, or if /etc/default/nfs-common was changed in the update. Anyhow, be sure that NEED_IDMAPD equals to yes in /etc/default/nfs-common on both server and clients.


Dell Inspiron 1525 – Power Adapter not recognized

My Dell Inspiron stopped charging battery some months ago. BIOS stated that the power adapter could not be found. Still, the machine was powered by the mains, but not charging battery. I ordered me a new power adapter from ebay, arrived today, but machine still not charging.

I googled, and a Dell support article recommended updating BIOS. Still nothing. Googled some more and found this:

Seems to be a communication problem between the charger and the mother board. The communication goes over the thin middle pin inside the power jack.

I disassembled the computer, taking out the power jack board. Ohmed between the middle pin, and the contact going to the mother board. No contact with any pins. Re-soldered the middle pin of power jack. Ohmed again, with contact between power jack middle pin and the connector. Reassembled. Battery charging again!

You could also buy new power jack boards on ebay:

mount by network location


host.lan:/ /media/mount nfs4 _netdev,noauto,users,async 0 0


ping=`/usr/bin/fping -q host.lan`
if [ $? = 0 ]; then
  mountpoint $stasjon > /dev/null
  if [ $? != 0 ]
    then mount $stasjon
  mountpoint $stasjon > /dev/null
  if [ $? = 0 ]
    then umount -l $stasjon

chmod +x /usr/local/bin/network-mount
crontab -e

* * * * * /usr/local/bin/network-mount

GLSlideshow picture directory and timeout

Linux Mint 10 comes with xscreensaver-gl, uses GNOME screensaver daemon and does not have xscreensaver installed. Therefore, using xscreensaver-demo is not the default way to configure your screen saver and you loose a lot of configuration possibilities. As setting GLSlideshow’s picture directory, timeout, with more. Luckily, it can be done easy with two files:

/etc/X11/app-defaults/XScreenSaver, here you will find

*imageDirectory:        /usr/share/backgrounds

Some personal images would be nice:

*imageDirectory:        ~/Pictures/screensaver


Exec=/usr/lib/xscreensaver/glslideshow -root -duration 5

Here, duration is the timeout for each picture. You can find more options with:

man glslideshow

For example fade, zoom, titles with more.

The manual for xscreensaver does also have information on the /etc/X11/app-defaults/XScreenSaver(under section X RESOURCES), but you need to install xscreensaver and might just use xscreensaver-demo to configure it then.