[Eisfair] (Dringende) SAMBA-Frage

Uwe Kunze u.kunze.sdh at t-online.de
So Aug 30 19:12:31 CEST 2020


> Jetzt das Problem ... die SAMBA-User :-(

Hab grad einen Thread von 2018 gefunden, in dem Thomas das 
install-Script des Samba-Paketes beschreibt .... damit probiere ich es.

> # only do this, if smbpasswd is not empty
> if [ -s "$smbpasswdfile" ]
> then
> /var/install/bin/backup-file "$smbpasswdfile" sic
>
> if ! [ -f "$tdbsamfile" ]
> then
> echo "Converting smbpasswd to tdbsam and removing irregular
> samba users ..."
> smbpasswdimportfile='/tmp/smbpasswd.import'
> rm -f $smbpasswdimportfile
>
> while read smbpasswdline
> do
> userline=`echo "$smbpasswdline" | grep -v ']:LCT-00000000:'
> | grep -v '^eis:0:' | grep -v '^halt:0:' | grep -v '^reboot:0:'`
> if [ -n "$userline" ]
> then
> #echo "$userline"
> echo "$userline" > $smbpasswdimportfile
> /usr/bin/pdbedit -i smbpasswd:$smbpasswdimportfile -e
> tdbsam:/etc/passdb.tdb
> rm -f $smbpasswdimportfile
> fi
> done < $smbpasswdfile
> fi
> fi
>
> # remove old /etc/smbpasswd but keep /etc/smbpasswd.sic
> rm -f "$smbpasswdfile"

Gruß Uwe


Mehr Informationen über die Mailingliste Eisfair