Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Is there an application for OS X that will let me view what parent process is launching bzip2? It randomly opens up and eats a massive amount of CPU so it sorta lags the computer. I'm not sure what's causing it so in order to figure out, I wanted something like Process Explorer but for mac where I get a tree-type view of the running processes so I can determine what its parent process is.

UPDATE:

Okay I discovered that there is a All Process, Hierarchically sorting mode which does just that. It seems bzip2 is being launched by newsyslog. Any thoughts on this?

share|improve this question
1  
newsyslog simply handles log rotation for all kinds of logs in /var/logs. See /etc/newsyslog.conf for its configuration, and check the open files and ports for more info about where it uses bzip2. –  slhck Feb 17 '13 at 13:03
    
newsyslog uses bzip2 to compress old log files; normally, the logs are fairly small and this is a quick operation. Look in /var/log and see if one of the log files there is growing rapidly. –  Gordon Davisson Feb 17 '13 at 15:58
add comment

2 Answers

If you open Activity Monitor.app, you can select the process, and open the Get Info… window (or press ⌘I).

You can then check the Open Files and Ports for specific information about that process. This is likely to be the best source of info, since most processes will only show launchd as the parent process.

share|improve this answer
    
Okay, bzip2 has finished its thing and closed for now. I'm waiting for it to happen again and will update here what I find out. It happens randomly throughout the day. –  Propeller Feb 17 '13 at 13:04
    
Not entirely unexpected given it's a log process which does its work, but it really shouldn't slow your system down. Did you actually notice performance decreasing without looking at the Activity Monitor? Or did you just see it there? –  slhck Feb 17 '13 at 13:06
    
Yes, the main reason why I decided to inspect was because performance would become poor for a few minutes then return to being normal after. When I opened Activity Monitor and sorted it by the CPU consumption, bzip2 was on the top. So I tried Get Info on bzip2, turns out, there was no Open Files and Ports tab, only Memory and Statistics are there. I can only see Open Files and Ports for process that I opened myself (e.g. Google Chrome). –  Propeller Feb 17 '13 at 13:36
    
Interesting. You could also run a sudo lsof | grep bzip2, for example. –  slhck Feb 17 '13 at 13:39
    
I ran it on Terminal but i didn't see anything that visibly changed? What was it supposed to do? –  Propeller Feb 17 '13 at 14:04
show 2 more comments
up vote 0 down vote accepted

Sorry I forgot to update here. As it turns out kdc.log, located inside /var/log/krb5kdc was chugging on huge amounts of size (it's increasing its size in MBs after a few seconds/minutes). What I did to stop this from happening was gain permission to access it first. This was the tricky part since its still being used by the system, I had to do some reboots to finally get it loose. I then deleted it and created a blank folder and named it kdc.log. I don't know where I learned this but it's somehow stock knowledge to me that if you replace a file with a same-name folder and try to overwrite it by attempting to write to a file, nothing happens so no log will be made.

I know this is unorthodox but it stopped what's causing the lag so yeah.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.