2009年5月25日 星期一

cpio usage

Oracle usually will use the cpio format as the installation binary.

But I used to use cpio -idvm < *.cpio to extract the file .

But encountered the error

cpio: 0511-903 Out of phase!
cpio attempting to continue...

cpio: 0511-904 skipping 732944 bytes to get back in phase!
One or more files lost and the previous file is possibly corrupt!


This made me hate the cpio format.


Today I finally found the correct usage


cpio -idcmv < *.cpio


 

2009年5月8日 星期五

Remove file according to date

I always forgot the syntax.

So I decide to write it down in my Blog.

 

find . -name '<pattern>' -exec rm -f {} \;

 

find . -atime +<n day> -exec rm -f {} \;