메뉴 건너뛰기

2014.02.27 12:06

SAMBA 설치

조회 수 7315 추천 수 0 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
1. 삼바 설치 확인
[root@localhost ~]# rpm -qa | grep samba
system-config-samba-1.2.39-1.el5
samba-3.0.28-0.el5.8
samba-client-3.0.28-0.el5.8
samba-common-3.0.28-0.el5.8

설치되어 있지 않을 경우
[root@localhost ~]# yum install -y samba


2. 삼바 환경설정
삼바 환경설정 파일인 smb.conf 파일 수정

[root@localhost ~]# cd /etc/samba
[root@localhost samba]# vi smb.conf

# ----------------------- Network Related Options -------------------------
#
# workgroup = Workgroup
#
# server string is the equivalent of the NT Description field
#
# netbios name can be used to specify a server name not tied to the hostname
#
# Interfaces lets you configure Samba to use multiple interfaces
# If you have multiple network interfaces then you can list the ones
# you want to listen on (never omit localhost)
#
# Hosts Allow/Hosts Deny lets you restrict who can connect, and you can
# specifiy it as a per share option as well
#

unix charset = cp949
dos charset = cp949
display charset = cp949

리눅스와 윈도우즈간의 언어셋 설정.

workgroup = MYGROUP
윈도우즈의 작업그룹명. ip 대역으로 접속시에는 아무거나 해도 상관없다.
server string = Samba Server Version %v
윈도우즈에서 접속시에 보여지는 서버이름.
네트워크 드라이브로 연결시에는 위의 서버명과 디렉토리명이 같이 표시되기 때문에 적절히 수정.

; netbios name = local_CentOS

; interfaces = lo eth0 192.168.1.2/24 192.168.2.13/24
hosts allow = 192.168.1.5 123.45.6.
삼바서버에 접속할 수 있는 클라이언트 IP 대역 설정.
(위의 경우 192.168.1.5 IP와 123.45.6. IP 대역에 대해 접속을 허용)


# ----------------------- Standalone Server Options ------------------------
#
# Security can be set to user, share(deprecated) or server(deprecated)
#
# Backend to store user information in. New installations should
# use either tdbsam or ldapsam. smbpasswd is available for backwards
# compatibility. tdbsam requires no further configuration.

security = user
passdb backend = tdbsam
security = share (삼바서버에 사용자명/패스워드 인증없이 접속 가능)
security = user (리눅스 계정 아이디로 접속 가능)
user로 설정했을 경우, 환경설정 저장 후 리눅스 계정 패스워드와는 별도로 삼바서버에 패스워드를 등록해야 한다.


#============================ Share Definitions ==============================

[homes]
comment = Home Directories
browseable = no
writable = yes
; valid users = %S
; valid users = MYDOMAIN%S

삼바서버에 로그인한 사용자의 홈디렉토리 설정.
security = user로 설정되어 있을 경우, 로그인한 사용자의 디렉토리가 표시된다.

[test1_share]
comment = test1_share
path = /home/test
writable = yes
valid users = test1


로그인한 사용자에게 홈디렉토리 이외에 공유할 디렉토리를 설정해줄 수 있다.
위의 경우, "test1" 사용자에게 자신의 디렉토리 이외에 "/home/test" 디렉토리도 공유할 수 있게 해준다.

3. 삼바 서비스 시작
[root@localhost samba]# service smb start
SMB서비스를 시작 중: [ OK ]
NMB서비스를 시작 중: [ OK ]

4. 윈도우즈에서 삼바 접속
시작 > 실행 > \삼바 서버 IP

5. 삼바 서버에서 사용할 계정 패스워드 설정
[root@localhost samba]# smbpasswd -a test1
New SMB password:
Retype new SMB password:
Added user test1.

smbpasswd -a test1 : test1 사용자의 삼바용 패스워드 추가
smbpasswd -x test1 : test1 사용자의 삼바 계정 삭제
smbpasswd -d test1 : test1 사용자의 삼바 계정을 사용중지

List of Articles
번호 제목 날짜 조회 수
236 확장자가 없는 파일 자동인식하는 mod_mime_magic 2016.03.18 9313
235 하루동안 실행된 쿼리 중 수행시간이 가장 긴 조회 쿼리 100개 2017.04.28 8042
234 하드디스크의 속도와 성능테스트강좌 hdparm 2014.02.27 7471
233 하드디스크 배드블록 점검 툴 - badblocks 2016.03.18 8808
232 포그라운드, 백그라운드, nohup 정리 2017.04.18 9043
231 파일 속성 명령어 : chattr, lsattr 2014.02.27 9614
230 특정 웹페이지에서 문자가 깨지는 경우 (인코딩 문제) 2016.03.18 7553
229 특정 데몬의 메모리 점유율 확인하기 2014.02.27 8051
228 컴파일을 이용하여 Apache 최신버전을 설치하자 2016.03.18 7632
227 재지향시 유의사항 (grep 재지향) 2021.03.26 174
226 작업 예약 스케줄러(크론Cron)파일,자동 백업 명령 file 2023.01.12 129
225 인코딩 깨진한글파일 삭제 방법 file 2016.07.22 8955
224 이온큐브로더(ioncube) 설치 매뉴얼 2016.03.18 10382
223 이미지 및 파일 무단링크 방지책 2019.02.14 1137
222 웹호스팅용 리눅스 서버 셋팅 file 2014.03.26 7940
221 웹호스팅용 리눅스 서버 셋팅 file 2014.02.27 7735
220 웹서버(Nginx+FastCGI PHP)구축 및 성능 시험 2017.09.20 5530
219 웹서버 모니터링 툴 awststs 2014.03.26 10235
218 웹로직 서버 시작 및 종료 스크립트 2017.04.28 8465
217 웹로직 + 아파치 연동 2017.04.13 8683
Board Pagination Prev 1 2 3 4 5 6 7 8 9 10 ... 12 Next
/ 12

하단 정보를 입력할 수 있습니다

© k2s0o1d4e0s2i1g5n. All Rights Reserved