Red Hat Training
A Red Hat training course is available for RHEL 8
108.2. IdM クライアントでの Samba サーバーのインストールおよび設定
IdM ドメインに登録されたクライアントに Samba をインストールして設定できます。
前提条件
- IdM サーバーとクライアントの両方が RHEL 8.1 以降で実行されている必要がある。
- IdM ドメインは、ドメインメンバーに Samba をインストールするための IdM ドメインの準備 の説明に従って準備されます。
- IdM に AD で設定された信頼がある場合は、Kerberos の AES 暗号化タイプを有効にします。たとえば、グループポリシーオブジェクト (GPO) を使用して、AES 暗号化の種類を有効にします。詳細は、GPO を使用した Active Directory での AES 暗号化の有効化 を参照してください。
手順
ipa-client-samba
パッケージをインストールします。[root@idm_client]# yum install ipa-client-samba
ipa-client-samba
ユーティリティーを使用して、クライアントを準備し、初期 Samba 設定を作成します。[root@idm_client]# ipa-client-samba Searching for IPA server... IPA server: DNS discovery Chosen IPA master: idm_server.idm.example.com SMB principal to be created: cifs/idm_client.idm.example.com@IDM.EXAMPLE.COM NetBIOS name to be used: IDM_CLIENT Discovered domains to use: Domain name: idm.example.com NetBIOS name: IDM SID: S-1-5-21-525930803-952335037-206501584 ID range: 212000000 - 212199999 Domain name: ad.example.com NetBIOS name: AD SID: None ID range: 1918400000 - 1918599999 Continue to configure the system with these values? [no]: yes Samba domain member is configured. Please check configuration at /etc/samba/smb.conf and start smb and winbind services
デフォルトでは、
ipa-client-samba
は、ユーザーが接続したときにそのユーザーのホームディレクトリーを動的に共有するために、/etc/samba/smb.conf
ファイルに[homes]
セクションが自動的に追加されます。ユーザーがこのサーバーにホームディレクトリーがない場合、または共有したくない場合は、/etc/samba/smb.conf
から次の行を削除します。[homes] read only = no
ディレクトリーとプリンターを共有します。詳細は、次のセクションを参照してください。
ローカルファイアウォールで Samba クライアントに必要なポートを開きます。
[root@idm_client]# firewall-cmd --permanent --add-service=samba-client [root@idm_client]# firewall-cmd --reload
smb
サービスおよびwinbind
サービスを有効にして開始します。[root@idm_client]# systemctl enable --now smb winbind
検証手順
samba-client
パッケージがインストールされている別の IdM ドメインメンバーで次の検証手順を実行します。
Kerberos 認証を使用して、Samba サーバー上の共有をリスト表示します。
$
smbclient -L idm_client.idm.example.com -U user_name --use-kerberos=required
lp_load_ex: changing to config backend registry Sharename Type Comment --------- ---- ------- example Disk IPC$ IPC IPC Service (Samba 4.15.2) ...
関連情報
-
ipa-client-samba(1)
の man ページ