LWN.net Logo

Announcing a new utility: 'trace'

Announcing a new utility: 'trace'

Posted Nov 16, 2010 23:06 UTC (Tue) by marineam (subscriber, #28387)
In reply to: Announcing a new utility: 'trace' by mingo
Parent article: Announcing a new utility: 'trace'

In my usage often the important strings other than filenames that I look at frequently in strace are the arguments to execve() and read()/write() so I can narrow down my debugging to things like "Ok, I see that it is receiving all of the data correctly but it somehow truncated it before calling xyz"

The vast majority of the strings aren't important but that one time an important string isn't decoded it is annoying and slightly time consuming to switch to a more complex tool such as gdb to answer the otherwise 3 second question of "that data is good/bad." (I can't remember what syscall it was that I hit this with strace any more but the data wasn't in a struct and yet it didn't know it could decode it.)

Decoding strings by default does add noise but strace's default of truncating after 32 characters seems to be a reasonable compromise.


(Log in to post comments)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds