Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

(Cheat sheet? Cheat Novella, more like! I think it's probably past the point where it needs to be split up a bit, even if only for your own benefit.)

"How do you check disk usage. How do you trouble shoot a high disk usage issue"

which is fine, until someone's done something similar to the next bit of advice - i.e. deleted some "old", large files that were still open by the application.

Better: compare filesystem usage (with df), against disk space used (with du), to deduce that there's an open file that has been unlinked. Then use lsof (whatever Sun say about pfiles or about dtrace, lsof is an essential tool) to look for processes with open files that have large offsets.

And, when deleting large files, check whether they're open, and truncate them before deleting them if you're not sure.

(note to another poster - ain't nothing wrong with Solaris! But I'm not really sure what interviewer might ask questions about the OSI 7 layer model, these days, and I agree that there's a real odd jumble of scripting snippets in there: best advice to anyone wanting to improve that side of their systems administration skills, is to read a copy of Unix Power tools.)



Systemtap has an open files tap which has similar advantages over lsof FYI.


Systemtap looks very cool. I am reading about it now. I will try it ou on my FC11 VM.


Re: pfiles equivalent (now I'm not on the phone and can chase it up)

http://kbase.redhat.com/faq/docs/DOC-9942




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: