Relative path on Win10/Ubuntu to store date on NAS

Win 10 & Ubuntu 20.02 Gramps 5.1.3

Hello,

I would like to store my data on a NAS server and edit them both from Windows and from a Linux computer (Ubuntu).

This works fine with the database. As I understand it, each computer actually stores its relative media path locally. On the Windows system this goes, also only with the Ubuntu system I always get an error. In addition, I see under relative media path in the GUI also always the Windows path.

What am I doing wrong?

The relative media path is stored both locally, and in the db. When a db is created or when the path is changed in the preferences while the db is open, a copy of the path is included into your db. So when set on one system, (Windows), and opened on another system, the path will end up pointing to the wrong place. Unless you can figure out a way to make the path appear the same on both systems.

I had the same issue when I put my Gramps data on the USB drive connected to my Router (Router/USB)

I could use the Gramps data fine with Windows, Router/USB mapped as drive Z:

But on my Linux Mint systems Gramps would report the Router/USB data files as Read Only. All other Linux based applications would work fine with any data stored on the Router/USB.

To rectify this issue I had to create a Mount Point on the Linux Local Drive for Router/USB and I can now use Gramps on my Linux and Windows systems.

Note 1: This problem only existed for Gramps all other data on Router/USB was available to all other Linux based applications.

Note 2: I have to thank Nick Hall for assisting me with and resolving this issue.

I’ll lookup the required string added to fstab later if you require it.

1 Like

The RMP is stored with each individual tree and not as a universal Gramps setting. This allows each tree a user may create to have its own media folder.

I have tried a few things but can’t get the database file to become writable.
No matter if I use my NAS or GoogleDrive. With all other programs I can work with the data on NAS/GoogleDrive but not with Gramps.
I think I will work locally on the Linux system and copy to NAS/GoogleDrive when I make changes.

Create a local folder called Samba on your Linux system

Now edit its fstab file and add the following line

//NNN.NNN.NNN.NNN/NNNN /mnt/Samba cifs user=username,pass=password_mode=0777,dir_mode=0777,uid=1000,gid=1000,vers=1.0

Where
NNN.NNN.NNN.NNN = network address of your NAS drive
NNNN = Name of the NAS drive
username = your username
password = your password

Now reboot and you should see the content of your NAS drive in the Samba folder.

If at anytime you loose network connection then the Samba folder will be empty. If so correct the network problem and reboot the system.

You may need to edit the parameters of (_mode=0777,dir_mode=0777,uid=1000,gid=1000,vers=1.00 but I found these worked for me.

1 Like

Thank you Keithjac,

the vers=1.00 entry did the trick.

I know it’s more of a Linux problem.
The permissions in my directory are correct


but I still get the message:

53365: ERROR: grampsapp.py: line 156: Unhandled exception
Traceback (most recent call last):
File “/usr/lib/python3/dist-packages/gramps/plugins/db/dbapi/sqlite.py”, line 160, in commit
self.__connection.commit()
sqlite3.OperationalError: database is locked

I have no idea what else this could be.

Regards Holger