If a large directory is deleted and namenode is immediately restarted, there are a lot of blocks that do not belong to any file. This results in a log:
This log is printed within FSNamsystem lock. This can cause namenode to take long time in coming out of safemode.
One solution is to downgrade the logging level.