PDA

View Full Version : Problem with mime types



Szpak
4th February 2007, 07:57 PM
Hi,


I observe strange behaviour of my system. It looks like a problem with mime types. In Nautilus all files are treated as a generic binary or text file (no application assigned). It isn't a problem with Nautilus itself because some apps had stopped working.
For example Evince Document Viewer can't open any PDF file reporting "Unable to open document Unhandled MIME type: 'application/octet-stream'" (even from File->Open menu).
It is probably caused be some updates, but I don't use Nautilus, so it could stay hidden for days (weeks?). What can it be caused by?

I use FC6 and Gnome.


Thanks for your help
Marcin

Szpak
10th February 2007, 04:45 PM
I've checked files:
/usr/share/mime-info/gnome-vfs.keys
/usr/share/mime-info/gnome-vfs.mime
and they look ok (there are proper associaions), but Nautilus doesn't want to use it.

What can be wrong?

sideways
10th February 2007, 04:49 PM
This is a known problem in gnome, I don't think there's a simple solution for all cases.

eg http://www.fedoraforum.org/forum/showthread.php?t=142927&highlight=mime

(This shows how to make it work by setting up an Overrides.xml file)

Szpak
10th February 2007, 06:07 PM
Thanks for your answer.

That wasn't exacly my problem, but following your link I've found (in a few iterations) http://forums.fedoraforum.org/archive/index.php/t-104477.html .

My main problem was the fact that all files in /usr/share/mime were readable only by root and normal user didn't have access to them. Probably some upgraded package changed their permissions (I don't know which application because /usr/share/mime in owned by shared-mime-info which wasn't upgraded, but files inside are not owned by any package).

I added +r for others and delete ~/.local/share/mime
It was also a reason I was seeing "I/O error : Permission denied" after start evince.

sideways
10th February 2007, 10:24 PM
That's a weird one.

This would also have fixed it (type as root)


update-mime-database /usr/share/mime

I wonder if the update-mime-database command was never run, maybe because of a lock up after the install or a package update?

Szpak
10th February 2007, 11:04 PM
That's a weird one.

This would also have fixed it (type as root)


update-mime-database /usr/share/mimeYup, it helped as well.


I wonder if the update-mime-database command was never run, maybe because of a lock up after the install or a package update?That command was probably had run after an instalation of FC6 - everything worked fine. Situation changed 2-3 months ago (probably after some package updation, but I don't know which one).