Return 200 But the page crashes, post is empty TTFB 10 minutes?

Source: Internet
Author: User


1. What is this? Remembera surprise (Shi) Heart (fen) (NAO) Soul (CAN) of the online bug fix! 2. What happened?

Say to work hours, lonely just read the plate (MOM eggs fell off) is enjoying the yogurt. All of a sudden the crowd snapped a few noises. The message bounced directly to the brother's desk--brother was AI!

The original is the operation of small brother.

"Just brother, upload the file is not!" ”

"Just brother, the page crashed!!" ”

"Just brother ..." ”

Elder brother very calm: "What situation ah, OK is a bug?" ”

The operation of small brother is still very experienced. PA pa A few sound, and put the steps and data all the way to the elder brother sent over.

Brother took the data to go again, get to the problem immediately. The original is-when uploading files too large 3m/file 12m/total (big?) ) caused the browser to strike directly (it is not expected to get back to sentimental).


3. Then what?

Then of course is hurriedly find the reason to fix the problem ah. After all, on the line, a second in and out of the hundreds of thousands of line Ah!

First grab a bag to see, I rub, 200 ah, everything is very harmonious ah. Then why did you turn so long, Daisy? Why did you just crash?

Look at timing:


TTFB, what the hell, it took 10 minutes!

Hurry and look at Nginx log:


Hey... You've really spent 10 minutes.

Look again, PHP log:

Pop, the POST parameter is empty. Hurry and look at the other requests, no problem. There's a problem with that. A fright.

Ask the left, "is it online?" "No", right, "Is it online?" "No," he said. ”

Since the same set of code requests, only the file over 3M has a problem, and has not been in the code, that decisive is the problem of configuration.

Possible causes:

Nginx Configuration:

Well, there's no flaw.

Ini:


Hey, it's not you, what's the trouble?

It may be because of the problem of upload_max_filesize , decisive change to 8M try, this time the page did not crash, but because the data in the post is still empty, so logically definitely wrong,

The TTFB still took 4 minutes, but a lot less. Feel the hope of seeing :


Forget it, change all of the above into a pair of M bar, with nginx corresponding. After all, I uploaded the file is the 12M of the giant. Gee, yes, I uploaded the file is 12M ah. Why did I change to 8M, the brain is disabled.

Gee, sure enough, this time, it's a success. Oh... Mom eggs, this should not be an error? Shouldn't I just do a 500 out and tell me upload_max_filesize limit or something? How the whole 200 to me.

Let brother check the long time ... [CRY]:

4Postscript

You see, that's the way to solve the problem, back 100. Is life not the same? Road winding rugged, bumpy road, even if there is a train of thought, even if there is a direction, but also because of a temporary brain residue and take two more steps.

So, when we have a twist in life--forget it, don't pretend to force. Come home from work. There is no food in the canteen.


Return 200 But the page crashes, post is empty TTFB 10 minutes?

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.