Service Unavailable after Checkout

Some of my customers receive a “service unavailable” message when checking out. Here’s one I got this morning. Message from customer: “When I placed the first order I got a message SERVICE UNAVAIABLE so I placed the order again only to find the first order went through.”

I just upgraded to 4.19.1 and am using Unitheme2 (latest). I’m on PH P8.1

This has been happening even before the upgrade. I think it started happening when I started using Cloudflare.

Sometimes the email receipt to the customer has it on the email they receieve. The email receipt is otherwise fine, except where the products that they ordered are supposed to show up, there is that service unavailable image.

I had someone order 5 times over the long weekend. The orders do not show up in the admin area, the order numbers are just skipped. But when checking my credit card processor, I see that all the charges are there and now have to refund 4 of them.

I do not think it’s directly related to the upgrade I just had done,since it was happening before, but I’ve been getting more of them over that past few day where it wasn’t before.

I think it might have to do with Cloudflare, but I’m not sure at all of what to change. I have 3 cache rules enabled. An “add to cart” a “cart” and a “Print email” all to byopass the cache. I’ve had these in place for a while.

Anyone have an idea why this is happening?

when you get “seervice unavaiable” view the page source and scroll to bottom to see any error message and it it realtes to cloudfare

Do you have Bot Fight enabled in cloudfare? try it off

As for the orders, are they not in the “incomplete” orders section?

I haven’t seen the error yet since the upgrade; the customer told me about it.

I did have Bot Fight Mode enabled, and have now disabled it.

The orders are not coming in as incompleted, I did check and nothing. It seems something is interrupting the full checkout process, which gives customers an error. I’m thankful a customer said something.

I have inventory logging so if a product goes under 50 in stock I will get an email. For this customer (Whom I just refunded 4 charges), only one order came through. But I did get 5 emails from the cart telling me I only have (22) of the product in stock. All of the emails came in at separate times, coinciding with the number of orders that were placed and the charges I seen in my processor. However, all of the emails said the same number of products remain in stock. So that has to tell something. Cs-cart didn’t keep decreasing inventory for each email. It still thought the inventory was only decreased by 1, yet it still sent all those emails saying the same thing.

I also spent about two hours with chatgpt trying to troubleshoot going through log files trying to find a 500 error but we were unsuccessful. It’s probably there, but that’s not my area of expertise and the AI kept going down different paths. I had to stop so I could get actual orders shipped out in time today.

I do have Cloudflare managing my DNS, but I gave those entries to chat and it said it was fine other than a C Name entry for www being proxied. It said to unproxy that one and go DNS only, but it also said that wasn’t the issue.

NEW - That same customer gave an email: "I would just like to make sure I’m only getting one order of 4 throwing stars because something was messing up when I ordered it because on my bank info it says I did my order like five times which is a mistake "

Not real helpful, but he says something was messing up. : ) Which I do think is happening more than just him, because orders have dwindled. I first thought it was of the holiday, but I do not think so anymore.

Any other ideas?

This is a different customer from today that I had to refund. He replied to the refund: "I pressed it twice and was charged twice . Both times it said it was not processed so I will get another refund as well I assume "

I let him know we’ve already shipped his order, that it came through only once on our end, but charged twice. He had the Service Unavailable image inside his email that he forwarded to me. It is the standard cs-cart image for service unavailable when you run into a 500 error.

EDIT: I have downgraded to PHP 8.0. Not sure if it’ll help any, but it was suggested.

The error should be logged in the server error logs. So check order time at first and then try to find error details on the server logs at this time

1 Like

would you like me to try a test order.(from the uk) .if so provide the url

I got it fixed. I think it was a combination of an old checkout and going back and forth with PHP versions. I got a new checkout installation and am not switching PHP versions without deleting the cache folder. Orders are coming in, and no complaints. I no longer have Cloudflare set up, except for DNS management. All of my DNS records are DNS only, with none proxied. I know this bypasses Cloudflare, but I’m at a good spot right now and will let it ride for a bit. I see an email receipt showing the “Service Unavailable” image, which was sent before I started the upgrades, so I’m not sure whether everything is fixed with the updated versions. I spent a day looking through log records with Chat and trying different things. I ended up with it working so it’s all good for now. Thanks for the suggestions and help!

2 Likes