Wow, that's really odd. Whatever's running that has put the entire script on the command line. At least that made it easy to look through and figure out what it's doing.
Basically, the script looks through your entire Applications directory and spits out the version numbers of all the apps it can find. I don't know why it's doing this or how that information is being used. Or what program is running it in the first place. That's where you have to trace back up the process tree to find what called it.
Next time it happens, do this instead:
Look for a similar big huge line, but this time look at the third number from the left. That tells you the parent process id. The second number is perl's process id. What you want to do is look for the parent process id (third number) to find out what program called it. So if the number is 12345, you'd do:
This time you'd look for the line with 12345 as the
second number. That's the parent process, and the third number in that line will be its parent process. You can keep doing this to trace back up until you find something you recognize.
For example, I want to trace what programs called the weather widget. First, I do:
Code:
ps laxww|grep -i weather
405 4397 3396 0 63 0 127340 7628 - S ?? 0:01.62 /System/Library/CoreServices/Dock.app/Contents/Resources/DashboardClient.app/Contents/MacOS/DashboardClient /Library/Widgets/Weather.wdgt/ 4855 41a1abb0f66011f5 f
From this, I see that process id 4397 is the weather widget, and it has parent process 3396. I look for 3396:
Code:
ps laxww | grep 3396
405 3396 71 0 46 0 134624 10536 - S ?? 0:07.83 /System/Library/CoreServices/Dock.app/Contents/MacOS/Dock -psn_0_7471105
405 4395 3396 0 63 0 133152 4908 - S ?? 0:00.76 /System/Library/CoreServices/Dock.app/Contents/Resources/DashboardClient.app/Contents/MacOS/DashboardClient /Library/Widgets/Google.wdgt/ 4853 41a30abbbb059b1b f
405 4396 3396 0 63 0 133564 6700 - S ?? 0:01.21 /System/Library/CoreServices/Dock.app/Contents/Resources/DashboardClient.app/Contents/MacOS/DashboardClient /Library/Widgets/Dictionary.wdgt/ 4854 41a04b8e2e89e7b8 f
405 4397 3396 0 63 0 127340 7628 - S ?? 0:01.62 /System/Library/CoreServices/Dock.app/Contents/Resources/DashboardClient.app/Contents/MacOS/DashboardClient /Library/Widgets/Weather.wdgt/ 4855 41a1abb0f66011f5 f
Ok, I see a few other widgets have the same parent process id, but the main line I'm interested in is the first one, with 3396 as the process id. Looks like
Dock is running the widgets. It has a parent process id of 71, so what's that?
Code:
ps laxww | grep 71
88 71 1 0 63 0 210516 70172 - Ss ?? 63:59.82 /System/Library/Frameworks/ApplicationServices.framework/Frameworks/CoreGraphics.framework/Resources/WindowServer -daemon
405 225 71 0 63 0 143100 9616 - S ?? 32:03.87 /System/Library/CoreServices/SystemUIServer.app/Contents/MacOS/SystemUIServer -psn_0_655361
... (and a whole bunch of other stuff) ...
Looks like WindowServer runs Dock, plus a whole bunch of other stuff that I cut out. WindowServer was started by process id 1, which is launchd. Using this method, hopefully you can figure out what is running that script. I've never seen it, so I have no idea.
