본문 바로가기

728x90

전체 글

[Apache] 아파치 버전정보 노출 막기 아파치 버전정보 노출 막기 # # ServerTokens # This directive configures what you return as the Server HTTP response # Header. The default is 'Full' which sends information about the OS-Type # and compiled in modules. # Set to one of: Full | OS | Minor | Minimal | Major | Prod # where Full conveys the most information, and Prod the least. # ServerTokens Prod => 주석 처리 #ServerTokens Prod # # Optionally add a l.. 더보기
[MySQL] mysql max_allowed_packet 설정 mysql max_allowed_packet 설정 WARNING: The user you typed does not seem to be root If you encounter any problem with files insertion, try setting the global max_allowed_packet MySQL value to at least 2MB in your server config file. [root@itms bin]# mysql -u root -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 3 Server version: 5.1.69 Source d.. 더보기
zip 명령어, unzip 명령어 zip 명령어, unzip 명령어 zip과 unzip은 유닉스(리눅스) 시스템에서 사용되는 명령어로, 파일들을 압축하거나 해제하는데 사용됩니다. zip 명령어의 기본 구문 zip [옵션] [압축 파일명] [파일 또는 디렉토리] unzip 명령어의 기본 구문 unzip [압축 파일명] 주요 옵션 -r: 디렉토리를 재귀적으로 압축 또는 해제 -d: 압축을 해제할 디렉토리 지정 -v: 상세 정보 출력 -q: 출력을 덜 자세하게 -l: 압축 파일의 내용 목록 출력 사용 예시 파일들을 archive.zip으로 압축 zip archive.zip file1.txt file2.txt dir/ archive.zip: 새로운 압축 파일의 이름 file1.txt, file2.txt: 압축할 파일들 dir/: 압축할 디렉토리.. 더보기
SSL 인증서의 개인키에 설정된 비밀번호를 제거하는 방법 SSL 인증서의 개인키에 설정된 비밀번호를 제거하는 방법 1. OpenSSL을 사용하여 SSL 인증서(crt)와 개인 키(key)를 생성하는 방법 openssl req -subj '/CN=sangchul.kr/O=Infrastructure Team/C=KR' -new -newkey rsa:2048 -sha256 -days 365 -nodes -x509 -keyout node1.key -out node1.crt $ openssl req -subj '/CN=sangchul.kr/O=Infrastructure Team/C=KR' -new -newkey rsa:2048 -sha256 -days 365 -nodes -x509 -keyout node1.key -out node1.crt ...+.............. 더보기
[리눅스] CentOS에서 mcrypt 설치방법 CentOS에서 mcrypt 설치방법 Error MSG : phpmyadmin에서 위와 같은 에러 메세지가 뜰경우 아래와 같은 명령어를 치면된다. # rpm -ivh http://www.mirrorservice.org/sites/dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm http://www.mirrorservice.org/sites/dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm(을)를 복구합니다 경고: /var/tmp/rpm-tmp.AOaGFC: Header V3 RSA/SHA256 Signature, key ID 0608b895: NOKEY 준비 중..... 더보기
CentOS에서 EPEL 저장소를 사용하기 CentOS에서 EPEL 저장소를 사용하기 1. EPEL 릴리스 패키지 설치 CentOS 시스템에서 EPEL 저장소를 사용하려면 먼저 EPEL 릴리스 패키지를 설치해야 합니다. sudo yum install epel-release 2. EPEL 저장소 활성화 EPEL 저장소는 이제 설치되었지만, 기본적으로 비활성화 상태입니다. 활성화하기 위해 EPEL 저장소 구성 파일을 편집합니다. 편집기를 사용하여 파일을 열고 enabled=1로 설정합니다. sudo vim /etc/yum.repos.d/epel.repo 또는 vim, vi, 또는 다른 원하는 편집기를 사용할 수 있습니다. EPEL 저장소의 [epel] 섹션을 열어 enabled=1로 설정합니다. 파일은 아래와 비슷한 내용을 가져야 합니다. [epel.. 더보기
vim 문자 치환 vim 문자 치환 test 파일 생성 vim test www.naver.com www.yahoo.co.kr 중복 제거 및 내림차순 정렬 sort -u test > test2 test2 파일 생성 www.naver.com/cafe를 www.naver.com으로 치환 vim test2 www.naver.com/cafe 대문자를 소문자로 치환 :%s/.*/\L&/g 앞 :%s/^/ host-control"/g 뒤 :%s/$/ " 11.11.11.11;"/g 더보기
FTP를 사용하여 파일을 업로드하는 스크립트 FTP를 사용하여 파일을 업로드하는 스크립트 ftp.sh 스크립트 작성 vim ftp.sh #!/bin/bash # 현재 날짜를 YYYYMMDD 형식으로 저장 DATE=$(date -d today +%Y%m%d) # 동기화할 서버 목록을 변수에 저장 SERVER_LIST=" relay2.scbyun.com #relay3.scbyun.com relay4.scbyun.com relay5.scbyun.com relay6.scbyun.com relay7.scbyun.com relay8.scbyun.com relay9.scbyun.com relay10.scbyun.com " # FTP 계정 정보 설정 USER='xman' PASSWD='dusrnth2001' # 동기화할 파일 패턴 설정 FILE="$DATE*.l.. 더보기

728x90
반응형