Can't export database on my Veros - don't have write permissions

I have two Veros connected to a network drive (a Banana Pi with a hdd attached).

I’ve mounted that network drive on the Veros via fstab.

I’m wanting to change the BPi to a Raspberry Pi, and in prep for doing that I’m wanting to export my current library so that I can just reimport it back in when I’ve got the RPi set up correctly.

I’m going to mount everything in the same paths so that there’s no difference in paths whether it is the BPi or RPi as the network drive.

However, my problem is when I go to export the library on to my network media drive from either of my Veros, whether I do it as a single file or multiple files, I get an error that I don’t have permission to write to the drive.

I’m not sure how or why I don’t have permission, as I’m pretty sure once upon a time a few years ago I backed up the library on the same network drive.

I can write to the drive over a network Samba share from my windows desktop (no Kodi installed on it), so it does seem as though it is just my Veros that have an issue with write permissions.

How do I go about fixing this so I can export the library both as a single file and as multiple files, to the network media drive?

Thanks.

Are you using the same username on the Vero and Windows?
How does your fstab look like?
Share URL of grab-logs -f

I’m not sure I’m using a username on Windows. The drive is just showing up in windows explorer under Network, and I can read, write, delete etc from it via windows explorer.

The URL is https://paste.osmc.tv/liqitacidu

In the smb.conf file on the BPi the shared drive has the following:

[Media_Server]
comment = This is the Banana Pi with the media attached
path = /media/media
available = yes
read only = no
browseable = yes
public = yes
writable = yes
create mask = 0777
directory mask = 0777
force user = root

Ok, using root as a user most like is your problem.
What does ls -lah /mnt/media give you.

total 117M
drwxrwxrwx+ 11 root root 0 Dec 3 22:31 .
drwxrwxrwx 3 root root 4.0K Jan 1 2015 …
drwxrwxrwx+ 136 root root 0 Nov 17 17:59 ‘Asian Films’
drwxrwxrwx+ 6 root root 0 Nov 17 00:00 Backgrounds
drwxrwxrwx+ 193 root root 0 Nov 28 11:31 ‘Family Films’
drwxrwxrwx+ 518 root root 0 Dec 3 12:36 Films
drwxrwxrwx+ 4 root root 0 Nov 18 07:32 Fitness
drwxrwxrwx+ 21 root root 0 Nov 17 02:36 “Kids’ TV”
drwxrwxrwx+ 2 root root 0 Dec 3 22:31 Lib
drwxrwxrwx+ 101 root root 0 Nov 28 11:47 TV
-rw-rw-rw-+ 1 root root 116M Dec 3 16:05 all_databases.sql
drwxrw-rw-+ 2 root root 0 Nov 16 22:23 lost+found

Technically should work.
What does touch /mnt/media/test.txt do and then check ls -lah /mnt/media/test.txt

touch: cannot touch ‘/mnt/media/test.txt’: Permission denied

-rw-r–r--+ 1 root root 0 Dec 4 10:27 /mnt/media/test.txt

I am at loss here now.
Maybe someone else has some ideas what is going on.
To be honest the solution with force root and using user root is not ideal.

I’m more than happy to change that! I’ll delete it out and see what happens.

Well you then would need to create a user and configure that in fstab.
And also would need to re-set the ownership on the existing files
And have public=no
So not sure if such a clean approach is really what you want.

Ok. I’m not sure I’ve ever had a user configured in fstab before, and I’m pretty sure I didn’t have these issues at some point in the past.

I’m starting to think just setting up the RPi as the server, then rescraping everything and taking a bit of time to re-set the library as I want it may be simpler than trying to figure all this out!!

Well that is surely an option, but to be honest cleaning up your setup may not harm. And as I wrote in the other thread as long a you keep the mount point as /mnt/mediayour existing database would work fine.

Unfortunately it didn’t work though (or I misunderstood something), which is why I was going this other method. I had the RPi all set up, had exported the sql from the BPi using mysqldump and reimported it on the RPi, mounted the network drive in the same place, and could access the media files going through the files menu, but nothing was showing up in library mode.

And on a bizarre side note - I’ve not changed the media folder names in years. One of the folders is called Kids’ TV - with the single quote. Had worked fine for ages, but isn’t used too much, but was last month. All was ok.

Tried it yesterday and path was not found. I checked all my path and playlist info on this one and it was recorded in those as Kids TV - without the single quote. Did the most recent update of OSMC change things so that it started to recognise the single quote in directory names?

And thanks for all the replies you’ve given to the multiple posts I’ve made. While I’ve not yet got to a solution, taking the time to respond and help me out is appreciated!

Did you changed the IP address for the MYSQL server?

You should have shared logs at that time.

No, as I made the Rpi have the same IP address as the BPi so there was less to change.

I didn’t have the BPi and RPi on at the same time at any point, so there shouldn’t have been any conflict of IPs.

Would suggest to power up the RPi again and share logs to figure out why nothing in the library.
Can continue in the other thread for troubleshooting