[Samba] Samba first time run

Rowland Penny rpenny at samba.org
Mon Mar 27 17:09:50 UTC 2023



On 27/03/2023 17:26, Lm Loge via samba wrote:
> @RowlandPenny
> 
> And why not may I ask you?
> All I'm doing is in the "wiki.samba.org" website pages (see link below 
> for example), can't it be trusted?
> (If not, is there a reliable manual for Samba installation, 
> administration and use?)

That page is for installing Samba from sources and as such, it covers that.

> 
> I thought the "make install" command, installed something, as its name 
> indicates...
> It's written in the wiki:
> "To install Samba, run:
> $ sudo make install"
> (Source: https://wiki.samba.org/index.php/Build_Samba_from_Source)
> 
> And, at the very end of the webpage just mentioned, you have the line:
> "To manually start the Samba Active Directory (AD) domain controller 
> (DC) service, enter:
> # systemctl start samba-ad-dc"
> Which I did and which resulted in a failure (status=1/FAILURE).
> (Of course, I created the systemd unit file beforehand.)
> 
> In this webpage, there is no such instruction as to provision the DC 
> before starting the Samba service.
> 
> So, I followed VERY CAREFULLY the instructions in this webpage and it 
> ended up with a failure.

No you haven't got a failure, you now need to configure it and then 
start Samba:

If you are going to run Samba as the first AD DC in a domain, then you 
need to provision using samba-tool and the start the 'samba' binary.

If you are going to run Samba as an additional AD DC in a domain, then 
you need to join the domain using samba-tool and then start the 'samba' 
binary.

If you are going to run Samba as a Unix domain member, then you need to 
create a smb.conf file and then start the winbind & smbd binaries, you 
can also optionally start the nmbd binary

If you are going to run Samba as a standalone server, then you need to 
create a smb.conf file and then start the smbd binary and optionally the 
nmbd binary.

> (And, by the way, I also made a whole "tour" of the wiki which took me 
> quite some time.)

I have added a few lines to the page you linked to, but are you sure 
that there is nowhere else in the wiki that states you have to configure 
Samba before using it ?
If this is the case, you are the first person (that I am aware of) to 
have discovered it.

> 
> That's why I ended up trying to simply run "/usr/local/samba/sbin/samba",
> just in case I would have done something wrong when creating the systemd 
> unit file (and with systemctl) as I'm not familiar with it.
> 
> I am just trying to understand the "Samba system", as well as I can and 
> at my level, because you know, every time I have to deal with Samba, 
> like every two or three years, it's a mess, a nightmare.

It hasn't majorly changed for quite sometime, yes, things have been 
fixed, but it works pretty much as it did several years ago.

> In 2018, we worked for nearly a whole month together to fix my setup, if 
> you remember.
> But, no, you don't remember obviously, there are too many people you are 
> answering to here.

No, sorry, you are correct, I don't really remember.

> I know Samba is a free product but I really have tons of other things to 
> do for my work and I am not specialized in Samba, or AD.
> In 2020, Van Belle, helped me, it took a lot less time, a couple of days.
> But this year, I asked him for help directly and he didn't answer me 
> (which I understand by the way).
> 
> The way you are putting things is somehow unpleasant.

I am not trying to be unpleasant, but you are asking such basic things, 
especially as you say you have some experience of using Samba, which, by 
extension, probably means you also use other software and didn't you 
stop to think if you needed to do anything else before trying to run Samba ?

> You shouldn't take advantage of the fact you are among the people who 
> "know" things.

I am not trying to take advantage of anyone, In fact, I try to help. If 
I didn't want to help, do you think I would have spent all that time 
that you referred to earlier.

Lets start again.

Why are you trying to use 4.18.0 ?
By using a version of Samba that you compile Samba yourself, you have to 
manually control everything.
Whereas, if you use Samba from Debian backports, then most things are 
looked after for you and you will get pretty close to 4.18.0 (4.17.6 at 
present).

Once we find out just what you are attempting to achieve, then we can 
try to help you get there.

Rowland





More information about the samba mailing list