KONFIGURASI SAMBA SEBAGAI PDC
Tekan Alt+F2
Ketikkan : gnome terminal/xterm
Kemudian install dengan perintah berikut :
$sudo apt-get install winbind
Ketikan :
# gedit /etc/samba/smb.conf
Kemudian copy kode berikut :
[global]
Workgroup=jaringanlinux
Netbios name = ubuntuserver
Server string = %h server (samba,ubuntu)
Passdb backend = tdbsam
Security = user
Username map = /etc/samba/smbusers
Nama resolve order = wins bcast hosts
Domain logons = yes
Preferred master = yes
Wins support = yes
# Useradd scripts
Add user script = /user/sbin/useradd -m %u
Delete user script = /user/sbin/userdel -r%u
Add group script = /user/sbin/groupadd %g
Delete group script = / user/sbin/groupadel %g
Add user to group script = user/sbin/usermod -G %g %u
Add machine script = /user/sbin/useradd -s /bin/false/ -d /var/lib/nobody %u
Idmap uid = 15000-20000
Idmap gid = 15000-20000
# sync smb passwords woth linux passwords
passwd prngram = /usr/bin/passwd %u
passwd chat = *Enter\snew\sUNIX/spassword:* %n\n *Retype\snew\sUNIX\spassword:* %n\n.
passwd chat debug = yes
unix password sync = yes
#set the loglevel
log level = 3
[homes]
comment = Home
valid users = %S
read only = no
browsable = no
[netlogon]
comment = Network Logon Service
path = /home/samba/netlogon
admin users = Administrator
valid users = %U
read only = no
[profile]
comment = User profiles
path = /home/samba/profiles
valid users = %U
create mode = 0600
directory mode = 0700
writable = yes
browsable = no
sesudah itu save file dan buat directory samba di home dan directory netlogon dan profiles.
/var/spool/samba
buat dengan printah :
mkdir /home/samba
mkdir /home/samba/netlogon
mkdir /home/samba/profiles
mkdir /var/spool/samba
kemudian berikan atribut ke folder tersebut :
chmod 777 /var/spool/samba/
chown -R root:users /home/samba/
chmod -R 771 /home/samba/
kemudian ketikkan :
# gedit /etc/nsswitch.conf
# gedit /etc/hosts
buat password root untuk samba dan harus berbeda dengan password root linux.
smbpasswd -a root
New SMB password: [masukkan password]
Retype new SMB password: [masukkan password]
ketikkan :
/etc/samba/smbusers
isikan dengan teks "root=Administrator" :
#echo "root = Administrator" > /etc/samba/smbusers
kemudian setting domain group windows dengan printah berikut :
#net groupmap add ntgroup="Domain Admins" unixgroup=root
#net groupmap add ntgroup="Domain Users" unixgroup=users
#net groupmap add ntgroup="Domain Guests" unixgroup=nogroup
sekarang tambahkan user non root yg akan digunakan untuk mengakses PDC.
Ketikkan perintah :
useradd pengguna -m -G users
New SMB password: [masukkan password]
Retype nex SMB password: [masukkan password]
lalu anda harus membuat direktory yg dpt di akses semua urer dan mengganti ownership dengan printah chown dan atribut dengan chmod dengan perintah berikut :
mkdir -p /home/shares/allusers
chown -R root:users /home/shares/allusers
chmod -R ug+rwx,o+rx-w /home/shares/allusers
gedit /etc/samba/smb.conf
copy kode berikut :
[allusers]
commanet = All Users
path = /home/shares/allusers
valid users = @users
fosce group = users
create mask = 0660
directory mask = 0771
writable = yes
save kemudian restart :
# /etc/init.d/samba restart
untuk mengujinya ketikan :
# smbclient -L localhost -U%
Tidak ada komentar:
Posting Komentar