Finding the true status of launchd jobs launchctl list

launchctl bstree


These show which jobs are active, dormant or inactive, allegedly.  I have never seen an inactive job personally. Even ones that I have tried to inactivate show as 'D'

Now, in /var/db/launchd.db there are textfiles that show, per user, which jobs are actually disabled, lamentably, the old -w switch was deprecated, and the Disabled  key in the plist is only a default. I don't know why they would do such a thing, there seems to be no way to say definitively

"Service X is off."

It seems that running as root I should be able to ask what is on, and what is off. What am I doing wrong?

EDIT: What I was doing wrong was ignoring

/var/db/launchd.db/com.apple.launchd/overrides.plist


Which is the definitive place apparently for the current state of a daemon.

Handily, this means that the default will be in the plist files in /System/Launch*
/Library/Launch*
~/Library/Launch*
and one can just blow away ( errrm copy and move ) that directory and reboot to a default set.  This worked for me recently.
The launchd GUI LaunchControl will give you a list of services along with their respective status. You can see if a job has been disabled by looking at the check box next to the job name. A colored check box indicates that the Disabled key has been overridden: a red checkbox stands for a permanently disabled job, a green one for a permanently enabled job.