samba server does not work Topic is solved

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
nanooker
Posts: 17
Joined: Sun Dec 06, 2020 7:41 pm

samba server does not work

Post by nanooker »

Hello,
i want to enable the smb server on dietpi. I did the installation of the samba server. During the automatic configuration the following message appears

FAILED] Samba mount failed with the following error output: │
│ │
│ mount error(2): No such file or directory │
│ Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) │
│ mount error(2): No such file or directory │
│ Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) │
│ mount error(2): No such file or directory │
│ Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) │
│ mount error(2): No such file or directory │
│ Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) │
│ mount error(2): No such file or directory │
│ Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) │


I assume that the file is created during the automatic configuration. Or do I see it wrong.
Do I have to create a file before? The Raspberrypi 3B+ is connected to an usb disk which is mounted. My system is linux debian
Is there a detailed description? I can't find anything anywhere.
Could someone give me a hint what I am doing wrong? Thanks a lot
User avatar
Joulinar
Posts: 3135
Joined: Sat Nov 16, 2019 12:49 am

Re: samba server does not work

Post by Joulinar »

Hi,

many thanks for your message. Just for clarification. You like to configure DietPi as SAMBA client to be able to connect to a different SAMBA server?

According the error message, the share you specified did no exist on SAMBA server side.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
nanooker
Posts: 17
Joined: Sun Dec 06, 2020 7:41 pm

Re: samba server does not work

Post by nanooker »

Good Morning Joulinar,
Thank you very much for your answer. I found the manual and the smb server is running fine.
It was about making the hard disk on the raspberrypi visible on my PC and in the network to store data on it.
I was just too stupid for that. Now it runs wonderfully.
Now I just want to change the smb user. But I cannot find the /etc/samba/smb.conf.
User avatar
Joulinar
Posts: 3135
Joined: Sat Nov 16, 2019 12:49 am

Re: samba server does not work

Post by Joulinar »

hmm that's quite strange, /etc/samba/smb.conf is the main configuration file and it should be there. Otherwise SAMBA should not work. Can you check

Code: Select all

ls -la /etc/samba/
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
nanooker
Posts: 17
Joined: Sun Dec 06, 2020 7:41 pm

Re: samba server does not work

Post by nanooker »

but that should already be there. I just don't know where to look?
User avatar
Joulinar
Posts: 3135
Joined: Sat Nov 16, 2019 12:49 am

Re: samba server does not work

Post by Joulinar »

pls can you do following on command line

Code: Select all

cat /etc/samba/smb.conf
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
nanooker
Posts: 17
Joined: Sun Dec 06, 2020 7:41 pm

Re: samba server does not work

Post by nanooker »

that is the output
workgroup = WORKGROUP
server string = %h server
dns proxy = no
log file = /var/log/samba/log.%m
max log size = 1000
syslog only = no
syslog = 0

panic action = /usr/share/samba/panic-action %d

security = user
encrypt passwords = true
passdb backend = tdbsam
obey pam restrictions = yes
unix password sync = yes

passwd program = /usr/bin/passwd %u
passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* .
pam password change = yes
map to guest = bad user

load printers = no
printcap name = /dev/null
disable spoolss = yes

[dietpi]
comment = DietPi Share
path = /mnt/dietpi_userdata
browseable = yes
create mask = 0664
directory mask = 0775
valid users = dietpi
writeable = yes
User avatar
Joulinar
Posts: 3135
Joined: Sat Nov 16, 2019 12:49 am

Re: samba server does not work

Post by Joulinar »

Hi,

this is your SAMBA configuration file. The last 7 lines describing details of your share

Code: Select all

[dietpi]
comment = DietPi Share
path = /mnt/dietpi_userdata
browseable = yes
create mask = 0664
directory mask = 0775
valid users = dietpi
writeable = yes
What do you like to change now?
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
nanooker
Posts: 17
Joined: Sun Dec 06, 2020 7:41 pm

Re: samba server does not work

Post by nanooker »

somewhere i read to change the smb name dietpi because of security. Whatever the reason?
If this is not necessary, I leave it as it is. I just wanted to know how to get to the etc file to change the name. There is the dietpi-explorer, where you can change the smb password and the name? Is that correct?
I don't want to annoy you with this topic any longer, the smb server is running wonderfully. You have already helped me there.
More important is the other topic with letsencrypt. I have installed the Baikal Webdav. It runs and synchronizes perfectly. But without tls encryption it makes no sense.
User avatar
Joulinar
Posts: 3135
Joined: Sat Nov 16, 2019 12:49 am

Re: samba server does not work

Post by Joulinar »

as long as you don't use standard password on user DietPi you should be fine.

However if you like to change the user anyway, you would need to create a user first. By default DietPi did not contain any personal user.

To edit SAMBA configuration file just do nano /etc/samba/smb.conf and change the user within the share configuration section.
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team
Post Reply