When you unlink a file the filesystem should recover the associated disk blocks and inode. I'm assuming that you only want to remove some of the files and, possibly, directories based on some criterion or other. If this is the case, once you have completed your tidy-up you should run
fsck -n /dev/rdsk/c......
which will check the partiton without making any changes and give you some stats at the end including percentage fragmentation. If the fragmentation value is above single figures then consider doing a ufsdump of the partition, remaking it with newfs and doing a ufsrestore -rvf. It is extremely rare in my experience to need to do this.
If on the other hand you actually want to unlink all of the directories and files on the partition, don't bother, just newfs it.
I hope this is useful.
Cheers,
JohnGG
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.