• Home
  • Get help
  • Ask a question
Last post 3 hours 54 min ago
Posts last week 89
Average response time last week 30 min
All time posts 67735
All time tickets 10467
All time avg. posts per day 21

Helpdesk is open from Monday through Friday CET

Please create an (free) account to post any question in the support area.
Please check the development versions area. Look at the changelog, maybe your specific problem has been resolved already!
All tickets are private and they cannot be viewed by anyone. We have made public only a few tickets that we found helpful, after removing private information from them.

#4291 – Huge database

Posted in ‘sh404SEF’
This is a public ticket. Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.
Tuesday, 07 November 2017 20:10 UTC
nbussiere88
 Hello,

I have a bug I just can't find how to solve it and I need your help please.

DEV site : http://dev.xxxx.com/xxxx
LIVE site : https://www.xxxx.ca

On our DEV site, there's 232 SEF URLs and on LIVE ... there's 6606 ! Numbers are growing day after day at a point the site comes too slow to operate and finaly gets memory error :

Like : PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32 bytes) blablabla.

We searched for weeks and find suspious the fact there was 500,000 entries in sh404sef_urls table. We flushed all the SEF URLs and the site made it again fast and reliable. This is the 3rd time we do this.

Now I experience the issue again and before flushing all the URL, I suggest you have a look. I just can't find that "stop it" button on LIVE to make sh404SEF act normaly.

Can you help me please?

Thanks !
Nicolas
Tuesday, 07 November 2017 20:11 UTC
nbussiere88
Oh, everytime I post a ticket, I receive an error on your site :-)
Nicolas
Wednesday, 08 November 2017 11:11 UTC
wb_weeblr
Hi

First, thanks for the head up about the error! I think this is happening when you upload an image together with the post, right? otherwise, we don't see that. Anyhow, that's a valuable information, we can try reproduce this and then fix it.

1 - It is very important that you understand that under no circumstances sh404SEF create any URL. Never. It does not and cannot. Joomla and/or extensions on your site creates URLs, in their non-sef form. Non-sef is what Joomla uses internally, the only URLs it understands. After creating a URL for display or another usage, Joomla then asks sh404SEF to create a SEF URL for that non-sef. That's when we record the non-SEF/SEF pair in the database.

So if you have 500,000 URLs in the database, then it means your site created 500,00 URLs, and it will always regardless of whether sh404SEF is installed or not. However, when sh404SEF, those URLs are recorded and visible.

Your dev site has a small number of URL, probably because those numerous URLs are linked to traffic and users visit, which your dev site don't get.

2 -
Like : PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 32 bytes) blablabla.
This is unlikely to come from sh404SEF, as we barely use any memory on the front end. The only thing that can slow down on the front end with many URLs (ie > 100,000) is the "Similar URLs" plugin, which we use when a 404 error happens, to show similar URLs to the visitor. I would suggest you turn that off, just in case.

3 - Now the thing to do at this stage is identify which extension on your site is creating that many URLs. You seem to be using Virtuemart, a very common combination with sh404SEF. I would suggest you look at the SEF URL manager, use the component selector on the left and try identify which component is creating all those URLs. Then among those URLs, whether there are, for instance, many different URLs, or instead, you have not that many URLs, but each URL has many duplicates.

Rgds
 
Wednesday, 08 November 2017 12:09 UTC
wb_weeblr
Hi

FYI, based on your screenshot, we were finally able to pinpoint the bug in our ticketing software and fix it :) we realized the error only happens when one uploads files with the ticket, but only if there are 2 or more files uploaded!
Thanks again!

Rgds
 
Wednesday, 08 November 2017 19:26 UTC
nbussiere88
Hello !

Thanks for your reply and your tips.

I do not want to turn off the 404 functionality cause it's hot ! :-) No more dummy 404 pages, we go to the content ! I see the database has 4328 404 URL and this is the number that grows. I will try to find there's that much all coming from an external source.

The component that generate all the URL is VM. And it seems VM had gone crazy !! For one page for instance, there's.......

...... wait for it......

39571 duplicates !! :-) I need to check VM ! Did you ever saw that ? Anyway, I will check my VM configuration.

Thanks a lot for your help !
NB
Wednesday, 08 November 2017 19:27 UTC
nbussiere88
Hi again !

I check the 36k duplicates... and there are 3. See pics. How can you explain that?
Wednesday, 08 November 2017 19:28 UTC
nbussiere88
The files didn't upload because of french accents ... sorry.
Thursday, 09 November 2017 09:02 UTC
wb_weeblr
Hi

1 - 404s: it's normal to have many 404 if your site has some traffic. Most are just bots trying to either crawl content, or just attacking your site. You'll see som requests for Joomla extensions that you don't have on your site, or even for Wordpress plugins!

2 - I can't provide much background about those duplicates, sh404SEF don't create non-sef, we just record them. I have never seen VM create anything like that, so I'm pretty sure this is really specific to your site setup. Here are a few things to consider though:

- there was a large bug in Joomla 3.7.x and 3.8.0 which caused the Itemid to be modified by Joomla under some circumstances. This could cause the multiplication of URLs. Again, nothing like what you see
- you should look at a series of those duplicates, and identify what's changing from one to the other. Usually, it's just the Itemid, but is it so in your case?
- If the Itemid is the changing part, then you have to look at whatever custom modules you may have that creates links to products/categories/.... If you have such modules on each page, and they do not include the proper Itemid, then they will generate many different URLs, just differing by the Itemid.
The modules provided by VM should not do that, but maybe 3rdparty modules, or templates overrides for modules or even VM pages can be wrong on building those links.

Rgds

 
Thursday, 09 November 2017 13:51 UTC
nbussiere88
Hello !

Thank you so much for your valuable help, you're the best !

Ciao !
Nicolas
This ticket is closed, therefore read-only. You can no longer reply to it. If you need to provide more information, please open a new ticket and mention this ticket's number.