File names issue on PI Media Server

Not sure where to start… pretty new to linux overall.

I have a PI media server with two hard drives. One drive only I have direct access to and one for the family to pull files from. I have OPENMEDIAVAULT set up to control the drives and am using the RSYNC functionality to mirror the archive to the share folder. The issue is that after the RSYNC runs the file names no longer match. The first six files are perfect… file seven however…

When accessing the folders through a GUI MAC OS / WINDOWS / LINUX… the archive folder shows

[7] Happy Happy Sing Along :yellow_square: you are my sunshine | #7 | Billy Joe Bob | Lets Play_Together.mp4

The Share folder shows… _M6PMB~C.MP4

If I SSH into the folders the file names match.

Archive Folder through terminal ‘[7] Happy Happy Sing Along ‘$’\360\237\237\250’’ you are my sunshine | #7 | Billy Joe Bob | Lets Play_Together.mp4’

Share Folder through terminal ‘[7] Happy Happy Sing Along ‘$’\360\237\237\250’’ you are my sunshine | #7 | Billy Joe Bob | Lets Play_Together.mp4’

I am not sure where the _M6PMB~C.MP4 is coming from or how to get the file name back to the source file name.

I have tried removing the :yellow_square:, rerunning the RSYNC and the name change still occurs. If i delete all the files on in the share folder and rerun RSYNC the first six files are fine… special characters and all… files seven and up get a new random file name.

Anyone seen something like this before?

I guess you’re sharing with Samba? Those mangled filenames are kind of a leftover thing from the dark ages of MS-DOS where you were limited to 8.3 format file names.

You can tell Samba not to do that in your Samba configuration file /etc/samba/smb.conf:

 [global]
mangled names= no

Then restart Samba with:

sudo systemctl restart smbd

OPENMEDIAVAULT has that file locked down to changes. But now that i know what to call it i was able to make the adjustment in the manner that OPENMEDIAVAULT allows. However that opened up a whole new can of worms. If i use the “mangled names = no” option… the system just flat won’t show the files at all. Go from just over thirty files to only the first six.
Guess i am just snake bit.
Thank you for your reply, your knowledge was exactly what i needed to move forward. Guess i get to chase this rabbit a little further down the hole. If you are interested, I will post if i make any further progress.

1 Like

I’m glad it pointed you in the right direction! :slight_smile:

IDK Openmediavault enough to be able to help more, but it seems weird that it’s doing that. Are your filesystems in FAT format or such?