setup and test samba server
Configuration
/etc/samba/smb.conf You knew it. Only security and [homes] are not default, the others are default. In this configuration, all the \\server\\username can be accessed.
[global] workgroup = WORKGROUP server string = %h server (Samba, Ubuntu) dns proxy = no log file = /var/log/samba/log.%m max log size = 1000 syslog = 0 panic action = /usr/share/samba/panic-action %d security = user encrypt passwords = true passdb backend = tdbsam obey pam restrictions = yes unix password sync = yes passwd program = /usr/bin/passwd %u passwd chat = *Enter\snew\s*\spassword:* %n\n *Retype\snew\s*\spassword:* %n\n *password\supdated\ssuccessfully* . pam password change = yes map to guest = bad user [homes] comment = %U Home Directories browseable = Yes read only = no create mask = 0660 directory mask = 0700 valid users = %SFor other user(not the user created during the OS installation but created with user add)
We still need to sudo smbpasswd -a <username>
Could we use unix user dirctly?
Show smbpwd users
$ sudo pdbedit -Lw
Test samba
Linux command line
smbclient -L <IP> -U guest -N #list
smbclient -L <IP> -U <username> #list
smbclient \\<IP>\<username> -U <username> # login
Mount for current user
sudo apt-get install cifs-utils
sudo mount.cifs -o username=<samba username>,uid=${USER} //<samba server>/directory/ /<local directory>
Windows
You may get 'Multiple connections' or 'disconnect previous connections' error in windows
rem list the connections
net use
rem remove all the connections
net use * /delete
usershare
Allow non-root/sudoers to create shares
相關文章
- SetUp a Secure Ubuntu Server[轉]UbuntuServer
- Team Foundation Server 2005 (Chs) Setup Step by StepServer
- SQL Server 2005 Developer Edition English Version Setup on Windows 7SQLServerDeveloperWindows
- Sql Server Linux(Redhat) Distributed Availability Group Setup — step by stepSQLServerLinuxRedhatAI
- setup types & setup standard operation(BOM>Rountings)
- MuseMail SetupAI
- test
- Oracle Audit setupOracle
- SETUP(安裝)
- oracle dataguard setupOracle
- Vue 3 setupVue
- samba安裝Samba
- webservice testWeb
- test_NO
- .單機版samba設定 /etc/samba/smb.confSamba
- linux samba配置檔案/etc/samba/smb.confLinuxSamba
- Lubuntu Setup for ProgrammingUbuntu
- ubuntu設定sambaUbuntuSamba
- samba共享檔案Samba
- Linux samba 配置LinuxSamba
- How to Setup DG4MSQL (Oracle Database Gateway for MS SQL Server) Release 11 on Linux [轉帖]SQLOracleDatabaseGatewayServerLinux
- 【Android Test】糟心的“Empty test suite ”異常AndroidUI
- Shell test 命令
- JavaScript test() 方法JavaScript
- Spring testSpring
- ACM Coin TestACM
- partition table test
- Test Generation frameworkFramework
- test1
- test日記
- Setup python virtual environmentPython
- Quickly setup a stream environment.UI
- oracle linux yum setupOracleLinux
- Setup – Profile Options – OA FrameworkFramework
- jive setup tips (轉)
- 使用Samba共享檔案Samba
- samba,nfs安裝使用SambaNFS
- Samba Install in linuxSambaLinux