linux samba服务
来源:互联网 发布:微博短文情感数据集 编辑:程序博客网 时间:2024/05/16 01:26
If you want to share files between your Ubuntu and Windows computers, your best option is to use Samba file sharing. To install, first open a terminal window and enter the following command: sudo apt-get install samba smbfs We’ve got samba installed, but now we’ll need to configure it to make it accessible. Run the following command to open the configuration file, substituting your editor of choice: sudo gedit /etc/samba/smb.conf Find this section in the file: ####### Authentication ####### # “security = user” is always a good idea. This will require a Unix account Uncomment the security line, and add another line to make it look like this: security = user This will set Samba to use the smbusers file for looking up the user list. Create a Samba User There are two steps to creating a user. First we’ll run the smbpasswd utility to create a samba password for the user. sudo smbpasswd -a <username> Next, we’ll add that username to the smbusers file. sudo gedit /etc/samba/smbusers Add in the following line, substituting the username with the one you want to give access to. The format is <ubuntuusername> = “<samba username>”. You can use a different samba user name to map to an ubuntu account, but that’s not really necessary right now. <username> = “<username>” Now you can create samba shares and give access to the users that you listed here.
# in this server for every user accessing the server. See
# /usr/share/doc/samba-doc/htmldocs/Samba-HOWTO-Collection/ServerType.html
# in the samba-doc package for details.
; security = user
username map = /etc/samba/smbusers
Samba Server allows you to share the home directories of users automatically. This can be useful so that you don’t have to manually create every share for every user. First, make sure that you’ve installed Samba server. To share the home directories, open up smb.conf with the following command: sudo gedit /etc/samba/smb.conf Find this section of the file, and make it match the following: #======================= Share Definitions ======================= # Un-comment the following (and tweak the other settings below to suit) # By default, //server/username shares can be connected to by anyone # By default, the home directories are exported read-only. Change next Now you should be able to map a drive on windows using the following share format: //ubuntumachine/username For example, if the Ubuntu machine is named ubuntuserv, and the username is geek, your share path would be //ubuntuserv/geek 上面的话在windows上已经将samba服务启动起来了,那么如何在windows上访问这个samba服务呢?起始很简单直接在”运行“下输入//ip_address就可以了。
# to enable the default home directory shares. This will share each
# user’s home directory as //server/username
[homes]
comment = Home Directories
browseable = yes
# with access to the samba server. Un-comment the following parameter
# to make sure that only “username” can connect to //server/username
valid users = %S
# parameter to ‘yes’ if you want to be able to write to them.
writable = yes
- linux samba服务
- Linux samba服务 PAM
- linux 配置samba服务
- linux Samba服务配置
- linux添加samba服务
- LINUX-SAMBA服务配置
- linux Samba服务配置
- linux-samba服务搭建
- Linux配置Samba服务
- Linux 配置samba 服务
- Linux安装samba服务
- Linux-samba服务
- Linux-samba服务
- Linux Samba服务配置
- linux samba服务
- linux安装Samba服务
- Linux系统samba服务
- linux samba服务
- 构造对象数组
- 给ATL控件添加安全接口
- 史上最全的C位域总结(转)
- 管理者的三层境界- 管事、管人、管组织
- 基于Servlet3.0规范的一个HelloWorld
- linux samba服务
- UIMA架构简介
- 已知线段各点经纬度,判断线段相交函数
- #include和#include" "搜索路径的区别。
- jsp出现getOutputStream() has already been called for this response异常的原因和解决方法
- 对系统进程的一些操作!
- 堆 栈 字符数组 字符指针的区别
- Sql语句批量插入(转载)
- 市场部