modify trace level and fix potential issues
Merge pull request #1416 from ruil2/fix

modify trace level and fix potential issues