Html blob 'global_content_block_x' does not exist

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
User avatar
rotezecke
Power Poster
Power Poster
Posts: 411
Joined: Fri Apr 18, 2008 9:34 pm
Location: Nimbin, Australia

Re: Html blob 'global_content_block_x' does not exist

Post by rotezecke »

i stumbled upon this error message today (again). the actual error was obvious, my jQuery didnt load. however, view source showed at least one "global_content ... does not exist" (maybe more than one). I hadnt touched the site in weeks (and admin log confirms this). my jquery library is loaded via GCB:
{strip}
<__script__ type="text/javascript" src="/uploads/js/jquery.1.2.7.tools.min.js"></__script>
<__script__ type="text/javascript" src="/uploads/js/windowsize.js"></__script>
{/strip}
when i changed the above to:
{strip}
<__script__ type="text/javascript" src="{root_url}/uploads/js/jquery.1.2.7.tools.min.js"></__script>
<__script__ type="text/javascript" src="{root_url}/uploads/js/windowsize.js"></__script>
{/strip}
things started working again. there were no obvious changes on the server (php, mysql, linux still same version) and as stated above, nothing was changed on the site for some time.
tristan
Dev Team Member
Dev Team Member
Posts: 375
Joined: Tue May 02, 2006 10:58 am
Location: The Netherlands

Re: Html blob 'global_content_block_x' does not exist

Post by tristan »

Hi rotezecke,

Could be that your edit just triggered a cache refresh, if I do a manual cash refresh here it solves the content block error as we'll for a couple if weeks.
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by paulbaker »

I am still getting this happen occasionally - like yesterday. The site causing the issues has loads of Global Content Blocks (about 30ish spread throughout all pages) and on this occasion only 1 page was not working, the rest were fine.

I have since upgraded the site from the set-up shown in a previous post of mine in this thread to the below (latest CMSMS):

----------------------------------------------
Cms Version: 1.11.10
Installed Modules:
CMSMailer: 5.2.2
CMSPrinting: 1.0.5
FileManager: 1.4.4
MenuManager: 1.8.6
MicroTiny: 1.2.6
ModuleManager: 1.5.5
News: 2.14.2
Search: 1.7.11
ThemeManager: 1.1.8
CMSForms: 1.10.14
Twitter: 2.0.2
FormBuilder: 0.7.3
CGExtensions: 1.38.1
CGSimpleSmarty: 1.7.1
CGBlog: 1.10.3
TinyMCE: 2.9.12
Archiver: 0.2.6
Statistics: 1.1.3
SEOTools2: 1.2.1
Notifications: 1.1

Config Information:
php_memory_limit:
process_whole_template:
max_upload_size: 32000000
url_rewriting: mod_rewrite
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true

Php Information:
phpversion: 5.4.21
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 128M
max_execution_time: 120
output_buffering: 4096
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 8M
upload_max_filesize: 32M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)

Server Information:
Server Api: cgi-fcgi
Server Db Type: MySQL (mysql)
Server Db Version: 5.1.72
Server Db Grants: Could not find a suitable "GRANT ALL" permission. This may mean you could have problems installing or removing modules. Or even adding and deleting items, including pages
Server Time Diff: No filesystem time difference found

----------------------------------------------

All modules up to date. I have also updated SocialBookmarks to the latest version 1.9.

Fingers crossed that might have solved the problem - anyone else got an update on this?
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by Rolf »

@paulbaker
Try to see what happens if a CGBlog article is planned and when it appears at the frontend...

grt. Rolf
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by paulbaker »

@Rolf

Thanks for the suggestion. I added a draft test blog. Checked front end - no errors. Then I made the test blog entry live - again no errors. Is that what you mean?

Site itself had last real blog entry in September 2013.
milehigh

Re: Html blob 'global_content_block_x' does not exist

Post by milehigh »

I also wanted to step in here. I've searched other posts about 'global content blocks missing' and HTML does not exist message in the source. I have a group of sites I see the same thing on. Any type of content refresh or cache clear and the GCB's show up again.
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm
Location: Fernie British Columbia, Canada

