{"id":2600,"date":"2024-08-12T08:32:54","date_gmt":"2024-08-12T12:32:54","guid":{"rendered":"https:\/\/sites.bu.edu\/marcom-team\/?page_id=2600"},"modified":"2025-12-09T12:01:01","modified_gmt":"2025-12-09T17:01:01","slug":"error-watching-performance-monitoring","status":"publish","type":"page","link":"https:\/\/sites.bu.edu\/marcom-team\/departments\/interactive-design\/role-specific-info\/info-for-developers\/error-watching-performance-monitoring\/","title":{"rendered":"Error Watching &#038; Performance Monitoring"},"content":{"rendered":"<div class=\" bu-callout alignright\"><\/p>\n<h5>You <span>need to be <a href=\"https:\/\/sites.bu.edu\/marcom-team\/departments\/interactive-design\/i-d-role-specific-info\/designers-developers\/vpn-sftp-setup-for-code-editors-instructions-for-tower-or-git\/\">on the VPN<\/a> to connect to our servers. Also: &#8216;NM&#8217; stands for our New Media sandbox.<\/span><\/h5>\n<p><\/div>\n<p><span style=\"font-weight: 400;\">Here\u2019s a list of all of the error watching and performance monitoring options available to us in ID &amp; Webteam.<\/span><\/p>\n<h3><strong>Immediate Logging w\/Terminal<\/strong><\/h3>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">To watch all of the development sandbox error logs, open terminal and run the following two commands:<\/span><\/li>\n<\/ul>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400;\"><code>1<\/code><\/span><\/p>\n<p><span style=\"font-weight: 400;\"><code>2<\/code><\/span><\/td>\n<td><span style=\"font-weight: 400;\"><code>ssh ist-wp-app-devl101.bu.edu<\/code><\/span><\/p>\n<p><span style=\"font-weight: 400;\"><code>tail -f \/var\/log\/httpd\/error_log<\/code><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">To watch just your sandbox, use this command instead and substitute your sandbox name (we\u2019re using <code>nm<\/code> here):<\/span><\/li>\n<li aria-level=\"1\"><\/li>\n<\/ul>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400;\"><code>1<\/code><\/span><\/td>\n<td><span style=\"font-weight: 400;\"><code>tail -f \/var\/log\/httpd\/error_log | grep nm<\/code><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">To clear the list of errors, hit <strong>\u2318 + k<\/strong> in your terminal window.<\/span><\/li>\n<\/ul>\n<p><span style=\"font-weight: 400;\">Note: your computer user name may not be the same as your SSH user name. If this is the case, you\u2019ll get an error that the password is incorrect. To fix, manually enter your user name in the SSH command:<\/span><\/p>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400;\"><code>1<\/code><\/span><\/td>\n<td><span style=\"font-weight: 400;\"><code>ssh <strong>yourusername<\/strong>@ist-wp-app-devl101.bu.edu<\/code><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h5><strong>Advanced Alias<\/strong><\/h5>\n<p><span style=\"font-weight: 400;\">You can create an alias in your <code>.bashrc<\/code> file on <code>ist-wp-app-devl101<\/code> that allows an easy way to access tail. Once this is created, you can just type <code>wptail<\/code>\u00a0into terminal.<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">SSH into <code>ist-wp-app-devl101<\/code><\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\"><code>vi .bashrc<\/code><\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Add the line below to the end of the file<\/span><\/li>\n<\/ul>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400;\"><code>1<\/code><\/span><\/p>\n<p><span style=\"font-weight: 400;\"><code>2<\/code><\/span><\/td>\n<td><span style=\"font-weight: 400;\"><code>#general aliases<\/code><\/span><\/p>\n<p><span style=\"font-weight: 400;\"><code>alias wptail=\"tail -f \/var\/log\/httpd\/error_log\"<\/code><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3><strong>\u201cHistoric\u201d Logging w\/ Splunk<\/strong><\/h3>\n<p><span style=\"font-weight: 400;\">Utilize IS&amp;T\u2019s <\/span><a href=\"https:\/\/prd-p-gz9nd9hn4p5g.cloud.splunk.com\/en-US\/app\/search\/search\"><span style=\"font-weight: 400;\">Splunk<\/span><\/a><span style=\"font-weight: 400;\"> account by logging in to our shared ID account.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Make sure you click the \u201cSplunk App for AWS\u201d in the top left and select \u201cSplunk &gt; lite\u201d.<\/span><\/p>\n<p><span style=\"font-weight: 400;\"><div class=\" bu-callout alignright\"><\/span><\/p>\n<h5><strong>This is \u201chistoric\u201d because of the ~2 minute delay between when events happen and when they flow into Splunk\u2019s dashboard.<\/strong><\/h5>\n<p><span style=\"font-weight: 400;\"><\/div><\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">To see all of the development sandboxes, utilize the search at the top by typing the following:<\/span><\/li>\n<\/ul>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400;\"><code>1<\/code><\/span><\/td>\n<td><span style=\"font-weight: 400;\"><code>index=\"wp-app-devl\"<\/code><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">To see just your sandbox, use this command instead and substitute your sandbox name (we\u2019re using nm here):<\/span><\/li>\n<\/ul>\n<table>\n<tbody>\n<tr>\n<td><span style=\"font-weight: 400;\"><code>1<\/code><\/span><\/td>\n<td><span style=\"font-weight: 400;\"><code>index=\"wp-app-devl\" \"nm.cms-devl.bu.edu\"<\/code><\/span><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<p><span style=\"font-weight: 400;\">Note the following handy features:<\/span><\/p>\n<ul>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Timeline (orange &amp; gray bar)<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">Time selector (right next to search button)<\/span><\/li>\n<li style=\"font-weight: 400;\" aria-level=\"1\"><span style=\"font-weight: 400;\">URL sharing (copy and paste it to your friends)<\/span><\/li>\n<\/ul>\n<h3><strong>WP Query Monitor<\/strong><\/h3>\n<p><span style=\"font-weight: 400;\"><div class=\" bu-callout alignright\"> <\/span><\/p>\n<h5><span style=\"font-weight: 400;\"><strong>We don\u2019t want Query Monitor to be enabled on production [LIVE] sites unless necessary.<\/strong> Remember to disable it immediately after you\u2019re done testing. Also disable it on a staging site before it launches.<\/span><\/h5>\n<p><span style=\"font-weight: 400;\"><\/div><\/span><\/p>\n<p><span style=\"font-weight: 400;\">Enable the Query Monitor plugin on sites in your sandbox.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">Use Query Monitor to watch for errors, fatal errors, duplicate queries, slow queries, and query counts per page.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">It also has a handy list of PHP template parts loaded on the current page, body classes, and conditionals.<\/span><\/p>\n<h3><strong>New Relic Performance Monitoring<\/strong><\/h3>\n<p><span style=\"font-weight: 400;\"><div class=\" bu-callout alignright\"><\/span><\/p>\n<h5><span style=\"font-weight: 400;\"><em>As of Oct 3, 2018<\/em>, the WordPress monitoring part of the app has lost connection to our services. IS&amp;T was last checking on it and will let us know if and when it has been restored.<\/span><\/h5>\n<p><span style=\"font-weight: 400;\"><\/div><\/span><\/p>\n<p><span style=\"font-weight: 400;\">Use IS&amp;T\u2019s <\/span><a href=\"https:\/\/rpm.newrelic.com\/accounts\/637623\/applications\/7212547\/\"><span style=\"font-weight: 400;\">New Relic<\/span><\/a><span style=\"font-weight: 400;\"> Instance by logging into your individual account. This service will let us know how performant (or not) queries are, functions, hook, etc.<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Here\u2019s a list of all of the error watching and performance monitoring options available to us in ID &amp; Webteam. Immediate Logging w\/Terminal To watch all of the development sandbox error logs, open terminal and run the following two commands: 1 2 ssh ist-wp-app-devl101.bu.edu tail -f \/var\/log\/httpd\/error_log To watch just your sandbox, use this command [&hellip;]<\/p>\n","protected":false},"author":12906,"featured_media":0,"parent":230,"menu_order":3,"comment_status":"closed","ping_status":"closed","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/pages\/2600"}],"collection":[{"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/users\/12906"}],"replies":[{"embeddable":true,"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/comments?post=2600"}],"version-history":[{"count":4,"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/pages\/2600\/revisions"}],"predecessor-version":[{"id":4173,"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/pages\/2600\/revisions\/4173"}],"up":[{"embeddable":true,"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/pages\/230"}],"wp:attachment":[{"href":"https:\/\/sites.bu.edu\/marcom-team\/wp-json\/wp\/v2\/media?parent=2600"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}