Blog dedicated to Oracle Applications (E-Business Suite) Technology; covers Apps Architecture, Administration and third party bolt-ons to Apps

Thursday, October 2, 2008

rm -rf takes a long time

Jimmy pinged me today.  He was doing rm -rf to $COMMON_TOP before starting a clone.  The rm -rf was taking a long time.  I did a truss on his os process of rm -rf

$ truss -p 25517
unlink("OAAttachmentTableBean.class")           = 0
lstat64("OALabeledFieldLayoutBean.class", 0xFFBFEF98) = 0
unlink("OALabeledFieldLayoutBean.class")        = 0
lstat64("OADefaultFormStackLayoutBean.class", 0xFFBFEF98) = 0
unlink("OADefaultFormStackLayoutBean.class")    = 0
lstat64("OADefaultDoubleColumnBean.class", 0xFFBFEF98) = 0
unlink("OADefaultDoubleColumnBean.class")       = 0
lstat64("OAContentContainerBean.class", 0xFFBFEF98) = 0
unlink("OAContentContainerBean.class")          = 0
lstat64("OADefaultHideShowBean.class", 0xFFBFEF98) = 0
unlink("OADefaultHideShowBean.class")           = 0
lstat64("OAListOfValuesBean.class", 0xFFBFEF98) = 0
unlink("OAListOfValuesBean.class")              = 0
lstat64("OAStyledItemBean.class", 0xFFBFEF98)   = 0
unlink("OAStyledItemBean.class")                = 0
lstat64("OAStyledListBean.class", 0xFFBFEF98)   = 0
unlink("OAStyledListBean.class")                = 0
lstat64("OAFlexibleCellLayoutBean.class", 0xFFBFEF98) = 0
unlink("OAFlexibleCellLayoutBean.class")        = 0
lstat64("OAFlexibleLayoutBean.class", 0xFFBFEF98) = 0
unlink("OAFlexibleLayoutBean.class")            = 0
lstat64("OAFlexibleRowLayoutBean.class", 0xFFBFEF98) = 0
unlink("OAFlexibleRowLayoutBean.class")         = 0
lstat64("OAKFFLovBean.class", 0xFFBFEF98)       = 0
unlink("OAKFFLovBean.class")                    = 0
lstat64("OAMessageComponentLayoutBean.class", 0xFFBFEF98) = 0
unlink("OAMessageComponentLayoutBean.class")    = 0
getdents64(12, 0xFF26E000, 8192)                = 0
close(12)                                       = 0
chdir("..")                                     = 0
rmdir("layout")                                 = 0
stat64(".", 0xFFBFEFF8)                         = 0
lstat64("OADescriptiveFlexBean.class", 0xFFBFF0F0) = 0


The lstat64() function gets status information about a specified file and places it in the area of
memory pointed to by buf. If the named file is a symbolic link, lstat64() returns information about the symbolic link itself.

The unlink() function will erase full (or empty) directories, where permissions are ok.

The getdetns64() function syscall retrieves information about the content of a directory

It seems that, because of the large number of java files inside common top, it was taking a long time to recurse through them.

No comments: