Hikashop cart table crashed

  • Posts: 1104
  • Thank you received: 12
  • Hikashop Business
1 month 3 days ago #367510

-- url of the page with the problem -- : www.vithos.net/
-- HikaShop version -- : 5.1.6
-- Joomla version -- : 3.10.12

Hi!

About every 10 days, i get this error that hikashop cart table crashed and i cannot enter the Hikashop control panel in backend.
The only solution i found is emptying the hikashop cart table from PhpmyAdmin but it keeps happening.
Any idea why and how to fix this?

Thank you!

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 84050
  • Thank you received: 13624
  • MODERATOR
1 month 3 days ago #367512

Hi,

Maybe it is too big because of bots ?
Next version should help.
Another thing you can try is to change the engine type of the table to innoDB instead of MyISAM via your PHPMyAdmin

The following user(s) said Thank You: verzevoul

Please Log in or Create an account to join the conversation.

  • Posts: 1104
  • Thank you received: 12
  • Hikashop Business
2 days 8 hours ago #367778

Hi!

The cart table crashes again, i updated to the latest Hikashop version.
And the weird part is that the cart option is available only for registered users, there is no guest checkout or register option for users.
All customers are added manually by the admin.
So how can it be spammed? Is there a loophole for spams in this situation?

Thank you!

Please Log in or Create an account to join the conversation.

  • Posts: 84050
  • Thank you received: 13624
  • MODERATOR
2 days 4 hours ago #367779

Hi,

Products can be added to the cart without the need to login or register on your website.
So yes, the carts can be spammed.
However, with HikaShop 6, the amount of carts created by bots should be reduced a lot.
I can see that you're still on the 5.1.6 on your website at the moment, so you're not on the latest version. Please check.

The following user(s) said Thank You: verzevoul

Please Log in or Create an account to join the conversation.

  • Posts: 1104
  • Thank you received: 12
  • Hikashop Business
1 day 13 hours ago #367784

Hi,

Can you check this https://alpin.com.gr/el/link ?
Same thing happens and there is no guest checkout or registration.

Thank you!

Please Log in or Create an account to join the conversation.

  • Posts: 84050
  • Thank you received: 13624
  • MODERATOR
1 day 8 hours ago #367785

Hi,

On this website, the add to cart button is still in the products' HTML.
However, there is some CSS code to set its "display" to "none".
So, you don't see the add to cart button in your browser, but it is still here and a crawler looking at the HTML of the page will still see it.
The update to the 6.0.0 that was done there will help reduce the amount of new carts created by bots.
Note that if you already have a lot of carts in the database, it won't be as effective at preventing crashes of the cart table. You should empty the hikashop_cart and hikashop_cart_product tables once via PHPMyAdmin for that.

However, if you don't plan on allowing non logged in users to add products to the cart, a better solution would be to remove the prices displayed to non logged in users and making sure the "display add to cart button for free products" setting to be turned off in the HikaShop configuration.
That way, it would be impossible for bots to create carts. And if you still want to display a price to non logged in users, you could do so with a custom product field.

The following user(s) said Thank You: verzevoul

Please Log in or Create an account to join the conversation.

  • Posts: 1104
  • Thank you received: 12
  • Hikashop Business
22 hours 56 minutes ago #367791

Hello Nicolas.
Is it a good idea to create a cron task that runs a script to empty these 2 tables every night?

Please Log in or Create an account to join the conversation.

  • Posts: 84050
  • Thank you received: 13624
  • MODERATOR
14 hours 7 minutes ago #367792

Hi,

I would not recommend this.

There should be a better solution than going to this extreme.
Normally, just updating to HikaShop 6 should already alleviate the problem a lot.

Also, even without updating, it's not normal that a table crashes so much.
Changing the storage engine of the table might help:
dev.mysql.com/doc/refman/8.4/en/crashing...y%20of%20the%20table .

The following user(s) said Thank You: verzevoul

Please Log in or Create an account to join the conversation.

Time to create page: 0.063 seconds
Powered by Kunena Forum