LibreOffice/Snap can't find my other hard disk

So, I have two hard disks: one smaller SSD and a bigger HDD in my laptop. I mounted the SSD as the root / partition and the HDD under /data. But when I try to open a document located in /data/Documents with LibreOffice, he says he can’t find the file?

Also, when I click the “Open” option in the “File” menu, and try to nagivate to the document I want to open the whole /data partition isn’t even listed in the file explorer. (but visible in normal Nautilus) Is this a limitation of Snap or a bug in LibreOffice?

This is a limitation of Snap, by default the home interface only allows access to the home directory excluding the hidden files right under it, and the manually connected removable-media interface only allows access under /media/* and /run/media/*.

Ah, I see thanks for the answer.

Is there any way to allow Snap to access more directories? I’d rather not mount my HDD under /media since well, it’s not really removable media. :stuck_out_tongue:

Yes it is possible (but probably not permanent), check out Auto-connect Request for the guvcview-brlin Snap - store - snapcraft.io.

You may also want to check out Interface:mnt - doc - snapcraft.io.

Thanks, I’ll check those links out. Also moved the topic to another category since it’s actually not really related to LibreOffice in particular then.

well, actual removable media typically gets mounted under /media/<user>/<devicename> if you mount it in /media/<devicename> you should be fine … it is media after all :wink:

alternatively you could add a bind mount from /data to something like $HOME/data that will work as well … snapd wont allow other dirs currently.

The F.H.S. doesn’t agree with you

perhaps because my usage of floppies and zip disks has gone down a little recently :wink:

(but seriously, why would anyone care for a personal home installation if this is FHS compliant … ?)

1 Like

Well I edited my fstab file and now it’s mounted as /media/data… it works for now and I can open my files again so I’m happy :smile:

But might be nice if you could just give permissions to any location in the future!

1 Like

Maybe an fstab interface is desirable that allows non-blacklisted mountpoints set in /etc/fstab to be accessed by snaps.

1 Like

I installed Ubuntu 20.04 yesterday.
I have the exact same problem with Gimp, Inkscape and Mattermost: I got two HD, impossible for those apps to access files in /data.

What I don’t understand is that Telegram, Skype, or Visual Studio (also installed as snaps) are able to access files on /data.

So I suppose it is not a snap limitation.