Installing Samba on Ubuntu

20:06 0 Comments

Installing Samba on Ubuntu


ขั้นตอนการลง Samba.
#sudo apt-get update

 install samba
#sudo apt-get install samba

แก้ไขไฟล์  configuration ของ samba
#cd /etc/samba/

backup ไฟล์  configuration ไว้ก่อน
#sudo mv smb.conf backsmb.conf

ขั้นตอนการสร้างโฟลเดอร์ที่ต้องการแชร์
สร้างไฟล์ configuration สำหรับแชร์โฟลเดอร์ให้ทุกคนสามารถเข้าใช้งานได้
#sudo nano smb.conf
เพิ่มโค้ดข้างล่างนี้เข้าไปในไฟล์ smb.conf
#
[global]
workgroup = Workgroup
server string = My Samba Share %v
security = user
map to guest = bad user
dns proxy = no
#
[ShareFolder]
comment = This is a folder accessible from everyone
path = /sharefolder
browsable = yes
guest ok = yes
read only = no
create mask = 0755
สร้างโฟลเดอร์ไว้ที่เครื่องที่เราต้องการแชร์และเปลี่ยนสิทธิ์การเข้าถึงโฟลเดอร์
#sudo mkdir /sharefolder
#sudo chown -R nobody:nogroup /sharefolder/
#sudo chmod 755 /sharefolder/

ทำการ restart service samba 
#sudo /etc/init.d/smbd restart

slow life :: KUL

Some say he’s half man half fish, others say he’s more of a seventy/thirty split. Either way he’s a fishy bastard. Google

0 Comments: