Sambaのインストール方法


Table of Contents

1 pdbedit

LinuxユーザアカウントとWindowsネットワーク認証のパスワードを設定するコマンドです。

Windowsログオン時のパスワードと同じパスワードにすることで、WindowsからSambaへのアクセス時のパスワード入力を省くことができます。

2 CentOS 7

$ sudo yum install -y samba$ sudo pdbedit -a -u hiroom2$ sudo systemctl enable nmb.service$ sudo systemctl enable smb.service$ sudo systemctl start nmb.service$ sudo systemctl start smb.service$ sudo firewall-cmd –add-service=samba –permanent$ sudo firewall-cmd –reload$ sudo setsebool -P samba_enable_home_dirs 1

3 Fedora 22

$ sudo dnf install -y samba$ sudo pdbedit -a -u hiroom2$ sudo systemctl enable nmb.service$ sudo systemctl enable smb.service$ sudo systemctl start nmb.service$ sudo systemctl start smb.service$ sudo firewall-cmd –add-service=samba –permanent$ sudo firewall-cmd –reload$ sudo setsebool -P samba_enable_home_dirs 1

4 Debian 8

$ sudo apt-get install -y samba$ sudo pdbedit -a -u hiroom2$ sudo systemctl enable nmbd.service$ sudo systemctl enable smbd.service$ sudo systemctl start nmbd.service$ sudo systemctl start smbd.service

5 Ubuntu 14.04

$ sudo apt-get install -y samba$ sudo pdbedit -a -u hiroom2$ sudo sed -i -e ‘s/;[homes]/[homes]/g’ /etc/samba/smb.conf$ sudo /etc/init.d/samba restart

Android | Linux | SDL - Narrow Escape