CentOS & RHEL 최소 설정
기본
PRE. 파티션 분리 및 기본 디렉토리 생성(/server, /web-source 또는 /app-source, /logs, -DB-/data)
계정생성 및 리눅스 환경 확인
- 한글확인 : locale (ko_KR.UTF-8)
- KST 확인 (ls /usr/share/zoneinfo/Asia/Seoul –> ln -sf /usr/share/zoneinfo/Asia/Seoul /etc/localtime)
- root 및 신규계정 패스워드 변경
- 번들로 설치된 httpd, mysql, svn 제거 (yum remove)
- Package 설치
- sudo 권한이 필요한 관리 계정인 경우: wheel 그룹에 계정 그룹(/etc/group)을 추가 후 다음을 실행 또는 직접 계정 추가 – 개발서버만 할 것
- iptables disable : vhost web 서버일 경우는 on
hostname 재설정 (hostname, /etc/hosts, /etc/sysconfig/network) : 딱히 정해진 Rule은 없지만 대부분
“회사(Shortcut) + H(HTTPD)/W(WAS)/D(DB, Cache) + 시스템 + [글로벌일 경우 Region] + D(개발)/P(운영) + 일련번호”
- API Service WAS-개발: HSWAPISVCD01
- API Service DB-운영 : HSDAPISVCP01
logroatated 설정 (선택사항)
/etc/logrotate.conf
NTP 설정 (/etc/ntp.conf)
설정 확인됬으면
FTP 설정(no guest) 및 불필요 계정 삭제
Limit ‘su’ command (/etc/pam.d/su) 주석제거
(선택사항) root 계정 login 막을려면
/etc/ssh/sshd_config 파일의 ‘PermitRootLogin no’ 수정 후,
계정별 기본 설정
profile 기본 설정 (/etc/profile)
(JDK 설치 서버)
(MariaDB 설치 서버)
ulimit 환경 수정 (/etc/security/limits.conf)
작업전에 아래의 설정 존재여부 확인 후, 없으면 추가
/etc/pam.d/login
/etc/pam.d/sshd
/etc/security/limits.conf
System 커널 수정 (/etc/sysctl.conf –> sysctl -p)
기타
/etc/rc.d