mount_smbfs Vs encoding

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
Hello,

I am trying to mount from my freenas box 11.1-STABLE-U6 my Windows share using a command like:
mount_smbfs -I 192.168.0.123 -L fr_FR.UTF-8 -E utf8:utf8 //username@computer/Share /mnt/mountpoint

I followed several threads discussing about this (one of them advising the utf8:utf8 conversion, where someone else was saying this was not working, some where advising to change locales, dos charset in the smb4.conf, ...).
My unix charset is set to utf8. This is the only samba setting I left.

The above command works for my French accents, but the Euros sign displays as "?", as well as other specific signs. I pushed the test to even include Asian characters in some filenames in order to see the result, question marks are displayed too.

I made the mount from a linux box (MageIA and Bodhi), both of them "mount -t cifs" my Windows share wihout specifying any locale/encoding and the special chars (especially the euro sign) display correctly. For the asian characters, I used the Terminology terminal emulator to have all of them displaying.

I tried several combinations without any success. As a consequence my rsync command fails (and delete the destination file!) as it cannot process the file with the question mark.

At this point, I would like to have someone being able to reproduce my case and share with me the parameters he used to be able to have utf8 characters working.
I am pretty sure that this thread may help other freenas users. So explanations may be useful too ;)

Thanks in advance and take care
 

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
I just tried 11.2 beta 3 but I was still unable to find the correct combination of options to display correctly Asian characters and the euro sign. French accentuated characters work.

EDIT : 11.2RC2 using new interface still showing "?" in the Shell...
 
Last edited:

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
I switched to 11.2 release and I am still unable to mount a Windows share and have the Euro sign (and some special chars) displaying correctly. As a consequence, a rsync command delete a file named for instance "test file ? file n?1" instead of synchronizing it
 

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
Still no luck with smbfs and latest builds...

I tried this:
mount -t cifs -o username=user //192.168.0.123/share /mnt/mountpoint
but I cannot solve this error:
mount: /192.168.0.123/share: Operation not supported by device

I tried adding options like vers=3.0,sec=3.0 without luck.

Any suggestions? Anyone was able to mount a Windows 10 share from a freenas box?
 

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
I can connect to my Windows share with smbclient, I can browse the directories and I can correctly see all the characters (accentuated ones, even the Chinese characters), but I was not able to mount it in a folder (I am not even sure I can mount using smbclient).

I tried this too :
mount -o username=myuser -t cifs server:/share /mountpoint
but I still get the "mount: server:/share: Operation not supported by device" error

If mount_smbfs is limited to SMB1, why still using it as many Windows machines have now this feature disabled?
There is either an issue with cifs under FreeNAS (and probably other forks), or I have an issue myself...
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
I can connect to my Windows share with smbclient, I can browse the directories and I can correctly see all the characters (accentuated ones, even the Chinese characters), but I was not able to mount it in a folder (I am not even sure I can mount using smbclient).

I tried this too :
mount -o username=myuser -t cifs server:/share /mountpoint
but I still get the "mount: server:/share: Operation not supported by device" error

If mount_smbfs is limited to SMB1, why still using it as many Windows machines have now this feature disabled?
There is either an issue with cifs under FreeNAS (and probably other forks), or I have an issue myself...
It's a FreeBSD issue. The reason why is because SMB2 did not exist when mount_smbfs was written, and changing the SMB client is a significant amount of work. smbclient gives an FTP-like interface. It does not mount remote shares.
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
Do note that this is an smb _client_ issue not an smb _server_ issue. The SMB client is in-kernel and SMB1. Our SMB server is Samba and supports the latest protocols.
 

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
I have no issue pushing files from Windows to FreeNAS, I have issues only when retrieving Windows files from FreeNAS, so yes, it is only a client issue that I cannot solve
 

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
I updated to U4 and made some recent Windows 10 updates and now, my FreeNAS does not mount my Windows share (but can still mount a Windows 7 share). I bet there is SMB1 protocol disabled somewhere...
Is there is any chance that the FreeNAS SMB client will be updated soon to a working one?
 

anodos

Sambassador
iXsystems
Joined
Mar 6, 2014
Messages
9,554
I updated to U4 and made some recent Windows 10 updates and now, my FreeNAS does not mount my Windows share (but can still mount a Windows 7 share). I bet there is SMB1 protocol disabled somewhere...
Is there is any chance that the FreeNAS SMB client will be updated soon to a working one?
No. Writing a new FreeBSD SMB client is a very significant amount of work. The current one works with SMB1.
 

HomeBoy38

Dabbler
Joined
Sep 27, 2018
Messages
15
I did not had in mind rewriting the client, is it too complex to port existing cifs client from other distributions to FreeBSD (I have no idea)? To solve my issue, I might be able to use a Windows rsync to push files to my FreeNAS, but I am not sure it will be better than my robocopy actual script...
 
Top