[Solved] How to restart samba server?

Sorry this is a little embarassing but I’m trying to set up my own server for the first time. I found great tutorial online.

http://www.intac.net/build-your-own-server/

I’m stuck at the 2nd to last line of step 4.

Apparently there is no samba directory in init.d.

Why isn’t there a samba directory in init.d?

Would the following work?

# sudo restart smbd
# sudo restart nmdb
Solution #1:

Start

sudo service smbd start

Stop

sudo service smbd stop

Restart

sudo service smbd restart
Respondent: Bruno Pereira
Solution #2:

You can also do this way:

Start

sudo /etc/init.d/smbd start

Stop

sudo /etc/init.d/smbd stop

Restart

sudo /etc/init.d/smbd restart

If you got an error, try using these commends this nmbd instead.

Respondent: One Zero
Solution #3:

Starting with 15.04 and systemd, the command is systemctl restart smbd

Respondent: mirh
Solution #4:

you may also try this :

check the name of the service:

service --status-all

restart the service

sudo service samba restart
Respondent: derdonn
Solution #5:

On RHEL you start smb and nmb:

systemctl start smb
systemctl start nmb

Next, check if they started:

ps -elf | grep smbd
ps -elf | grep nmbd
Respondent: Darrin
The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .

Leave a Reply

Your email address will not be published.