You are not logged in.

#1 2017-11-09 23:40:02

Keltere
Member
Registered: 2017-10-05
Posts: 12

Webmin won't recognize rar file

Hi, i can't get webmin to recognize rar file. I've heard the mime of rar file has changed on the "shared-mime-info" package from "application/x-rar" to "application/vnd.rar"
I tried to contact the creator of webmin but i could't get to resolve it.
Capture.png

Thanks for the help.

Last edited by Keltere (2017-11-27 15:21:42)

Offline

#2 2017-11-09 23:58:40

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,330
Website

Re: Webmin won't recognize rar file


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2017-11-10 22:24:18

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

Thanks but i've already tried to add a custom xml but it's not working, maybe i'm doing something wrong.

~/.local/share/mime/packages/application-x-rar.xml
<?xml version="1.0" encoding="UTF-8"?>
<mime-info xmlns="http://www.freedesktop.org/standards/shared-mime-info">
    <mime-type type="application/x-rar">
        <comment>foo file</comment>
        <icon name="application-x-rar"/>
        <glob-deleteall/>
        <glob pattern="*.rar"/>
    </mime-type>
</mime-info>

Offline

#4 2017-11-11 13:09:07

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,939

Re: Webmin won't recognize rar file

Is that screenshot from filemin aka the webmin html filemanager or from something else ?

Is unrar installed ?

Does installing full rar from aur make a difference ?
(Some programs expect to be able to use rar x instead of unrar to extract something)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#5 2017-11-11 21:11:18

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

Lone_Wolf wrote:

Is that screenshot from filemin aka the webmin html filemanager or from something else ?

Is unrar installed ?

Does installing full rar from aur make a difference ?
(Some programs expect to be able to use rar x instead of unrar to extract something)

Yes it is from webmin.
I have installed both unrar and rar but nothing changed.
I've also tried to add custom mime on webmin but i can't add the dot so i don't know how to test vnd.rar

Offline

#6 2017-11-12 12:58:31

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,939

Re: Webmin won't recognize rar file

let's try to find out some details about the file in question and mime on your system, post the output of

file Capture.rar
file -i  Capture.rar
file -kr Capture.rar
mimetype Capture.rar
mimeopen --ask Capture.rar

Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#7 2017-11-12 17:55:06

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

 Capture.rar: RAR archive data, v5

Capture.rar: application/x-rar; charset=binary

Capture.rar: RAR archive data, v5
- data

Capture.rar: application/vnd.rar

Please choose an application

Thanks for helping me, i hope we find a solution. Also a friend of mine has the same problem but on Manjaro so it's not only my problem.

Last edited by Keltere (2017-11-12 19:04:38)

Offline

#8 2017-11-13 11:55:17

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,939

Re: Webmin won't recognize rar file

Those outputs look ok, let's see what which application handles rar on your system.

$ xdg-mime query default application/x-rar
$ xdg-mime query default application/vnd.rar



Keltere wrote:

I tried to contact the creator of webmin but i could't get a help to resolve it because is not webmin fault.

Even if this is not a webmin bug, information about how webmin html filemanager determines which filetypes can be extracted would help,.
Is there a bug ticket, mailing list thread about this ?

Last edited by Lone_Wolf (2017-11-13 11:55:32)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#9 2017-11-13 12:28:45

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

No output at all on both the command. I've installed xdg-utils to test them.

This is the github issue i've opened some time ago, still searching for a solution.

https://github.com/qooob/authentic-theme/issues/839

Offline

#10 2017-11-13 13:08:29

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,939

Re: Webmin won't recognize rar file

That clarifies how webmin handles things.

your system does understand the rar mimetype, but doesn't have an application associated with it.
Try creating a .desktop file in ~/.local/share/applications , see https://wiki.archlinux.org/index.php/Desktop_entries .


I'm not exactly sure what it should contain, but taking /usr/share/applications/org.kde.ark.desktop as example, something like this might work :

# ~/.local/share/applications/unrar.desktop
[Desktop Entry]
MimeType=application/vnd.rar;application/x-rar;
Name=Unrar
Exec=unrar %U
Type=Application
Terminal=false
NoDisplay=true

Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#11 2017-11-13 13:31:44

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

Now with both "xdg-mime query default application/vnd.rar" and "xdg-mime query default application/x-rar" it show me "unrar.desktop"

With "mimeopen --ask Capture.rar" i still have the same output "Please choose an application" but without any entry. I've checked webmin and still dosen't allow me to handle rar files.

Last edited by Keltere (2017-11-13 13:32:11)

Offline

#12 2017-11-15 13:48:05

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

I've tried to check for zip files and it has the same result as rar files except that zip files work on webmin. I think that the problem is with webmin not with arch or shared-mime-info... I've tried to edit those files but it's still not working.

/opt/webmin/authentic-theme/extensions/file-manager/extract.cgi
/opt/webmin/filemin/extract.cg

Offline

#13 2017-11-17 11:36:24

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 12,939

Re: Webmin won't recognize rar file

on my system compressed files are handled by ark and mimeopen --ask somerarfile  does list ark .

Please install ark to test whether this is same for you.
If mimeinfo does recognize ark, check if webmin also recognizes rar files with ark installed.


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.

clean chroot building not flexible enough ?
Try clean chroot manager by graysky

Offline

#14 2017-11-21 00:14:38

Keltere
Member
Registered: 2017-10-05
Posts: 12

Re: Webmin won't recognize rar file

I'm using a remote server with no gui, i've asked a friend to test it but it didn't resolve the problem. I just think i need to edit something in webmin i just don't know what.
Anyway thanks for the help, i really appreciate it.

Last edited by Keltere (2017-11-21 00:16:04)

Offline

Board footer

Powered by FluxBB