2

I have a secondary internal hard drive to store files. However, Snap programs in Ubuntu do not have the permissions to open the files on the secondary hard drive. To open files with certain Snap apps, I have to copy them first to the primary Ubuntu drive to access them.

Desired solution: How do I enable Snap access to contents on my secondary internal HDD as if it was my main hard drive with full permissions.

Rockishi
  • 563
  • 3
  • 8
  • 14

1 Answers1

2

Snap is quite rigid in its permission system. Lacking options for a more granular control on which locations a snap can access, you may mount that internal hard drive under your home folder, or better, especially on multi-user systems, mount --bind specific folders of the second internal HDD under folders where your snap application has access. Symbolic links unfortunately do not work for that purpose.

vanadium
  • 82,909
  • 6
  • 116
  • 186
  • This worked! I had a data partition normally mounted as /D with a folder `mydocs` containing my documents. Now after `sudo mkdir /media/mydocs`, `sudo mount --bind /D/mydocs /media/docs` I can e.g. drag a drop an image to the firefox browser window (firefox is installed as a snap since Ubuntu 22.04). This did not work before. – geekQ May 15 '23 at 09:38