How to install Samba server on Ubuntu 12.04
Part 1: Configuring anonymous share with samba server
To install the samba package,enter the following command:
sudo apt-get install samba samba-common

Check the version of installed samba software by using this command:
smbd --version

Also install these suggested packages for samba:
sudo apt-get install python-glade2 system-config-samba

Go to your Windows machine and use this command in order to check the WORKGROUP name:
net config workstation

It will show the output, something like this:

Backup the smb.conf file, then delete it and create the new one:
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf.bak
sudo rm /etc/samba/smb.conf
sudo touch /etc/samba/smb.conf
sudo nano /etc/samba/smb.conf

Add this, in your smb.conf file (or change it according to your requirement):
#======================= Global Settings =====================================
[global]
workgroup = WORKGROUP
server string = Samba Server %v
netbios name = ubuntu
security = user
map to guest = bad user
dns proxy = no
#============================ Share Definitions ==============================
[MyShare]
path = /samba/share
browsable =yes
writable = yes
guest ok = yes
read only = no

Save the smb.conf file and restart the service:
sudo service smbd restart

Access the samba share from windows (where ubuntu is the name of my samba server):

wao, we are able to access the samba share successfully :-)

Let’s try to create something, inside the share folder:

Error, we cannot create anything inside the share folder :-(

Check the current permission on the samba share:
cd /samba/
ls -l

Change it, in such a way that everyone can read and write it(Check it, that it is allowed in your environment or not):
sudo chmod -R share
ls -l

Try to create something again, inside the share folder:

Verify the newly created file on samba server:
cd share/
ls -l

Part 2: Add and manage users and groups
Add a group in your ubuntu server (in my case smbgrp):
sudo addgroup smbgrp

Create a new share, set the permission on the share ,add the user to the samba group and create samba password:
cd /samba/
sudo chown -R arbab:smbgrp secure/
ls -l
sudo chmod -R secure/
ls -l
sudo adduser arbab smbgrp
sudo smbpasswd -a arbab

Add the newly created samba share in smb.conf file:
[secure]
path = /samba/secure
valid users = @smbgrp
guest ok = no
writable = yes
browsable = yes
create mask = 0777

Restart the samba service and check the syntax error with testparm:
sudo service smbd restart
sudo testparm

Testing from Windows Machine:



Verification from Ubuntu server:
cd /samba/secure/
ls -l

Hope this will help you!
Please Remember me in your prayers!
Source page from : http://rbgeek.wordpress.com/2012/04/25/how-to-install-samba-server-on-ubuntu-12-04/
How to install Samba server on Ubuntu 12.04的更多相关文章
- Install Asterisk 11 on Ubuntu 12.04 LTS
http://blogs.digium.com/2012/11/14/how-to-install-asterisk-11-on-ubuntu-12-4-lts/ Last week I put up ...
- install yael on the ubuntu 12.04
1. bits/predefs.h no such file or directory ??? sudo apt-get install gcc-multilib 2. sudo gedit /et ...
- Install eclipse ns3 in ubuntu 14.04
1. NS3 install 参考NS3 tutorial即可. 2.eclipse 2.1下载 下载地址:http://www.eclipse.org/downloads/ ...
- Ubuntu 12.04安装Adobe Reader
原本从Adobe 官方网站下载了 Adobe Reader, 是个rpm包,先用agt-get 装了rpm(sudo apt-get install rpm), 一安装(rpm -ivh AdobeR ...
- 【NS2】Installing ns-2.29 in Ubuntu 12.04
Installing ns-2.29 in Ubuntu 12.04 Off late, we try to use(install) a old software in a new Oper ...
- ubuntu 12.04 install docker-engine1.12.3
root@node3:/data/src# cat /etc/issueUbuntu 12.04.4 LTS \n \l root@node3:/data/src# cat /etc/apt/so ...
- 在Ubuntu 12.04安装和设置Samba实现网上邻居共享
转载:http://www.startos.com/ubuntu/tips/2012031333097.html 有微小改动. Samba 是一款功能强大的共享工具,可以实现与win ...
- OpenStack Havana 部署在Ubuntu 12.04 Server 【OVS+GRE】(三)——计算节点的安装
序:OpenStack Havana 部署在Ubuntu 12.04 Server [OVS+GRE] 计算节点: 1.准备结点 安装好ubuntu 12.04 Server 64bits后,进入ro ...
- OpenStack Havana 部署在Ubuntu 12.04 Server 【OVS+GRE】(二)——网络节点的安装
序:OpenStack Havana 部署在Ubuntu 12.04 Server [OVS+GRE] 网络节点: 1.安装前更新系统 安装好ubuntu 12.04 Server 64bits后,进 ...
随机推荐
- java中的向上转型
Person 可以表示为一个抽象的东西 就是人.比如说人可以唱歌, 就好比Person类中有一个sing方法.那么这个抽象的类(Person 人)可以具体到两类或者更多类 比如 男人,女人 .Man ...
- Kafka- Spark消费Kafka
在高版本的API中 val brokers = properties.getProperty("kafka.host.list") val topics = Set(propert ...
- webpack 教程资源目录
初级教程 webpack-howto 作者:Pete HuntWebpack 入门指迷 作者:题叶 webpack-demos 作者:ruanyf一小时包教会 —— webpack 入门指南 作者:V ...
- 仿联想商城laravel实战---3、前端页面搭建(什么情况下需要路由接参数)
仿联想商城laravel实战---3.前端页面搭建(什么情况下需要路由接参数) 一.总结 一句话总结: 比如访问课程的时候,不同的课程(比如云知梦),比如访问不同的商品,比如访问不同的分类 //商品详 ...
- R基础之批处理--R IN ACTION
1.5 批处理多数情况下,我们都会交互式地使用R:在提示符后输入命令,接着等待该命令的输出结果.偶尔,我们可能想要以一种重复的.标准化的.无人值守的方式执行某个R程序,例如,你可能需要每个月生成一次相 ...
- Linux配置redis服务器
1.安装redis 2.开启6379端口,使外部机器能够访问 3.
- MySQL常用方法
1.INSTR,例:INSTR(content,'\"SHOP_DES\"')>0,返回字符串在某一个字段的内容中第一次出现位置,没有为0 2.REPLACE,例:conte ...
- 机器学习(二十三)— L0、L1、L2正则化区别
1.概念 L0正则化的值是模型参数中非零参数的个数. L1正则化表示各个参数绝对值之和. L2正则化标识各个参数的平方的和的开方值. 2.问题 1)实现参数的稀疏有什么好处吗? 一个好处是可以简化 ...
- node.js+express+jade系列六:图片的上传
安装npm install formidable 先把文件上传到临时文件夹,再通过fs重命名移动到指定的目录即可 fs.rename即重命名,但是fs.rename不能夸磁盘移动文件,所以我们需要指定 ...
- Java之泛型浅解
我觉得学习一个东西,首先得从概念上明白它大概是什么? “泛型”就是“参数化类型”,也就是是把类型当成了一种参数.之前我们看到得函数方法比如: public long add(int num1,int ...