pstat / swapinfo prints wrong output

Matthew Dillon dillon at
Sun Jan 4 12:02:27 PST 2004

:Here is the patch, I havn't tested it to much yet, so feedback is very
:welcome. If you remove every entry in /dev befor recreating it, make sure
:it creates all you disk devices. It did not create ad0s[34][a-h] for me,
:and that really screwed things up here. Just so you are warned.
:Eirik Nygaard
:eirikn at xxxxxxxxxxxx

    This looks reasonable.  I would make two changes.

    First, in all the places where you remove the 'ln -f blah rblah' put
    in its place a 'rm -f rblah' so it cleans up any prior usage in the
    /dev automatically.

    Second, in all the places where you remove the 'rm -rf $dname r$dname'
    please be sure to add back in a 'rm -rf $dname'.  You do in a few
    instances, but in most cases you jsut remove the rm -rf entirely.  This
    is bad.  The rm -rf exists as a safety feature in case someone 
    (A) accidently redirects to a non-existant device name as root, or
    (B) the device numbers change.  mknod will not create the device 

					Matthew Dillon 
					<dillon at xxxxxxxxxxxxx>

More information about the Bugs mailing list