Memory problem (Add/Edit record pages not loading completely

In this board you can talk about general questions about phpMyFAQ

Moderator: Thorsten

Post Reply
rickliveops
Posts: 61
Joined: Tue Mar 27, 2007 8:57 pm
Location: Palo Alto, California
Contact:

Memory problem (Add/Edit record pages not loading completely

Post by rickliveops »

We ran into this problem today:

One of my editors reported not being able to add a new record or edit an existing one. The add/edit pages didn't load completely: the FCK Editor WYSIWYG icons didn't appear; neither did the Save, Preview and Cancel buttons.

A quick search in the Apache error log showed we were running into a memory limit. The solution was to edit /etc/php.ini and increase the memory_limit from the default of 8MB to 32MB. The add/edit pages now load completely, though still a bit slowly.

Hope this helps.

Rick
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

how many records do you have?

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
rickliveops
Posts: 61
Joined: Tue Mar 27, 2007 8:57 pm
Location: Palo Alto, California
Contact:

Post by rickliveops »

Not so many that I think this would impact performance:

Visits
18165
Articles
451
Comments
2
Open Questions
251

mysql> select count(*) from faquser;
+----------+
| count(*) |
+----------+
| 5363 |
+----------+

Surely, php and mySQL should be able to handle 100 times this amount of data with no problem?
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

uh.... I never tested phpMyFAQ with this amount of users, I only optimized the queries for categories and records... Maybe there are some un-optimized queries on the user table..

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
rickliveops
Posts: 61
Joined: Tue Mar 27, 2007 8:57 pm
Location: Palo Alto, California
Contact:

Post by rickliveops »

Ah, that might explain why there is the problem of the User list not populating beyond a certain number of users (in the User admin page, which I reported a while ago).
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

that could be the problem, because 5K users in a select box is also hard to render for the browser...

Is it possible to get a SQL dump of your database?

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
rickliveops
Posts: 61
Joined: Tue Mar 27, 2007 8:57 pm
Location: Palo Alto, California
Contact:

Post by rickliveops »

I sent a copy of the database to thorsten@phpmyfaq.de. Did you receive that?

I've upgraded to 2.0.3 but it doesn't appear that this bug is fixed there yet.
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi,

I received it. I'll try to add a fix in 2.0.4.

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
rickliveops
Posts: 61
Joined: Tue Mar 27, 2007 8:57 pm
Location: Palo Alto, California
Contact:

Post by rickliveops »

Hi Thorsten

Although upping the memory limit to 32MB as I reported earlier made the page load completely, it is still extremely slow to load, taking 2 or 3 minutes even for a short article (or a brand new one) (so it is not the article data that is slowing things down). As you said, it might be the number of users.

Has this problem been fixed in 2.0.4?

Rick
Thorsten
Posts: 15562
Joined: Tue Sep 25, 2001 11:14 am
Location: #phpmyfaq
Contact:

Post by Thorsten »

Hi Rick,

sorry, not yet. I'm still in time trouble. :-(

bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
Post Reply