Thread tagged as: Problem, Blog

Very strange bahaviour from Perch admin area and perch_content_custom


I've come across a very strange problem which I think you should be aware of. I've fixed the problem, but I wanted to run it past you in case you'd heard of similar occurrences.

Basically, the problem manifested itself by the Perch admin area constantly redirecting to /perch/core/update (which resulted in a 404 because the /update folder had been deleted). On the front-end, any content pulled into a page using perch_content_custom() or perch_blog_custom() was missing. No error messages were shown. Content pulled in using perch_content() and perch_blog_recent_posts() appeared as expected.

I fixed the problem by replacing the /perch/core folder with its equivalent from the staging version of the site.

According the client, the problem occurred when he was working on a draft blog post. He had saved and clicked on preview, then left the tab with the draft blog post and the preview tab open while he left his computer briefly (he works alone - there was no-one else that could have touched the computer). The problem started when he refreshed the preview page when he returned.

After I replaced the Perch core, there were two new page instances listed in the page list. They were both "ghost" pages - imprints of existing pages but possessing invalid directory structures.

My first thought was malware, but nothing was found when we checked our systems.

As I've mentioned - this is just for your info. The problem is fixed AFAIK. If you need any further info, though, please let me know.

Thanks, Jon

Here's the diagnostics.

