728x90
# cp index.html index2.html
index.html 파일을 index2.html 파일로 복사한다.
# grep adm /etc/passwd
adb:x:3:4:adm:/var/adm:/sbin/nologin
/etc 아래 내 passwd 파일에서 adm이라는 text를 찾아 보여줘라.
파일에 특정 패턴을 찾아내는 명령어
# ps -ef | grep httpd
daemon 7667 25307 0 May 04? 00:00:00 /usr/local/apache2/bin/httpd -k start
daemon 9264 25307 0 Apr 25? 00:00:02 /usr/local/apache2/bin/httpd -k start
특정 프로세스(httpd)의 상태 정보를 확인 할 수 있다.
참고 : https://brunch.co.kr/@topasvga/553
728x90
'Linux' 카테고리의 다른 글
쉘 스크립트란? (0) | 2022.12.31 |
---|---|
grep과 pipe(|)의 조합 (0) | 2022.12.30 |
리눅스 기본 명령어 모음 (3) | 2022.12.18 |
리눅스 시간(타임존)을 한국 표준시(KST)로 변경 (0) | 2022.08.04 |
리눅스 서버가 이상할 때, 로그 보는 곳 (0) | 2022.07.28 |