Page 1 of 1

Spartacus

Posted: Fri Nov 04, 2005 8:30 pm
by PENorwood
Hi,

When I installed Spartacus and then attempted to run it I get this ...

Trying to open URL package_sidebar_en.xml...
Fetched 56178 bytes from the URL above. Saving file as /hsphere/local/home/paul2/paulericnorwood.com/serendipity/templates_c/package_sidebar_en.xml...
Data successfully fetched.


Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 46080 bytes) in /hsphere/local/home/paul2/paulericnorwood.com/serendipity/plugins/serendipity_event_multilingual/serendipity_plugin_multilingual.php on line 117

THe settings I used are ...

XML metadata: Netmirror.org
files: sourceforge.net
the rest are left blank.

Any ideas?

Thanks! Serendipity is by far the best blog software I have tried and I have tried most of them ... keep up the great work!!!

Re: Spartacus

Posted: Fri Nov 04, 2005 9:00 pm
by garvinhicking
Which serendipity version are you using?

Your server is using up more than 8MB of memory. Which event and sidebar plugins do you have installed?

Best regards,
Garvin

Re: Spartacus

Posted: Fri Nov 04, 2005 9:00 pm
by garvinhicking
Which serendipity version are you using?

Your server is using up more than 8MB of memory. Which event and sidebar plugins do you have installed?

Best regards,
Garvin

Posted: Wed Nov 09, 2005 7:48 pm
by PENorwood
serendipity_event_aggregator
serendipity_event_blogpdf
serendipity_event_entryproperties
serendipity_event_filter_entries
serendipity_event_forum
serendipity_event_google_sitemap
serendipity_event_includeentry
serendipity_event_layout_preinter_friendly
serendipity_event_mailentry
serendipity_event_mailer
serendipity_event_page_nugget
serendipity_event_podcast
serendipity_event_popfethcer
serendipity_event_spamblock
serendipity_event_spartacus
serendipity_event_thumbnails
serendipity_event_trackback
serendipity_event_weblogping
serendipity_plugin_adduser
serendipity_plugin_authors
serendipity_plugin_comments
serendipity_plugin_creativecommons
serendipity_plugin_delicious
serendipity_plugin_entrylinks
serendipity_plugin_eventwrapper
serendipity_plugin_google_last_query
serendipity_plugin_randomquotes
serendipity_plugin_remoterss
serendipity_plugin_wikipedia_finder

Posted: Wed Nov 09, 2005 7:48 pm
by PENorwood
Those are the ones in the plugins folder, not all of them are used

I trimmed all the extra events and sidebar plugins from the directory and I still get this error ...

Fatal error: Allowed memory size of 8388608 bytes exhausted (tried to allocate 39 bytes) in /hsphere/local/home/paul2/paulericnorwood.com/serendipity/plugins/serendipity_event_spartacus/serendipity_event_spartacus.php on line 436

Even if I delete an extra one I still get the 39 bytes error (which is barely any text at all)

Posted: Wed Nov 09, 2005 8:50 pm
by garvinhicking
Hm, that is a bit strange. Some plugin is using up all the ressources on your server.

If you are familiar with phpMyAdmin, you could go and look at the serendipity_plugins table. There you can execute that query:

Code: Select all

UPDATE serendipity_plugins SET placement = 'hiddenevent' WHERE placement = 'event' AND name not like '%spartacus%';
This will temporarily disable any event plugins apart spartacus from getting executed. Then you could try and see if it makes any difference? You could try the same with sidebar plugins:

Code: Select all

UPDATE serendipity_plugins SET placement = 'hiddenleft' WHERE placement = 'left';
UPDATE serendipity_plugins SET placement = 'hiddenright' WHERE placement = 'right';

Here's a list of which plugins could cause the memory outage:
serendipity_event_blogpdf
serendipity_event_forum
serendipity_plugin_remoterss

Maybe you could also use phpMyAdmin to look at the size of your serendipity_config DB table. If it's larger than 500kb or so, there is some problem!

If you don't find anything at all, I could ask you for temporary FTP access to your machine to investigate things?

Regards,
Garvin

Posted: Wed Nov 09, 2005 9:01 pm
by PENorwood
The table is only 277 KB ... checking on the other things right now

Posted: Wed Nov 09, 2005 9:03 pm
by PENorwood
Using the query

Code: Select all

UPDATE serendipity_plugins SET placement = 'hiddenevent' WHERE placement = 'event' AND name not like '%spartacus%';
seems to have allowed me to get past that error.

Now that I have hidden all those events, do they still work or do I need to do something to get them back?

Posted: Wed Nov 09, 2005 9:08 pm
by PENorwood
I ran the query

Code: Select all

UPDATE serendipity_plugins SET placement = 'event' WHERE placement = 'hidden' AND name not like '%spartacus%';
to reverse the temporary condition and when I went back in all was working with no errors at all ... strange. What could have caused this and how did something like this affect it at all?

I spoke too soon ... I got the error the second time I tried to go in. I just disabled the pdf event plugin and it seems to work. Crossing fingers :?

Posted: Wed Nov 09, 2005 9:10 pm
by garvinhicking
You'll need to re-enable the plugins one by one, I'm afraid. One of them will cause heavy system load.

Use phpmyadmin to browser your serendipity_config table and successively set placements from 'hiddenevent' to 'event' and check your s9y after each enabled plugin.

What you can also do is this, edit your include/plugin_api.inc.php file. Go to about line 390, where the &load_plugin method is declared.

Change this code:

Code: Select all

        if (!class_exists($class_name) && !empty($pluginFile)) {
            // $serendipity['debug']['pluginload'][] = "Classname does not exist. Including $pluginFile.";
            include_once($pluginFile);
        }
to this:

Code: Select all

        echo "Memory usage before loading plugin $pluginFile is " . memory_get_usage() . "<br />\n";
        if (!class_exists($class_name) && !empty($pluginFile)) {
            // $serendipity['debug']['pluginload'][] = "Classname does not exist. Including $pluginFile.";
            include_once($pluginFile);
        }
Note the first line, where your current memory usage is told. You will get some "Warning, header already sent" errors then, but don't pay attention to them, just search for the message listing. If you saw which plugin is causing a huge memory increase, you can remove that line again and tell me which plugin it was, then I can introspect if it's possible to lower its usage...

Regards,
Garvin

Best regards,
Garvin

Posted: Wed Nov 09, 2005 9:27 pm
by PENorwood
I did as you suggested and saw no large increases in memory usage. Even after I put back export to pdf.

Perhaps there was an error when I first installed export to pdf and deleting and resetting fixed it? Also, once I was able to run Spartacus I noticed there was an update available for export to pdf ... maybe this fixed it as well?

In any case all seems to work fine now.

THanks!

Posted: Wed Nov 09, 2005 9:50 pm
by garvinhicking
Well, I forgot about an important issue. Once that spartacus was properly run, it parsed the XML plugin data and cached it in a DB table. And now the memory intensive compiling of the XML data is no longer performed because of the cache.

Once the cache needs purging (after 24 hours) you will sadly hit the limit again, I'm afraid. :-/

You can force purging the spartacus cache by going to the s9y config panel, select the spartacus plugin (click on it) and then enter its config screen. There you just click on "Save" and it will purge the XML cache...

Regards,
Garvin

Posted: Wed Nov 09, 2005 10:20 pm
by PENorwood
Once again I spoke too soon ... this is getting frustrating. It works if I just want to look at the available plugins but if I try to update or install a new one it fails ... I think the problem is the export to pdf event, which really is not necessary I guess ... just a nice feature.

It does seeom to use up about 500k or memory when turned on, so for now I will leave it off.