[Samba] leaving a domain?

Michael Tokarev mjt at tls.msk.ru
Thu Jun 20 12:03:25 UTC 2024


Hi!

I joined a newly installed samba (4.20.1) server to a domain, - just testing
things.  Now I want to remove this test server from a domain, but I can't:


root at svdcm2:/# samba-tool domain leave -U tls\\mjt-adm
WARNING: Using passwords on command line is insecure. Installing the setproctitle python module will hide these from shortly after program start.
Password for [TLS\mjt-adm]:
ERROR(<class 'SystemError'>): uncaught exception - <method 'leave' of 'net_s3.Net' objects> returned a result with an exception set
   File "/usr/lib/python3/dist-packages/samba/netcmd/__init__.py", line 285, in _run
     return self.run(*args, **kwargs)
            ^^^^^^^^^^^^^^^^^^^^^^^^^
   File "/usr/lib/python3/dist-packages/samba/netcmd/domain/leave.py", line 59, in run
     s3_net.leave(keep_account)

(all tools also display this out-of-context warning about using passwords on command line,
which I don't do).

How to remove this machine from a domain?

Thanks,

/mjt

-- 
GPG Key transition (from rsa2048 to rsa4096) since 2024-04-24.
New key: rsa4096/61AD3D98ECDF2C8E  9D8B E14E 3F2A 9DD7 9199  28F1 61AD 3D98 ECDF 2C8E
Old key: rsa2048/457CE0A0804465C5  6EE1 95D1 886E 8FFB 810D  4324 457C E0A0 8044 65C5
Transition statement: http://www.corpit.ru/mjt/gpg-transition-2024.txt



More information about the samba mailing list