1

I recently updated my Samba and now it made a mess. Here is a part of my current smb.conf:

pi@raspberrypi ~ $ cat /etc/samba/smb.conf
[global]
        (...)
[homes]
        comment = Home Directories
        valid users = %S
        create mask = 0700
        directory mask = 0700
        browseable = No

[printers]
        comment = All Printers
        path = /var/spool/samba
        create mask = 0700
        printable = Yes
        print ok = Yes
        browseable = No

[print$]
        comment = Printer Drivers
        path = /var/lib/samba/printers

[data]
        path = /
        valid users = pi
        force user = root
        read only = No
        create mask = 0777
        directory mask = 0777
        guest ok = Yes

[apache_root]
        path = /var/www/
        valid users = pi
        force user = root
        read only = No
        create mask = 0777
        directory mask = 0777

[Seagate_500GB]
        path = /media/seagate/
        guest ok = Yes
        browseable = Yes
        writeable - Yes
        valid users = pi
        force user = pi
        create mask = 0777
        directory mask = 0777
        read only = No

Every share can be browsed, but only the apache_root section is working perfectly (Writing files & browsing).

The home folder share looks fine, but when I tried to write/delete a file to the directory it says that I do not have access to it.

I can't access any folder or files except the root directory itself.

What should I do to make everything work again?

1 Answer 1

0

You need to add read only = No to the [homes] configuration block. SAMBA defaults to read only = Yes.

You don't seem to indicate what is wrong in any of the other shares.

Also, in your title you mention an issue creating files with filenames that contain NON-ASCII characters. You will run into issues with some applications when using non-ascii characters in filenames. My advice is just not to use those characters in filenames. If you give more specifics about which characters where causing trouble there may be a fix for it, but without more detail it is hard to say.

8
  • adding read only = No solved the problem. I have a file which called "通話_2.3.2.apk"(Obviously it have chinese characters, which is non-ascii.) when I copy the file to the root directory share, it says that I do not have the permission to do that. puu.sh/mwtjw.jpg when I copy the file to the Seagate share, it said that the file is too large to fit in the folder. puu.sh/mwtns.jpg (I did a little googleing and found that the error is actually ERROR_INVALID_PARAMETER) Commented Jan 15, 2016 at 10:37
  • Another problem is that sometimes it will give me either this puu.sh/mwtxL.jpg or this puu.sh/mwtAk.jpg. The first screen returns an error code 0x8007045D. The second screen says "<%1 NULL:NameDest>" is too large to fit in the file system. I cant really know what's going on with my samba...:S Commented Jan 15, 2016 at 10:40
  • When copying to the root directory, make sure your user has the appropriate permission to write to the location you are trying to write to. Report the output of: ls -l /path/to/write/directory/ Also, how much space is left on the Seagate drive? Run df -H and report the results. What is the size of the file you are trying to write? du --si /path/to/file Commented Jan 15, 2016 at 19:00
  • The seagate drive is a new-formatted drive, so I think that it isn't a problem. df -H outputs: puu.sh/mxTfC.txt. ls -l / outputs: puu.sh/mxTiX.txt. du --si the file returns that the file is 33M in size. Commented Jan 16, 2016 at 15:41
  • additionally I also found that although Windows reporting that theres an error in copying/ creating the file, it will write to the directory, as seen in the result of ls -l. Commented Jan 16, 2016 at 15:43

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.