Re: Html blob 'global_content_block_x' does not exist

Post by calguy1000 »

I reviewed the code for the {global_content} tag in 1.11

It's very straight forward (unless I missed something). If the tag is not in the cache, it is queried from the database by name.

Now. If the problem is only happening 'some times' I would stay with my initial assumption that some plugin/module/UDT/custom code you have installed is accessing the database directly via mysql_ functions without properly restoring the CMSMS database connection.

The way to diagnose this is to:
a: Isolate the problem to something consistently reproducible on every request
if you can't do this... there's not much you can do... sorry. that's life.

b: Once you can consistently reproduce the problem you can slowly isolate it.
c: Once you can isolate the code you can make a decision to remove it or fix it.

We don't know your sites, the issue could be in some third party file that is included... or on some funky event handler, or in some erroneous module. but you have to do the leg work in reproducing and isolating the issue.
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
milehigh

Re: Html blob 'global_content_block_x' does not exist

Post by milehigh »

For those having the problem, what kind of hosting?

Looking at my pool of sites, I have isolated it down to one shared host provider. I've NEVER seen this issue across several much larger,busier and more customized sites on VPS's or dedicated servers spread across various versions of 1.11.x
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by paulbaker »

For me - shared hosting.
tristan
Dev Team Member
Dev Team Member
Posts: 375
Joined: Tue May 02, 2006 10:58 am
Location: The Netherlands

Re: Html blob 'global_content_block_x' does not exist

Post by tristan »

We're doing hosting ourselves on different kind of server configurations so I don't think this is a hosting issue. Mr. Campbell's suggestion sounds more likely although I couldn't find any GCB that didn't restore the CMSMS database connection correctly.

But since this is just a temporary problem, refreshing the cache solves it every time, wouldn't it be better to just notify on the admin side of the CMS in stead of the frontend and refresh the cache automatically?
calguy1000
Support Guru
Support Guru
Posts: 8169
Joined: Tue Oct 19, 2004 6:44 pm
Location: Fernie British Columbia, Canada

Re: Html blob 'global_content_block_x' does not exist

Post by calguy1000 »

a: I did not say GCB, I said plugin/module/UDT or custom code.

b: Clearing the cache directory is not the proper solution and will have undesired side effects
- increased server load
- increased load time for users
- templates have to be recompiled
- page structure re-cached
- stylesheets re-cached
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by Rolf »

My website is on a VPS...

For a long period I noticed it happen when a planned CGBlog article appeared on the front-end. You could almost set the clock on it. I updated all templates code, so almost all php notices in the error_log were gone, cleaned out modules, etc. etc. The last week all went pretty good.

