Score:0

nginx (+ php-fpm) sometimes returns http code = 499

br flag
Vv.

I have a script.php that is called via curl and runs for about 40 minutes.

Sometimes the script just stops in the middle.

In nginx access.log script call completes with strange http code 499. There are no errors in php-fpm logs.

In php config max_execution_time = 9000

I implied that the problem may be in the timeout and set in the configuration nginx with a large margin fastcgi_read_timeout = 2h; but the problem is not solved.

Which way to dig, since there are no errors in the logs.

Richard Smith avatar
jp flag
This is an Nginx specific status code that means **client has closed connection** before the server answered the request.
br flag
Vv.
@RichardSmith In this case, the client is the one who calls script.php - right? Cron calls script.php via curl request - no errors when working through Apache, but on Nginx periodically breaks with code 499. Consequently, something is wrong in the configuration of Nginx, but I have read the documentation several times, corrected seemingly the right variables, but the problem does not go away.
sv flag
Please see this solution... https://stackoverflow.com/a/59724098/1004587
br flag
Vv.
@PothiKalimuthu Thanks for the tip, unfortunately, I edited the correct config))
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.