Samba 4

Hello, I have just installed Samba 4 on FreeBSD 10.3 Release. I am having a problem to start it. I have created the file smb4.conf in /usr/local/etc/ but when I go to start samba this happens:

#service samba start
Code:
samba does not exist in /etc/rc.d or the local startup directories (/usr/local/etc/rc.d)

Also tried with smb and smb4 with same reply. What I am doing wrong and how to fix it?
 
Last edited by a moderator:
bangmyhead, try service samba_server onestart. And if you add samba_server_enable="YES" to /etc/rc.conf, you can use service samba_server start.

That worked but I have a new problem now

Code:
#serivce samba_server onestart
Performing a sanity check on Samba configuration: FAILED

and in /var/log/samba4 there is no log to check
 
bangmyhead, your configuration file's /usr/local/etc/smb4.conf, right? I'm asking because it looks like you may have experimented with naming it smb.conf.

Maybe the output of smbd -d 3 -i -s /usr/local/etc/smb4.conf would include a clue about the problem's cause.

I'd also be happy to eyeball your smb4.conf, if you feel like posting it.
 
Because of the vulnerabilities found in 3.X & 4.X, and the none-upgrade of it, I decided to upgrade to Samba 4.4, and my shared folders broke instantly. No Active Directory & Domain Servers & all that crap. Wtf??? Lots of docs are not up-to-date, indeed!
  1. I found out that only samba-tool testparm is useful in my specific case, only shared folders (we are allowed to say 'folders' when it's Windows related ;)).
  2. I also made sure that all options in /usr/local/etc/smb4.conf are good. This file was generated during the upgrade and contained old stuff (some incompatible), and new stuff. Config file compared to: man smb.conf. At the end, it specifically says:
This man page is correct for version 4 of the Samba suite.

An then, my shared folders came back! Yeah! Hope this helps!
Dominique.
 
How do I get SAMBA to auto start?

I have the following in my /etc/rc.conf but that does not seem to do it:

samba_server_enable="YES"

EDIT:

I just realized that SAMBA may have been started. I tried:


ps -aux | grep smbd
ps -aux | grep nmbd


and got nothing.

How do I know if SAMBA is running?
 
Look at the file /usr/local/etc/rc.d/samba. There should be instruction on the header section of this file. Mine read as

Code:
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
# to enable this service:
#
#samba_enable="YES"
 
walterbyrd, Samba is very complex. What Samba version have you installed? What Samba features do you intend to use? Do you see anything suspicious in the log files? Share your configuration file with us! If nmbd and smbd aren't running, I would suspect Samba's config file.

For example, my Samba 4.4 server for shared folders is launched using:
Code:
samba_enable="NO"
samba_server_enable="YES"
in /etc/rc.conf.

Dominique.
 
Now, I seem to be able to find the samba processes. No idea why.

I am curious as to way you run

Code:
samba_enable="NO"
samba_server_enable="YES"

Why do you specifically run:

Code:
samba_enable="NO"
?
 
It would prevent Samba 3.x from starting, probably in case something went wrong and you accidentally end up with both Samba 3.x and Samba 4.x.
 
Back
Top