This morning again problems :(

I looked into the tmp folder and found the cached file. This file *is* created, so I think CMSMS won't try to recreate it, unless the file is deleted (cache cleared).

The content of the file is:

Code: Select all

<?php /* Smarty version Smarty-3.1.16, created on 2014-02-13 07:09:59
         compiled from "globalcontent:footer" */ ?>
<?php /*%%SmartyHeaderCode:118257075652fbde101e5ee2-84009488%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_valid = $_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '2bb586574f3650db1bd921637f42bdb7952d7721' => 
    array (
      0 => 'globalcontent:footer',
      1 => 1392271781,
      2 => 'globalcontent',
    ),
  ),
  'nocache_hash' => '118257075652fbde101e5ee2-84009488',
  'function' => 
  array (
  ),
  'version' => 'Smarty-3.1.16',
  'unifunc' => 'content_52fbde101e8c18_32139623',
  'has_nocache_code' => false,
),false); /*/%%SmartyHeaderCode%%*/?>
<?php if ($_valid && !is_callable('content_52fbde101e8c18_32139623')) {function content_52fbde101e8c18_32139623($_smarty_tpl) {?><!-- Html blob 'footer' does not exist  --><?php }} ?>
I also created a mousetrap to help me find template errors ( https://www.cmscanbesimple.org/blog/mou ... ate-errors ) This morning when the website went down again, the mousetrap found a problem (can't tell what) in the root page. Cause or effect? I can't tell it at the moment...

PS. I updated the mousetrap code so it also sents the error message itself, not only the url.
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by Rolf »

My system information:

----------------------------------------------

Cms Version: 1.11.10

Installed Modules:

CMSMailer: 5.2.2
FileManager: 1.4.4
MenuManager: 1.8.6
ModuleManager: 1.5.5
CustomContent: 1.9
ThemeManager: 1.1.8
TinyMCE: 2.9.12
LinkMgr: 1.5.1
CGSimpleSmarty: 1.7.1
CGExtensions: 1.38.1
CGBlog: 1.11.1
CGCalendar: 1.13.3
Smileys: 0.9.0
Gallery: 1.6.1
Guestbook: 1.4_RC2
CGSmartImage: 1.15
CompanyDirectory: 1.20
CMSSimplepie: 1.0
FormBuilder: 0.7.3
FrontEndUsers: 1.22.3
JQueryTools: 1.2.5
Gbook: 1.2
MicroTiny: 1.2.6
CustomGS: 1.5
AceEditor: 1.0


Config Information:

php_memory_limit:
process_whole_template:
max_upload_size: 1000000000
url_rewriting: mod_rewrite
page_extension:
query_var: page
image_manipulation_prog: GD
auto_alias_content: true
locale:
default_encoding: utf-8
admin_encoding: utf-8
set_names: true


Php Information:

phpversion: 5.3.17
md5_function: On (True)
gd_version: 2
tempnam_function: On (True)
magic_quotes_runtime: Off (False)
E_STRICT: 0
E_DEPRECATED: 0
memory_limit: 250M
max_execution_time: 120
output_buffering: 4096
safe_mode: Off (False)
file_uploads: On (True)
post_max_size: 16M
upload_max_filesize: 1000M
session_save_path: /tmp (1777)
session_use_cookies: On (True)
xml_function: On (True)
xmlreader_class: On (True)


Server Information:

Server Api: cgi-fcgi
Server Db Type: MySQL (mysql)
Server Db Version: 5.5.9
Server Db Grants: Found a "GRANT ALL" statement that appears to be suitable
Server Time Diff: No filesystem time difference found


----------------------------------------------
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
User avatar
paulbaker
Dev Team Member
Dev Team Member
Posts: 1465
Joined: Sat Apr 18, 2009 10:09 pm
Location: Maidenhead, UK
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by paulbaker »

Rolf I added your mousetrap code to my problematic site and tested it - I got the email.

However, on my site when the error this thread is all about occurs, it does not produce the "Ooops" error page, instead there is a small comment in the HTML. So I'm not sure your code is going to run, is it... ???
User avatar
Rolf
Power Poster
Power Poster
Posts: 7825
Joined: Wed Apr 23, 2008 7:53 am
Location: The Netherlands
Contact:

Re: Html blob 'global_content_block_x' does not exist

Post by Rolf »

Yesterday my website had issues again. It isn't reproducable yet, but step by step the problem is getting clearer to me. My mousetrap worked during that period (approx. 30min.) and I think proofed what I was suspecting from the start and what also is mentioned by others. At some point a process within the website (CMS/webserver) creates a huge datatransport / connection attempts to the database. The mysql server is getting overloaded and will fail sometimes. My VPS is sending me mails with the message database overload.

The (43) mousetrap emails contained messages like can't find (module)template this and template that.
When CMSMS wants to recreate the html block cache file, the template content isn't readable because the mysql server is temporary down. This ends in the error message html block not found, what is clearly an effect of a problem and not the problem itself.

My error log doesn't contain clear and useable errors or notices.
What I do see each time the problem occurs is a simularity in IP addresses in the messages that are in the error log. They are always from bots, like google and facebook. I can't explain that at all, might be just an unrelated coincidence... To be sure I added extended sitemaps to the website to lower the bots indexrate. (Note: the website is very large!)

Now checking all add-ons *again*, trying to find... something...

Grtz. Rolf
- + - + - + - + - + - + -
LATEST TUTORIAL AT CMS CAN BE SIMPLE:
Migrating Company Directory module to LISE
- + - + - + - + - + - + -
Image
Locked

Return to “CMSMS Core”