-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: upstream prematurely closed connection error after updating PHP versions #254
Comments
Hm is this related to laravel/valet#1433 ? |
I tried some solutions on this, but it didn't work. I tried adding some fastcgi params like: laravel/valet#1433 (comment) I also tried adding this: laravel/valet#1433 (comment) to the Then I removed Herd completely from my computer and installed it again, the issue was still happening. Tried the solutions above again and the issue is still happening. IDK what to try anymore. |
It seems that this problem cannot be reproduced in the existing running environment. I used the following steps:
I first tried the above steps on Ventura and then on a clean Sonoma virtual machine, but the problem did not occur. Did I miss something? |
Exact same problem here. When a Postgres connection is made, the Nginx upstream error triggers. All was working perfectly before upgrading to PHP 8.2.13. Herd 1.3.1, PHP 8.2.13 or 8.3 |
I am having same issue on PHP 8.2.13. I have debugged it and PHP PDO class causes the error with only Postgres. Herd 1.3.1, PHP 8.2.13 or 8.3 Is it possible to send rollback update until php fixes the issue? @mpociot |
I was also having the same issue with connection to PostgreSQL databases Herd: Version 1.3.1 (Build 18) I've done some testing and found if postgres has SSL mode on, the 502 Bad Gateway happens. |
Thanks for the SSL hint! |
Thank you so much @mpociot! |
Can you share how you build PHP for Herd by any chance? Configure options? |
It looks like this bug is not isolated to Herd. I'm running Homebrew php 8.3 and Postgres 14 standalone — with the same error. |
@thomas-shirley Yeah, it's related to the specific openssl version that was used in combination with postgresql |
Looks like this bug is being tracked in Homebrew core: Homebrew/homebrew-core#155651 |
Operating system version
macOS Sonoma 14.1.1
System architecture
Intel (x86)
Herd Version
1.3.1 (Build 18)
PHP Version
PHP 8.2.13 and PHP 8.3.0
Bug description
After updating my PHP versions to PHP 8.2.13 and PHP 8.3.0 I started to get this error:
The weird thing is that this is happening only with endpoints that access a PgSQL DB. The application uses two DBs, a MySQL one and a PgSQL one. All endpoints that are accessing the MySQL one only are working, but all endpoints that access the PgSQL DB are resulting in this:
And when I check the logs the error above and on the Relevant log output are being added to the log file.
I already did some research and tried some solutions that I saw happening with Valet. Tried to uninstall and install Herd and the issue wasn't fixed.
This started to happen today after I updated my PHP versions on Herd.
Steps to reproduce
I can't share the repository since it's private, but a simple Laravel app that accesses a PgSQL DB with a simple query should be enough to check this behaviour.
Relevant log output
The text was updated successfully, but these errors were encountered: