Select Your Language

Infrastructure and Management

Cloud Computing

Storage

Runtimes

Integration and Automation

  • Comments
  • Strange behavior of default application assignment

    Posted on

    Some of our RHEL 5.10 servers show strange behavior in assigning a default application to a specific MIME-Type, say application/pdf. I expect /usr/share/applications/defaults.list to set the standard application for each MIME-Type. This works for most of our servers, but some are dealing different...

    When I cd to /usr/share/applications on any machine and look into defaults.list, it says:

    root@red1:1258> grep pdf defaults.list 
    application/pdf=AdobeReader.desktop
    

    AdobeReader.desktop is existing and is world readable on each machine:

    root@red1:1259> ls -l AdobeReader.desktop 
    -rw-r--r-- 1 root root 371 23. Sep 07:35 AdobeReader.desktop
    

    Therefore, Adobe Reader should be the default application for PDF files. Let's check with xdg tools:

    root@red1:1260> xdg-mime query default application/pdf
    AdobeReader.desktop
    

    OK, but files seem to get opened via the Gnome Virtual File System, which seems to ignore the default on the machines in question:

    root@red1:1261> gnomevfs-info /some/path/MA.pdf 
    Name              : MA.pdf
    Type              : Regular
    MIME type         : application/pdf
    Default app       : evince.desktop
    Size              : 34357
    Blocks            : 72
    I/O block size    : 32768
    Local             : YES
    SUID              : NO
    SGID              : NO
    Sticky            : NO
    Permissions       : 600600
    Link count        : 1
    UID               : 515
    GID               : 100
    Access time       : Fri Sep 27 16:46:13 2013
    Modification time : Fri Sep 27 16:46:14 2013
    Change time       : Sat Jan 25 14:50:15 2014
    Device #          : 19
    Inode #           : 92410160
    Readable          : YES
    Writable          : YES
    Executable        : NO
    

    Gnome VFS seems to default to the first application entry in mimeinfo.cache, which is evince on this machine:

    root@red1:1262> grep pdf mimeinfo.cache 
    application/pdf=evince.desktop;AdobeReader.desktop;fedora-gv.desktop;
    

    Of course I can alter the sequence of applications in mimeinfo.cache, which immediately influences the default application. But since the cache file is newly generated when installing or uninstalling packages, this would be necessary quite frequently.

    Therefore I kindly ask if anybody can point me a way to
    - make Gnome VFS respect the default application, or at least
    - influence the application sequence in mimeinfo.cache in a persistent way.

    Any help would be highly appreciated.

    by

    points

    Responses

    Red Hat LinkedIn YouTube Facebook X, formerly Twitter

    Quick Links

    Help

    Site Info

    Related Sites

    © 2026 Red Hat