Skip to content
Paul Bunyan Message Logger. The best damn logger there ever was. WordPress, PHP, MySQL.

Turn recording on and off

The Paul Bunyan switch: on, off, on for a set time, or on for your browser only. Plus the wp-config.php off switch and the safety switch that turns Paul Bunyan off by itself.

Updated · By Diamond Sierra

On this page

Paul Bunyan has one switch, in the header of every Paul Bunyan screen and in the admin bar. Off means off: no hooks, no browser script and nothing written to the database. The screens still show what was recorded before.

The choices

ChoiceWhat it does
Turn onRecords until you turn it off.
On for 15 minutes, 1 hour or 24 hoursRecords, then switches itself off. Good for a short investigation on a busy site.
On, this browser onlyRecords only your own visits, from the browser you pressed it in. Visitors are not traced. Useful for reproducing a problem on a live site.
Turn offStops all recording.
The Paul Bunyan header with the recording switch: Recording On, Turn off, and Record this browser only
The switch is in the header of every screen, and in the admin bar.

You can profile one page on demand from the Compare screen even while recording is off.

Switch it off without logging in

If the dashboard itself will not load, add this line to wp-config.php:

define( 'PAUL_BUNYAN_OFF', true );

Paul Bunyan then does nothing at all, and the switch in the header says it was switched off in wp-config.php. Remove the line to use the switch again.

From the command line

wp pb on --for=60
wp pb off
wp pb status

See Paul Bunyan from the command line.

When Paul Bunyan switches itself off

Paul Bunyan watches its own cost. If it costs more than the safety limit (150 ms by default) on five ordinary requests inside ten minutes, or the log table cannot be written, it switches itself off so it cannot make things worse, and records why as PB-1008.

Messages filtered to PB-1008: Paul Bunyan switched itself off after its own cost passed the 150 ms safety limit five times in ten minutes
PB-1008 on a live site: Paul Bunyan switched itself off rather than slow the site down.

It counts a request against itself only when its own cost is over the limit and is also at least a tenth of the whole request. So a server that is slow for everyone, during a bot burst say, does not trip it.

Read the reason, fix it (lower Trace this percent of requests or the discovery rate, raise the safety limit, or check the database), then turn it back on. See Settings.