일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- history
- django
- QT
- hadoop
- erlang
- RFID
- comic agile
- Python
- Linux
- Software Engineering
- web
- agile
- Spain
- management
- France
- programming_book
- psychology
- Malaysia
- essay
- leadership
- Book
- hbase
- ubuntu
- Book review
- program
- Italy
- Kuala Lumpur
- Java
- Programming
- MySQL
- Today
- Total
목록bash (3)
http://www.linuxproblem.org/art_9.html e.g. from id_a@server_a, login without password to id_b@server_b_1 ~ id_b@server_b_10 [id_a@server_a]$ for host in server_b_{1..10};do cat ~/.ssh/id_rsa.pub | ssh id_b@$host 'cat >> .ssh/authorized_keys'; done id_b@server_b_1's password:id_b@server_b_2's password: ...id_b@server_b_10's password:
case 1. dump monetdb database into file (escape sequences show like '\t', '\n' properly) 2. split it into table by table using bash script (escape sequences show like 't', 'n') 3. bulk input table dump file into other database problem: cannot write escape sequence properly (want: '\t', '\n' / real: 't', 'n') solution: use eight back slashes ... _line=`echo $_line | sed 's/'\''\([t|n]\)'\''/'\''\..
#!/bin/bash ps aux | grep test | grep home1 | awk -F" " '{print $2;}' | while read PID; do kill -9 $PID; done; 1. ps aux 2. grep test | grep home1 : testj가 들어가고 거기서 다시 home1만 들어간 행만 선택 3. awk -F" " '{print $2;}' : 공백으로 구분된 것들 중 두 번째 필드들만 출력 4. while read PID; do kill -9 $ PID; done;: 3의 결과를 PID로 읽어 프로세스 삭제