Perch: 2.8.8 Production mode: Production (100) Installed apps: content (2.8.8), assets (2.8.8), categories (2.8.8), perch_blog (4.6), perch_backup (1.2) DB driver: PDO DB tables: perch2_blog_authors, perch2_blog_comments, perch2_blog_index, perch2_blog_posts, perch2_blog_posts_to_tags, perch2_blog_sections, perch2_blog_tags, perch2_categories, perch2_category_counts, perch2_category_sets, perch2_content_index, perch2_content_items, perch2_content_regions, perch2_navigation, perch2_navigation_pages, perch2_page_templates, perch2_pages, perch2_resource_log, perch2_resource_tags, perch2_resources, perch2_resources_to_tags, perch2_settings, perch2_user_privileges, perch2_user_role_privileges, perch2_user_roles, perch2_users Users: 2 App runtimes: <?php $apps_list = array( 'content', 'categories', 'perch_blog', 'perch_backup' ); Scheduled tasks for perch_blog: delete_spam_comments (1440 mins) Editor plug-ins: markitup H1: 00784e28ebc9953570bc4aaa4193b0a4 L1: 80d34e58150f2d8e0ef7851cecd0a0ad headerColour: #ffffff content_singlePageEdit: 1 helpURL: siteURL: / hideBranding: 0 content_collapseList: 0 lang: en-gb update_2.8.6: done latest_version: 2.8.8 on_sale_version: 2.8.8 perch_blog_update: 5.0 perch_blog_post_url: /article/{postSlug} headerScheme: light perch_blog_slug_format: {postID}-{postTitle} perch_blog_akismet_key: perch_blog_max_spam_days: 0 dashboard: 0 hide_pwd_reset: 0 content_hideNonEditableRegions: 0 content_frontend_edit: 0 perch_blog_comment_notify: 0 logoPath: /perch/resources/nexus_logo.png update_2.8.7: done update_2.8.8: done PERCH_DEVELOPMENT: 10 PERCH_STAGING: 50 PERCH_PRODUCTION: 100 PERCH_DB_USERNAME: nexus-323 PERCH_DB_SERVER: PERCH_DB_DATABASE: nexus-323 PERCH_DB_PREFIX: perch2_ PERCH_TZ: Europe/London PERCH_EMAIL_FROM: PERCH_EMAIL_FROM_NAME: Jon Brain PERCH_LOGINPATH: /perch PERCH_PATH: /home/cluster-sites/4/n/ PERCH_CORE: /home/cluster-sites/4/n/ PERCH_RESFILEPATH: /home/cluster-sites/4/n/ PERCH_RESPATH: /perch/resources PERCH_HTML5: 1 PERCH_CLEAN_RESOURCES: PERCH_RUNWAY: PERCH_ERROR_MODE: DIE PERCH_DATE_LONG: %d %B %Y PERCH_DATE_SHORT: %d %b %Y PERCH_TIME_SHORT: %H:%M PERCH_TIME_LONG: %H:%M:%S PERCH_DEBUG: PERCH_PREVIEW_ARG: preview PERCH_TEMPLATE_PATH: /home/cluster-sites/4/n/ PERCH_DEFAULT_DOC: index.php PERCH_DEFAULT_EXT: .php PERCH_PRODUCTION_MODE: 100 PERCH_RWD: PERCH_HTML_ENTITIES: PERCH_SSL: PERCH_STRIPSLASHES: PERCH_PROGRESSIVE_FLUSH: 1 PERCH_AUTH_PLUGIN: PERCH_DB_CHARSET: utf8 PERCH_DB_PORT: PERCH_DB_SOCKET: Hosting settings PHP: 5.4.26 Zend: 2.4.0 OS: Linux SAPI: cgi-fcgi Safe mode: not detected MySQL client: mysqlnd 5.0.10 - 20111026 - $Id: c85105d7c6f7d70d609bb4c000257868a40840ab $ MySQL server: 5.5.5-10.0.14-MariaDB Extensions: Core, date, ereg, libxml, openssl, pcre, zlib, bz2, calendar, ctype, hash, filter, ftp, gettext, gmp, SPL, iconv, pcntl, readline, Reflection, session, standard, shmop, SimpleXML, sockets, mbstring, tokenizer, xml, cgi-fcgi, bcmath, curl, dom, enchant, fileinfo, gd, imap, intl, json, ldap, exif, mcrypt, mssql, mysqlnd, mysql, mysqli, odbc, PDO, pdo_dblib, pdo_mysql, PDO_ODBC, pdo_pgsql, pdo_sqlite, pgsql, Phar, posix, pspell, recode, soap, sqlite3, sysvmsg, sysvsem, sysvshm, tidy, wddx, xmlreader, xmlrpc, xmlwriter, xsl, zip, mhash, ionCube Loader, Zend Guard Loader GD: Yes ImageMagick: No PHP max upload size: 64M PHP max form post size: 64M PHP memory limit: 128M Total max uploadable file size: 64M Resource folder writeable: Yes Session timeout: 24 minutes Native JSON: Yes Filter functions: Yes Transliteration functions: Yes PATH: /usr/local/bin:/usr/bin:/bin UNIQUE_ID: VZ@F438AAAEAAFx9bqcAAAAI HTTP_HOST: HTTP_USER_AGENT: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:39.0) Gecko/20100101 Firefox/39.0 HTTP_ACCEPT: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 HTTP_ACCEPT_LANGUAGE: en-US,en;q=0.5 HTTP_ACCEPT_ENCODING: gzip, deflate HTTP_REFERER: HTTP_COOKIE: __utma=10778283.943419592.1423669937.1436344290.1436453729.25;|utmccn=(referral)|utmcmd=referral|utmcct=/blog/article/12-integrating-inbound-marketing-with-outbound-sales-is-essential; __hstc=153692839.34a4ac75b5f2d22a1cead8a2cc4da267.1427979519438.1436344308059.1436453730093.23;||1427979519437; hubspotutk=34a4ac75b5f2d22a1cead8a2cc4da267; cmsa=1; cookieconsent_dismissed=yes; __utmc=10778283; __hssrc=1; PHPSESSID=ab3s9ti8hnd7cca3r9mc9cval0 HTTP_X_BRAND: 123 HTTP_CONNECTION: close SERVER_SIGNATURE: <address>Apache/2.4.12 (Unix) Server at Port 80</address> SERVER_SOFTWARE: Apache/2.4.12 (Unix) SERVER_NAME: SERVER_ADDR: SERVER_PORT: 80 REMOTE_ADDR: DOCUMENT_ROOT: /home/cluster-sites/4/n/ REQUEST_SCHEME: http CONTEXT_PREFIX: / CONTEXT_DOCUMENT_ROOT: /home/cluster-sites/4/n/ SERVER_ADMIN: root@localhost SCRIPT_FILENAME: /home/cluster-sites/4/n/ REMOTE_PORT: 37861 GATEWAY_INTERFACE: CGI/1.1 SERVER_PROTOCOL: HTTP/1.1 REQUEST_METHOD: GET QUERY_STRING: extended REQUEST_URI: /perch/core/settings/diagnostics/?extended SCRIPT_NAME: /perch/core/settings/diagnostics/index.php PHP_SELF: /perch/core/settings/diagnostics/index.php REQUEST_TIME_FLOAT: 1436517859.6064 REQUEST_TIME: 1436517859
Jonathan Brain

Jonathan Brain 0 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Why was the perch/core/update folder deleted?

It was deleted manually after the previous Perch update.

Drew McLellan

Drew McLellan 2638 points
Perch Support

I won't ask why - but please don't mess with stuff in the core folder. As you can see, if you remove parts of the system weird things can happen.

Let me know if it reoccurs.

Oh hell - I think I've been deleting /update folders instead of /setup folders after each update.

Drew McLellan

Drew McLellan 2638 points
Perch Support

Ha! Now would be a great time to stop :-)

Actually, only on this one site it seems - I must have had a very bad day...!