There are no necessary rights on the mounted disk when using samba and transmission packages

hello. I raised a question on the github on this topic.

1 Like

That won't get any attention any time soon, there're absolutely no details in the ticket.

There's one known issue, where the permissions get wrong, if the drive is mounted directly under /.

I actually do not understand what you are asking.

Do you mean OpenWrt as Samba client, mounting a remote folder, and use OpenWrt's transmission to download?

And how you mount the disk, how the Samba server configured are not known, no one can guess what's going on.

that's why I wrote it, to find at least some solution.
the disk is mounted via the disk mount package.


samba settings

Sorry I cannot understand the language....however I believe you don't need to wait for people to ask for information, other people might simply ignore your post because of virtually no content in original post, giving more information in first post is the way to get more people to help

yes, you are right, since I do not know where to dig to solve the problem. However, I'm pretty sure that it's about the rights to the mounted disk. because of this, it is not possible to write to the disk either remotely or through the transmission package

The common language here is English, as mentioned above I cannot read the screenshots, I think many people in this forum might feel the same, to increase your audience, you should change it to English.

Disk permission, yes, we all know it's about disk permission, but we cannot simply blame Samba, and I still don't understand your way of operation, are you mounting remote folder and run transmission?

not quite right. Transmission and samba packages are installed on openwrt, but they have a common problem - writing to disk due to the lack of the necessary rights.

Disk /dev/sda: 7.68 GiB, 8242855936 bytes, 16099328 sectors
Disk model: Flash Disk
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 2E592ACE-9E2F-1946-97E1-B04C6A046006
Device     Start      End  Sectors  Size Type
/dev/sda1   2048 16095231 16093184  7.7G Linux filesystem
root@OpenWrt:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root                 4.3M      4.3M         0 100% /rom
tmpfs                   122.3M      3.4M    118.9M   3% /tmp
/dev/ubi0_1              32.9M     23.4M      7.8M  75% /overlay
overlayfs:/overlay       32.9M     23.4M      7.8M  75% /
tmpfs                   512.0K         0    512.0K   0% /dev
/dev/sda1                 7.7G      3.5M      7.2G   0% /mnt/sda1
root@OpenWrt:~#
/dev/sda1: UUID="a1b86d1d-2fc8-4048-9bb5-c52a74bc5097" UUID_SUB="5234f58b-508f-4c3d-bdb3-e71a649ffc8a" BLOCK_SIZE="4096" TYPE="btrfs" PARTUUID="0dcec60c-6d46-b943-b850-a74ba5c94915"
root@OpenWrt:~# cat /etc/config/fstab
config global
        option anon_swap '0'
        option anon_mount '0'
        option auto_swap '1'
        option auto_mount '1'
        option delay_root '5'
        option check_fs '0'
config mount
        option target '/mnt/sda1'
        option uuid 'a1b86d1d-2fc8-4048-9bb5-c52a74bc5097'
        option enabled '1'
        option options 'relatime'
root@OpenWrt:~#

So you are mounting a local disk, someone else create a folder through Samba share to let transmission writing to it?

neither someone, but I mount and try to create a folder remotely, but there is no write access.

config samba
        option workgroup 'WORKGROUP'
        option charset 'UTF-8'
        option description 'Samba on OpenWRT'
        option interface 'lan'
config sambashare
        option name 'share'
        option path '/mnt/sda1'
        option read_only 'no'
        option guest_ok 'yes'
        option create_mask '0666'
        option dir_mask '0777'

What are the dir permissions on /mnt/sda1 ?

1 Like

If it's about permissions, then it's not a transmission or samba issue, as @fakemanhk said.

Fix your topic.

1 Like

Then there exists "someone", which is "you".

Elaborate more, you mount share from remote machine and create folder from remote machine, both working fine, however the folder you created remotely cannot be written by transmission on OpenWrt itself?

If yes, then nothing is wrong with Samba/transmission, Samba is running under root and create files with root permission which transmission user (non-root) cannot write, that's working as intended by default. However what you want to do is possible, this is config question, you need to study how to config smb.conf on file/directory creation mask, user permission.

So this is basically a config issue rather than software bug.

1 Like

References/context:

:+1:

I agree, there seems to be no bug. The OP edited permissions for Transmission, and cause a Samba issue while doing so.

this is a temporary solution, but I wanted to work with the disk without these additional actions, both remotely and download files through the transmission package that is installed on the router.

Still an auth issue, until you prove the opposite.

As I mentioned before, you can configure your Samba to do this, it's not a bug of Samba.

1 Like

then tell me how to set up samba? And at the same time the transmission package, for downloading to a mounted disk, without creating a folder.

Make sure both use the same permissions on files and dirs?

777 if you're lazy.

If you don't know how to, read the Samba docs.

1 Like