Forum Replies Created
-
AuthorPosts
-
in reply to: Stripe Integration #16452
Yes. It’s one query, and it’s not close.
The query breaking your server:
sqlSELECT p.*, pi.*
FROM cart_products p
LEFT JOIN cart_product_images pi
ON (p.productid = pi.imageprodid AND pi.imageisthumb = 1)
WHERE p.prodvisible = 1
AND productid != 98898
AND FIND_IN_SET(78, prodcatids)
AND prodavailability = ‘unreserved’
AND prodcurrentinv != 0
AND levenshtein_ratio(‘(813) 896-2999’, prodname) > 60
ORDER BY levenshtein_ratio(‘(813) 896-2999’, prodname) DESC
LIMIT 5;Run by database user excellen_shaz on schema excellen_vip3. It’s the “similar phone numbers” widget on your product detail pages — it fires once per product page view.
What it did on 09-09-2026:Executions
9,531 of 9,783 in the log
Share of all database time99.88%
Total time consumed5,600,935s = 1,556 hours in one day
Rows examined per run594,007
Rows returned per run5
Average runtime588s
Worst single run6,406s — 1 hour 47 minutes
The worst five executions of the day, all this same query:
StartedEnded
Duration
Thread
06:10:1307:56:59
107 min
56412
05:30:3207:16:35
106 min
54410
05:29:4207:13:55
104 min
54364
05:59:5807:43:51
104 min
55765
06:52:3408:31:01
98 min
58620
229 executions ran longer than an hour. 2,096 ran longer than ten minutes. All of them this query.
Why it kills the server specifically:
The levenshtein_ratio() user-defined function has to be computed on every single one of the 594,007 rows — and then a second time for the ORDER BY. That’s roughly 1.2 million UDF calls per execution, each one pure CPU with no index able to skip a single row. FIND_IN_SET(78, prodcatids) guarantees the full scan on its own, since categories are stored as a comma-separated string.
The mechanism that turns a slow query into an outage is the pile-up. Each page view starts a new copy. At peak you had 218 running at once, each burning CPU on 1.2 million function calls. They starve each other, so each one gets slower, so more accumulate. Average concurrency across the whole 24 hours was 65.9 and it never dropped below 19.
Two pieces of evidence confirm the query itself is the cause rather than a victim of general server load:The isolated manual run by user excellentnumbers — same query, run by hand with far less contention — still took 98 seconds.
Three executions examined zero rows and still averaged 859 seconds. They weren’t doing work; they were queued for CPU that never came. That’s starvation caused by the other copies.The single fastest thing you can do right now is SET GLOBAL max_statement_time = 30;. It doesn’t fix the query, but it makes it impossible for one to run for 107 minutes, and it would have killed all 229 of the hour-long executions before they could stack up.
in reply to: Stripe Integration #16446Oh sorry about that Nishit, the link in #16445 same document whcih is in #16441 = https://webmaklay.com/slow-query-analysis-new.md
🙂in reply to: Stripe Integration #16442Oh in addtiong to above, Nishit you can rund DB back up from your cPanel access we can only perform full back up which we will do soon for your DB improvments (files atatched)
https://techlyncs-my.sharepoint.com/:t:/r/personal/salman_techlyncs_com/Documents/Attachments/slow-query-analysis-new.md?d=we4c5ea0dac2d4e388893b1dfa89fe8e6&csf=1&web=1&e=ndekB0-
This reply was modified 2 weeks, 4 days ago by
Andrey.
in reply to: Stripe Integration #16441Hello Nishit thank you for your reply,
could you please advice what is this 1 serioal number of? could you please remove it we did not have it before and En team do not want to see it there.i aslo checked your video and can not see you changed buttons and other points mentioned from #16402 below:
1. Down Time task: Yes we will need to updated the coding for those queries to reduce the calls to DB.If you not surpriced then i assume you knew the issue and im now surprised you as exepreieced developer not mentioned that and not updated it as we always ask you to use modern codings and this puts EN proeject under huge risk. So please thoese queries are mentioend in Jeffs report need to be imroved. And as a kindly reminder on ANY tasks we give you we rely on your profecionalism and experience to be able forcast such a truble and risks and implemenet contemporary codings. Now it sounds that we never told you this and we facing this issues builded up by the time:(
P.S System team attached an other document for you with full EN investigation report and possible resolutions to fix it asap. Please find it here.
2. Sand Box: – We can not do anything at this stage really as EN admins did not get back to us about about the time to switch back to Sanbox.
3. Compamy Name as i could see from your video removed from compolsory but if any field missed during regestration does the proper hint displayd (for example ” Phone Number filed is missing “) loading gifs, messages “please wait” and ect? We do not want EN team repeat it again 😉
4. Does all redirects working and centered on the login page? Aslo when email verifications requestsr is everything clear that customers not being confused and do not know that notifications email been sent, and if any processes going behind the sceen customers are aware that processing messages or loading gifs come up. Will the customers know about verification process exeration time and so on?
5. PortOut Validation i could see the process on your video but we still could not see you applied our recomendations about the buttons, allignemnts, font and ect. ( We know that firist time we did not provided such details and you did it as you think is good so no issues with that but now we have got clear instriuctions on changes and thus will add more funds for this task to your EN credit.) Please make this PortOut Validation with better look we know you can:)
6. I noted in your video the popup has now got X close icon, but i aslo noted that when you clicked APPROVE there had been sime time before pop up window actually appeared and there was no any loading gif come up or ” please wait” message apeared. Buttons are still the same and especulay ugl cancell button not been changed:(
It is preety quick process between AProve and pop up but you can see still it takes some time which is DB queries and coding language that we need to do and already mentioned above.
SAMARY
Please Nishit finish all the #16402 points details and please fix the DB/coding issue – those that causing major problems, aftre nanotelecom we will probably get all the DB coddings review and upgarde job – which will need to confirm with EN team as they alwasy belive that during all developemnet we always use new and modern coding technics and this is why they paying for.
in reply to: Messenger App #16436Hello Dave, thank you for your message, i have sent system team your video and conserns they are still investigating this matter, i will let you know when they provide more information.Curretnly the invormation i have is not supported by any evedence will give you updates with verified info;)
in reply to: Stripe Integration #16434Hello Nishit thank you for your video and removing Company Name from compolsory and fixing these #16402.
Today we have got more complains from EN team they site was down somtime again and we have spoken to system team. They are running more detailed investigation but for now they said that EN cause multiple stresses to the hosting DB.the main reason for this issue is Long sql queries and queries without index – could you please let me know if you can improve it? The reason for this is that if we can not do it there maybe some other developer will have to have a look at that which we all do not want.
Here are just some examples:
1. Today whet the site was loading very slow we found that the DB got very bussy loading with EN DB queries. So we treid to conect to it many times from desk top or mobile phone but interestengly enough when we open EN from a mobile we’ve suddently seen a login page from OLD mobile version of EN. Since we move the site to responsive we were very surpried that EN opened an old login page from old EN mobile site.So we started thinking maybe this is the problem when we loading the pages some queires featching old EN mobile version mixed with responsive and this makes the laoding time more dificult and stressed.
2. En other example when we look the EN DB we can see some queries take a VERY long time to connecting and when we checked some tables we cound some of the tables are very heavy please see this here
Could you please advice do we need this table and if so can we drop it and set up a sync script for droping this table if it is over certain level. O was going to drop it myself but i was afraid to do smothing wrong that may harm any of your works. Our system team also suggested to consult with you. Could you please advice ASAP.
I think f we drop this 2.5GB table it will bring some releave for DB too.
So as above we should make EN DB very light and flowing as a fresh wind so people could use EN as they want without stress and down times this is byt the way on of the jobs we should do and reported back that it is not working mentioned in #16402
in reply to: Custom Works #16430Hello Nishit got you, thank you for your #16428, well im also not a server guru i will forward your suggestion to the system team to have a look!
How is other things going Nishit when do you think we can show your work to nanotel team?
in reply to: Stripe Integration #16429Thank you Nishit!
in reply to: Stripe Integration #16426Nishit is there any updates for #16402?
for #16412 i have adviced to customer clear all the cache to make sure they are not seeing some of the cached error pagethank you Nishit!
in reply to: Custom Works #16425Hello Nishit thank you for the goodnews fixing hidden error issue on the login page!
For .us VS .com domain as mentioned before the .com domain is the primary domain and nanotelecom customer they want to put an A Record for the AWS project so when people click on portal.nt.com address they will go to portal.nt.us customers portal page BUT on the broeser it will be shown as portal.nt.com curretny it does not work for some reason.Could you please double check that we no lonher have any urls issues on AWS .us project as we expecting many customers coming to nt.us from nt.com site and we want that all the customers see nt.com address while they are on nt.us AWS host 😉
Kind regadrs Andrey
in reply to: Stripe Integration #16424Hello Nishit thank you for your updates,
For error code i have been also seeling loading pages are good and not noticing any error pages, bute EN site admins they always do multiple operations of the site loinging in as admin sometime they login as other customer and as they say they sometime visiting pages tens or hudreds of times and on some points when then do some refund works or logining back to En admin concole they seeing this issue.So your #16410 and #16412. are clear i aslo can clik n site admin page and see login page well but there is still somthing behind the sceene when EN team perform multiple processes it happends.
So we will need to think of what can cause this issue im aslo with system team about the same.
in reply to: Messenger App #16421Hello Dave your video had been sent to system team for investigation, yes it seems that something is also going on the WEB side and they are going to look at that to find out.
Meanwhile can i please ask you to inspect crushihg issue mentioned in this ticket
Once fixed could you please prepare IOS copy of the app for testing and if no crushing or other (non server related issues) we will need your APK source code and hopefully close this job.
Kind reagdrs Andrey
in reply to: Custom Works #16420Hello Nishit i know you still working on this project login form and other areas, but just letting you know that today customer contacted us and they know that we have moved the content to the nanotelecom.us AWS account, so they asked some questions as : – :where is the admin part” so i told them where it is and also they asked me: – “where are customers numbers” so i told them that it is in portal but we still working on it.
Then after somtime they contacted me and said that they are started tp set up their nanotelecom.com A record links to these areas and looking forward when they can test it.
However thay mentioned when they set up an A record for a portal directory the directory is not being openeing as expected and they belive that this is the issue on the site:
So when the set up an A Record for directory as portal.nanotelecom.com that should lead to portal.nanotelecom.us but when we tested it is not working please see this yourself. https://portal.nanotelecom.com and see where it goes.
i think the link not working because the previous issue that we have had with “www” was not in the address and somthing tells me that now Nanotelecom team experiencing same problem.
So could you please check these addresses issues so any way nanotelecom input will lead to the site no matter if www there or http or https there it should open their site so they can set up a links A records or whate ever they want to set it 100% worsk 😉
This project is under developement and o mentiooned that but i can see that if they aready saying about link not being A recorded we may have a very thourogh testing once you done:)
Please kindly have a look at that.
in reply to: Messenger App #16418Hello Dave, thanks for your video i will show the team your video and see what they say.
The server team say that the quees to the server slow because of the coding compexity other DB calls are fast enough and return data quickly from DB..
Anyway will check with them and let you knwow!
in reply to: Custom Works #16415Hi Nishit thank you for your reply, im glad you are now back and feeling better,
not a problem with fixing please let me know when we can test trying project. -
This reply was modified 2 weeks, 4 days ago by
-
AuthorPosts