How to strace cPanel software

November 10th, 2009 by tech Leave a reply »

From time to time, strange issues pop up which aren’t going to be logged to an error log. For some of the more “hard to track down” issues, you can use strace to see just what the process is doing, and where your issue might be.

This article won’t go into how to read straces, as there are many other articles written about this, but I’ll provide a good base from which to start.

strace -v -o /root/strace.cpanel -f -s 4096 -p `cat /var/run/cpsrvd.pid`

That command uses several flags, outputting the strace to a file called strace.cpanel.

-v enables a more verbose output
-o specifies the file to output the contents to. If not specified, it will output directly to your terminal.
-f includes all processes forked by the process you’re stracing
-p will specify the PID. In this case, we’re going to cat the pic from cpsrvd.pid

  • Share/Bookmark
Post Sponsored by

Leave a Reply


cPanel Web Site Hosting by IntraHost