민서네집

리눅스 tee, 화면과 파일에 동시 출력하기 / screen / nohup 본문

LINUX

리눅스 tee, 화면과 파일에 동시 출력하기 / screen / nohup

브라이언7 2016. 8. 12. 18:07

리눅스 tee, 화면과 파일에 동시 출력하기


http://zetawiki.com/wiki/리눅스_tee,_화면과_파일에_동시_출력하기


  • 명령어
명령어 | tee 파일명
  • 명령어 (오류메시지 포함하여 파일로 저장)
명령어 2>&1 | tee 파일명


간단한 screen 사용법


http://seungigi.blogspot.kr/2012/03/screen.html?m=1


리눅스 nohup 사용법


http://zetawiki.com/wiki/리눅스_nohup_사용법


[linux] 백그라운드 작업 nohup [xxx.sh] &




Background Process 돌고 있을때 출력값을 보고 싶을때


제일 좋은 방법은 실행시킬 때 redirect 를 걸어야 되는데, 이를 깜빡했다면...


$ sudo ls -l /proc/{process번호}/fd


혹은


strace -ewrite -p $PID 2>&1 | grep "write(1" 


cf) http://stackoverflow.com/questions/593724/redirect-stderr-stdout-of-a-process-after-its-been-started-using-command-lin

'LINUX' 카테고리의 다른 글

How to check if a user can access a given file?  (0) 2016.09.12
setfacl / getfacl  (0) 2016.08.16
Ubuntu Linux에 Redis 설치 완료  (0) 2016.08.12
디렉터리 합치기 (Merge Directory)  (0) 2016.05.16
Samba 설정  (0) 2016.05.03
Comments