Belgium
May - 09

25

F-Spot photos on remote SFTP broken in Ubuntu Jaunty

Posted in Linux on May 25th, 2009 by Nicolas

After upgrading to Ubuntu Jaunty yesterday, I found that none of the pictures I had in F-Spot worked anymore. Ok, I have my pictures stored on a remote machine and I access them through SFTP but that shouldn’t be a reason for it to break so easily.

It appears that between Intrepid and Jaunty, the GVFS mounts done through the Places->Connect to Server… have changed mountpoint. Ideed, when they used to be mounted to /home/nicolas/.gvfs/sftp on someserver/ they are now mounted to /home/nicolas/.gvfs/sftp for nicolas on someserver/ and this broke F-Spot’s database.

In order to fix that, I went through the following:

1. Backed up /home/nicolas/.gnome2/f-spot in case I messed it up. 
2. sudo apt-get install sqlitebrowser 
3. sqlitebrowser /home/nicolas/.gnome2/f-spot/photos.db 
4. File-> Export -> Database to SQL file (data.sql in my case) 
5. Replaced all occurences of /home/nicolas/.gvfs/sftp on someserver/ 
with /home/nicolas/.gvfs/sftp for nicolas on someserver/ using 
a text editor

Removed two lines that would not allow me to restore the database:

CREATE TABLE sqlite_sequence(name,seq); 
INSERT INTO sqlite_sequence VALUES('photos',3306);

Restored the database:

sqlite3 -init data.sql data.db

Finally, overwrote photos.db with data.db

mv data.db photos.db

This fixed it and I got my photos back ;) In order to be able to import new photos however, I had to change the default location which was not found anymore as it still refered to /home/nicolas/.gvfs/sftp on someserver. This was done in the preferences window!

Happy F-Spotting

Tags: ,