Can't enable samba service after update

Brief description of the problem

Can’t enable samba service after update

Detailed step by step instructions to reproduce the problem

  1. Install rockstor
  2. enable samba service
  3. create a pool
  4. active Stable updates
  5. update
  6. samba is stoped, try to enable it result in error

Web-UI screenshot

Error Traceback provided on the Web-UI

        Traceback (most recent call last):

File “/opt/rockstor/src/rockstor/smart_manager/views/samba_service.py”, line 114, in post
systemctl(‘smb’, command)
File “/opt/rockstor/src/rockstor/system/services.py”, line 64, in systemctl
return run_command([SYSTEMCTL_BIN, switch, service_name])
File “/opt/rockstor/src/rockstor/system/osi.py”, line 121, in run_command
raise CommandException(cmd, out, err, rc)
CommandException: Error running a command. cmd = /usr/bin/systemctl start smb. rc = 1. stdout = [‘’]. stderr = [‘Job for smb.service failed because the control process exited with error code. See “systemctl status smb.service” and “journalctl -xe” for details.’, ‘’]

result from systemctl status smb:

● smb.service - Samba SMB Daemon
Loaded: loaded (/etc/systemd/system/smb.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Tue 2018-08-21 01:50:49 PDT; 4min 40s ago
Process: 6350 ExecStart=/usr/sbin/smbd $SMBDOPTIONS (code=exited, status=255)
Main PID: 6350 (code=exited, status=255)
Status: “Starting process…”

Aug 21 01:50:48 gx systemd[1]: Starting Samba SMB Daemon…
Aug 21 01:50:49 gx smbd[6350]: [2018/08/21 01:50:49.061822, 0] …/source3/auth/auth_util.c:1399(make_new_session_info_guest)
Aug 21 01:50:49 gx smbd[6350]: create_local_token failed: NT_STATUS_NO_MEMORY
Aug 21 01:50:49 gx smbd[6350]: [2018/08/21 01:50:49.063081, 0] …/source3/smbd/server.c:2011(main)
Aug 21 01:50:49 gx smbd[6350]: ERROR: failed to setup guest info.
Aug 21 01:50:49 gx systemd[1]: smb.service: main process exited, code=exited, status=255/n/a
Aug 21 01:50:49 gx systemd[1]: Failed to start Samba SMB Daemon.
Aug 21 01:50:49 gx systemd[1]: Unit smb.service entered failed state.
Aug 21 01:50:49 gx systemd[1]: smb.service failed.

@FRXDQ A very very belated welcome to the Rockstor community, and thanks for helping to support Rockstor’s development via a stable subscription.

To try and narrow down what’s happened here (nice report by the way) could you paste the output from the following commands:

yum info rockstor

and

yum update

It may be that you have a part-way update of the base CentOS system, we have seen this a number of times and it could be why you have such a strange Samba failure:

result of yum info rockstor
info

result of yum update

@FRXDQ Great, so it’s not another failed update; that’s good.

Could you try a reboot as it may just be an old library still in play? Though it seems unlikely but worth a try.

Also could you give the machine’s specification, ie how much memory does this machine have for example?

I have tried reboot it, same result.
The machine is an old ibm x3550 Type 7978 server with intel Xeon 5120 CPU and 4GB of ram.

@FRXDQ Ok thank.

Unfortunately nothing else spring to mind. Have you made any manual additions to the smb.conf?

Are their any other forum members who have seen this particular failure, ie the same log entry as is reported by @FRXDQ.

It might be worth doing a general CentOS search on this issue as we do nothing more than control the smb.conf content. Our samba packages are essentially vanilla CentOS so they should work independently of the rockstor code anyway. Let us know how you get on and if you find any more pointers.

Hope that helps.

I think i find it. There are some active directory config in smb.conf prevent samba from starting. I think it’s from failed attemps to join the domain in web ui after install.

But i have a new problem, It can’t join domain. When click the status toggle after config active directory service i end up whith error.

Web-UI screenshot

Error Traceback provided on the Web-UI
Traceback (most recent call last):
File “/opt/rockstor/src/rockstor/rest_framework_custom/generic_view.py”, line 41, in _handle_exception
yield
File “/opt/rockstor/src/rockstor/smart_manager/views/active_directory.py”, line 227, in post
self._join_domain(config, method=method)
File “/opt/rockstor/src/rockstor/smart_manager/views/active_directory.py”, line 78, in _join_domain
return run_command(cmd, input=(‘%s\n’ % config.get(‘password’)))
File “/opt/rockstor/src/rockstor/system/osi.py”, line 121, in run_command
raise CommandException(cmd, out, err, rc)
CommandException: Error running a command. cmd = /usr/bin/net ads join -U ctrlyare. rc = 255. stdout = [“Enter ctrlyare’s password:”, ‘Failed to join domain: Invalid configuration (“workgroup” set to 'WORKGROUP', should be 'HZKY') and configuration modification was not requested’, ‘’]. stderr = [‘’]

i think
"workgroup" set to \'WORKGROUP\'
part is obviously wrong but i can’t find the way to config it.

This is the same error i encounter after install. Which feels like some error in web ui, so i stop at that and do the update. But it still didn’t work.