Ubuntu – file:// protocol connected with wrong program

filesgnomegnome-panelgnome2protocol

I have the problem that when I open some programs/documents in Gnome, the wrong application is launched to open these.

I think I already narrowed the problem, that everything that is called with file:// will be launched with the wrong program (in my case keepassx). I remember that when everything starts, I wanted to start keepassx from my gnome-panel. Ubuntu asked me with what program it should be started. I wondered a little, since I used it already a lot, so I choosed keepassx from the list. But it seems that this has overriden the file-protocol handler.

Some situations where the wrong program is called: shortcuts in my gnome panel (personal folder – which should open nautilus, keepassx, some txt files), synapse (launcher like gnome-do) and firefox finished downloads.

How can I reset this setting to get everything back to normal?

Edit:

The only reliable way to open files currently is via nautilus.

To give an example, a shortcut in the gnome-panel has the following properties:
Name: myfile.txt, Location: file:///home/dag/myfile.txt, Comment: »/home/dag/myfile.txt« öffnen

I use Ubuntu 11.04 with "Gnome-classic" aka Gnome2 2.32.1

Best Answer

There are a few places I can think of looking. I'm not entirely sure how you got in this situation, so I'm not sure which is likeliest:

  1. ~/.local/share/applications/defaults.list (see if you have anything suspicious in there)
  2. ~/.local/share/applications/mimeapps.list (likewise)
  3. Run gconf-editor, navigate to /desktop/gnome/url-handlers, and see if you have a file subdirectory in there.

Do any of those help?

Related Question