public static function run() { self::$_results['start_troubleshooting'] = microtime(true); self::$_results['gmt_offset'] = get_option('gmt_offset'); self::$_results['current_time'] = pb_backupbuddy::$format->date(time()); self::$_results['localized_time'] = pb_backupbuddy::$format->date(pb_backupbuddy::$format->localize_time(time())); self::$_results['current_timestamp'] = time(); // Recent send fails (remote destination failures). // HIGHLIGHTS: PHP errors, send errors, NUMBER of sends failed in X hours // Populates tail of status log and looks for PHP and BB notices. self::_test_site_home_url(); self::_test_versions(); self::_test_log_file_info(); self::_test_status_log(); self::_test_recent_sync_notifications(); self::_test_live_state(); self::_test_server_stats(); self::_test_cron_scheduled(); self::_test_recent_live_send_fails(); self::_test_extraneous_log(); self::_recent_waiting_on_files_tables(); self::$_results['finish_troubleshooting'] = microtime(true); self::$_finished = true; }
<?php backupbuddy_core::verifyAjaxAccess(); require pb_backupbuddy::plugin_path() . '/destinations/live/_troubleshooting.php'; backupbuddy_live_troubleshooting::run(); $output = "**File best viewed with wordwrap OFF**\n\n" . print_r(backupbuddy_live_troubleshooting::get_raw_results(), true); header('Content-Description: File Transfer'); header('Content-Type: text/plain; name=backupbuddy-live_troubleshooting-' . backupbuddy_core::backup_prefix() . '.txt'); header('Content-Disposition: attachment; filename=backupbuddy-live_troubleshooting-' . backupbuddy_core::backup_prefix() . '.txt'); header('Expires: 0'); header('Content-Length: ' . strlen($output)); pb_backupbuddy::flush(); echo $output; pb_backupbuddy::flush(); die;