Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- mkdir history
- echo foo bar > history/hist.db
- echo hello > test
- strace ./run 2>&1 | sed -n '/^open.*WRONLY/p' | sed 's/.*"(.*)"[^"]*$/1/'
- history/hist.db
- test
- $ lsof -p PID
- $ lsof -p `pidof gnome-terminal` | head -5
- COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
- gnome-ter 7423 saml cwd DIR 253,2 32768 10354689 /home/saml
- gnome-ter 7423 saml rtd DIR 253,0 4096 2 /
- gnome-ter 7423 saml txt REG 253,0 338632 1220790 /usr/bin/gnome-terminal
- gnome-ter 7423 saml mem REG 253,0 614032 1192949 /usr/lib64/libfreetype.so.6.6.0
Add Comment
Please, Sign In to add comment