일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
- bash
- 디렉토리
- CentOS
- 파이썬
- Shell
- Elk
- syslog
- log
- Chrome
- K8S
- Audit Log
- JSON
- RHEL
- C
- GNOME
- docker
- Kubernetes
- 빅데이터
- Elasticsearch
- Python
- yum
- audit
- GPU
- Linux
- zabbix
- PostgreSQL
- centos 7.5
- rsyslog
- 크롬
- 서울시민카드
- Today
- Total
목록업무 (169)
Sysops Notepad
CAP_NET_BIND_SERVICE이 1024이하 포트(privileged ports)에 대해 권한 부여 역할 CentOS : yum install libcap pam-devel -e : effective 효력 부여-p : Permitted 허용-i : Inheritable 권한 상속 여부(execve) # setcap 'cap_net_bind_service=+ep' /usr/bin/nc (설정추가)# getcap /usr/bin/nc/usr/bin/nc = cap_net_bind_service+ep # setcap -r /usr/bin/nc (설정삭제)# getcap /usr/bin/nc su를 이용한 유저별 권한 부여vi /etc/security/capability.conf# needed to ru..
linux bash shell 에서 많이 사용 되는 echo 명령어의 상세 옵션 입니다. #!/bin/bash # -n new line 제외echo -n "1234567890" # \b backspaceecho -e "123456\b7890" # \\ backslashecho -e "123456\\7890" # \e escapeecho -e "123456\e7890" # \n new lineecho -e "123\n456\n789\n0" # \t tabecho -e "123\t456\t789\t0" # \v vertical tabecho -e "123\v456\v789\v0" # \r carriage returnecho -e "123\r4567890" # \c 이후 내용 생략, new line 포함 (s..
server,peer 둘 다 실행 yum install -y centos-release-gluster yum install glusterfs-server systemctl start glusterd systemctl enable rpcbindsystemctl start rpcbind vi /etc/hostsx.x.x.10 server.comx.x.x.20 peer.com server.com에서 실행 gluster peer probe peer.com -> peer probe: success. gluster peer status -> Number of Peers: 1 Hostname: peer.com Uuid: - State: Peer in Cluster (Connected) gluster pool list..
Centos 7 / RHEL 7 에서 반복되는 로그 제거하는 방법 해당로그는 systemd의 session_start_scope () 함수에 의해 인쇄됩니다. 이 함수는 cgroup을 만드는 데 사용되며 무시 가능합니다. # tail /var/log/message Dec 6 04:01:01 localhost systemd: Created slice user-0.slice.Dec 6 04:01:01 localhost systemd: Starting Session 63 of user root.Dec 6 04:01:01 localhost systemd: Started Session 63 of user root.Dec 6 05:01:01 localhost systemd: Created slice user-0.s..
# for user in $(cut -f1 -d: /etc/passwd); do crontab -u $user -l; done
yum install screen screen -S 세션명 : 세션 생성screen -r 세션명 : 강제로 종료된거에 다시 붙이기screen -RR Ctrl+a A : 현재 screen의 이름 설정Ctrl+a c : screen에서 새창 생성Ctrl+a k : 현재 screen 죽이기Ctrl+a d : 현재 screen detach Ctrl+a " : 리스트 보기 == screen -list Ctrl+a a : 바로 전 창으로Ctrl+a n : 다음 창으로 Ctrl+a p : 이전 창으로 Ctrl+a 0 : 0번째 창으로Ctrl+a 1 : 1번째 창으로 Ctrl+a S 화면 수평 분할Ctrl+a | 화면 수직 분할Ctrl+a tab 화면 분할 이동Ctrl+a Q 화면 분할 해제
리눅스 파일시스템 감시를 통한 변경,생성,삭제,위치변경 알림 inotify 사용법OS : centos 7.5 # yum install inotify-tools # inotifywait -e create,delete,modify,move -mrq /test & # touch /etc/test.txt/etc/ CREATE test.txt# detected # vi /etc/inotifywait.conf # create config file LOGFILE=/var/log/inotify.log MONITOR=/test EVENT=create,delete,modify,move # vi /etc/rc.d/init.d/inotifywait -------------------------------------------..
GPU 스케쥴링을 위한 GPU 스케쥴러 Slurm 명령어 정리 # smap -> 작업 상태 및 노드 상태 확인 # sinfo [option] -N -I-> 노드 or 파티션 정보 확인 # squeue -> 작업 상태 확인 - R : RUNNING - PD : PENDING - S : SUSPENDED - ST : STOP - CD : COMPLETED - CA : CANCELLED - F : FAILED - NF : NODE_FAIL # sbatch [option] scriptfile-> 작업 제출 -n 필요 프로세스 수-N 필요 컴퓨트 노드 수-o stdout filename-e stderr filename-t 최대 작업 시간 지정 format> 02:00:00--gres=gpu gpu 사용 옵션-p ..
mysql/mariadb 리눅스 json 포멧으로 출력하는 방법 # echo "select * from table limit 3;" | mysqlsh --json --sqlc --uri root@ip:3306{"duration":"0.00 sec","info":"","row_count":3,"rows":[[1,"PENELOPE","GUINESS",{"year":2006,"month":1,"day":15,"hour":4,"minute":34,"second":33.0}],[2,"NICK","WAHLBERG",{"year":2006,"month":1,"day":15,"hour":4,"minute":34,"second":33.0}],[3,"ED","CHASE",{"year":2006,"month":1,"day"..
Linux ( centos , redhat ) 환경에서 파이썬 소스 컴파일하여 사용하는 방법 # 컴파일할 특정 디렉토리로 이동cd /home/centos/py/ # 컴파일 명령어 실행python -m compileall . # 기존 컴파일 파일 overwritepython -m compileall -f . # 특정 파일만 컴파일 하는 방법python -m py_compile name.py # 리눅스 쉘에서 실행시키는 방법python 파일 가장 최상단에 #!/usr/bin/python 추가 (경로는 상황에 따라 변경) # 참고: python 3.x 버전의 경우 -f 를 해도 기존의 pyc파일 유지 ,cache 디렉토리로 compile 된다.이를 overwrite하려면 -b 옵션 추가python3 -m co..