Skip to main content

LDAP구성-3. SAMBA구성해서 연동하기

Samba서버와 LDAP연동하기 – LDAP서버에서 작업

  1. 패키지 설치
    $> yum insall -y samba samba-devel
  2. samba설정 적용
    $> vi /etc/samba/smb.conf 내용 추가
    ...
    security = user
    ldap admin dn = cn=Manager,dc=my-domain,dc=com
    ldap suffix = dc=my-domain,dc=com
    ldap group suffix = ou=groups
    ldap user suffix = ou=people
    ldap passwd sync = yes
    ldap delete dn = Yes
    domain logons = yes
  3. LDAP과 samba연동
    $> vi  /etc/openldap/slapd.conf
    ...
    include /etc/openldap/schema/samba.schema
    access to attrs=userPassword,sambaLMPassword,smabaNTPassword,shadowLastChange
    by dn.children="ou=Manager,dc=my-domain,dc=com" write
    by self write
    by anonymous auth
    by * none
    access to *
    by dn.children="ou=Manager,dc=my-domain,dc=com" write
    by * read
  4. ldap admin 패스워드 설정
    $> smbpasswd -w
  5. LDAP사용자 samba 패스워드 설정
    $> smbpasswd -a test
    $> New SMB password:
    $> Retype new SMB password:
  6. 서비스 시작 및 활성화
    $> /etc/init.d/smb start
    $> chkconfig smb on
  7. samba 클라이언트 접속 테스트
    $> smbclient -U test //192.168.10.10/home
    • 윈도우 장비에서 네트워크 공유폴더를 통해 접근 여부 확인