Bug 15766 - unityed_media VFS module not working
Summary: unityed_media VFS module not working
Status: NEW
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: VFS Modules (show other bugs)
Version: unspecified
Hardware: x64 Linux
: P5 critical (vote)
Target Milestone: ---
Assignee: Samba QA Contact
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-12-12 15:20 UTC by otcenas
Modified: 2024-12-13 13:47 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description otcenas 2024-12-12 15:20:44 UTC
VFS module unityed_media not working in recent versions of samba. Tested in 4.19.5-Ubuntu, 4.20.2-Rocky and 4.15.13-TrueNAS (FreeBSD).

The unityed_media VFS module modifies folder names during its operation (e.g., by appending usernames). It is supposed to remove the added user name string when accessed by the same user. However, the second part of this process does not work. After copying files, clients cannot see any created folders in the Avid MediaFiles/MXF directory structure.

Folder structure:

root@host:/mnt/ssdmedia/Avid MediaFiles/MXF# ls -laR
.:
total 12
drwxrwxrwx 3 nobody nogroup 4096 Dec 11 23:19 .
drwxrwxrwx 3 nobody nogroup 4096 Dec 11 22:38 ..
drwxrwxrwx 3 nobody nogroup 4096 Dec 11 23:19 1_jaro.1 #("jaro" is added user name string to folder name "1")

./1_jaro.1:
total 94948
drwxrwxrwx 3 nobody nogroup     4096 Dec 11 23:19 .
drwxrwxrwx 3 nobody nogroup     4096 Dec 11 23:19 ..
-rw-rw-rw- 1 nobody nogroup  5562977 Nov 27  2020 A01.5FC0F414_5FC0F5FC0F414A.mxf
-rw-rw-rw- 1 nobody nogroup  4956769 Nov 27  2020 A01.5FC0F416_5FC0F5FC0F415A.mxf


Error messages in debug log:

[2024/12/11 23:19:15.420073,  5] source3/smbd/open.c:4718(open_directory)
  open_directory: opening directory Avid MediaFiles/MXF, access_mask = 0x100080, share_access = 0x0 create_options = 0x800001, create_disposition = 0x1, file_attributes = 0x10
[2024/12/11 23:19:15.420104,  5] lib/dbwrap/dbwrap.c:172(dbwrap_lock_order_lock)
  dbwrap_lock_order_lock: check lock order 1 for /run/samba/locking.tdb
[2024/12/11 23:19:15.420145,  5] lib/dbwrap/dbwrap.c:204(dbwrap_lock_order_unlock)
  dbwrap_lock_order_unlock: release lock order 1 for /run/samba/locking.tdb
[2024/12/11 23:19:15.420172,  5] source3/smbd/dosmode.c:391(fget_ea_dos_attribute)
  fget_ea_dos_attribute: Cannot get attribute from EA on file Avid MediaFiles/MXF: Error = Bad file descriptor
[2024/12/11 23:19:15.420195,  5] source3/smbd/dosmode.c:68(dos_mode_debug_print)
  dos_mode_debug_print: fdos_mode returning (0x10): "d"
[2024/12/11 23:19:15.420235,  5] source3/smbd/uid.c:327(change_to_user_impersonate)
  change_to_user_impersonate: Skipping user change - already user
[2024/12/11 23:19:15.420257,  5] source3/smbd/uid.c:294(print_impersonation_info)
  print_impersonation_info: Impersonated user: uid=(65534,65534), gid=(0,65534), cwd=[/mnt/ssdmedia]
[2024/12/11 23:19:15.420314,  3] source3/smbd/smb2_trans2.c:2078(smbd_do_qfsinfo)
  smbd_do_qfsinfo: level = 1007
[2024/12/11 23:19:15.420675,  5] source3/smbd/smb2_trans2.c:2331(smbd_do_qfsinfo)
  smbd_do_qfsinfo : SMB_QUERY_FS_FULL_SIZE_INFO bsize=1024, cSectorUnit=2, cBytesSector=512, cUnitTotal=205314024, cUnitAvail=186383708
[2024/12/11 23:19:15.420773,  5] source3/smbd/files.c:1985(file_free)
  file_free: freed files structure 0 (3 used)
[2024/12/11 23:19:15.420791,  5] source3/smbd/files.c:1985(file_free)
  file_free: freed files structure 0 (2 used)
[2024/12/11 23:19:15.421570,  5] source3/smbd/uid.c:327(change_to_user_impersonate)
  change_to_user_impersonate: Skipping user change - already user
[2024/12/11 23:19:15.421649,  5] source3/smbd/uid.c:294(print_impersonation_info)
  print_impersonation_info: Impersonated user: uid=(65534,65534), gid=(0,65534), cwd=[/mnt/ssdmedia]
[2024/12/11 23:19:15.421683,  5] source3/smbd/dosmode.c:391(fget_ea_dos_attribute)
  fget_ea_dos_attribute: Cannot get attribute from EA on file Avid MediaFiles/MXF: Error = Bad file descriptor