I decided to update from Buster to Bullseye today.
I’m running on my Rpi4 an Nginx server with Organizr, that also works as a reverse proxy for all my services.
My services didn’t seem to encounter any error, it all went smoothly. They all work, Nginx work, accessing with the reverse proxy works.
However, I can no longer access Organizr on the root of my domain. I get a “502 error”.
In my network debug tab on my browser, there is nothing special except the html 502 error I get.
I don’t know where I can seek for more infos, and I don’t know what’s causing this.
It’s a bit annoying as it puts a whole part of my setup down.
Where should I search for more info ? Is it common when upgrading to Bullseye ? What should I do ?
Thanks in advance for any answer, have a great day.
Did you setup Nginx manually to serve Organizr at the root of your domain? If you followed our distro upgrade guide, a reinstall of Nginx is triggered, so it may have reverted some customisations done to /etc/nginx/nginx.conf or /etc/nginx/sites-available/default. The previous files should however be present with a backup suffix.
Else, does /var/log/nginx/error.log contain anything after you try to access Organizr?
I just checked the /etc/nginx/sites-available/default file and it is correctly set to the path of my organizr folder (/var/www/organizr.local/html).
I checked the error logs from nginx, it says this :
2021/10/10 18:42:13 [crit] 27704#27704: *1 connect() to unix:/run/php/php7.3-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /?error=502 HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.3-fpm.sock:", host: "mydomainremovedforprivacy.com"
2021/10/10 18:42:13 [crit] 27704#27704: *1 connect() to unix:/run/php/php7.3-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /?error=502 HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.3-fpm.sock:", host: "mydomainremovedforprivacy.com"
2021/10/10 18:42:13 [crit] 27704#27704: *1 connect() to unix:/run/php/php7.3-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /?error=502 HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.3-fpm.sock:", host: "mydomainremovedforprivacy.com"
2021/10/10 18:42:13 [crit] 27704#27704: *1 connect() to unix:/run/php/php7.3-fpm.sock failed (2: No such file or directory) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /?error=502 HTTP/2.0", upstream: "fastcgi://unix:/run/php/php7.3-fpm.sock:", host: "mydomainremovedforprivacy.com"
2021/10/10 18:42:22 [error] 27704#27704: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /webmin/stats.cgi?xhr-stats=general HTTP/2.0", upstream: "http://[::1]:10000/stats.cgi?xhr-stats=general", host: "mydomainremovedforprivacy.com", referrer: "https://mydomainremovedforprivacy.com/webmin/filemin/?xnavigation=1"
2021/10/10 18:42:36 [error] 27704#27704: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "POST /webmin/index.cgi/?xhr-get_nice_size=1&xhr-get_nice_size_sum=65865 HTTP/2.0", upstream: "http://[::1]:10000/index.cgi/?xhr-get_nice_size=1&xhr-get_nice_size_sum=65865", host: "mydomainremovedforprivacy.com", referrer: "https://mydomainremovedforprivacy.com/webmin/filemin/?xnavigation=1"
2021/10/10 18:42:47 [error] 29545#29545: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /webmin/stats.cgi?xhr-stats=general HTTP/2.0", upstream: "http://[::1]:10000/stats.cgi?xhr-stats=general", host: "mydomainremovedforprivacy.com", referrer: "https://mydomainremovedforprivacy.com/webmin/filemin/?xnavigation=1"
2021/10/10 18:42:59 [error] 29545#29545: *1 connect() failed (111: Connection refused) while connecting to upstream, client: 8.40.31.33, server: mydomainremovedforprivacy.com, request: "GET /webmin/help.cgi/authentic-theme/editor HTTP/2.0", upstream: "http://[::1]:10000/help.cgi/authentic-theme/editor", host: "mydomainremovedforprivacy.com", referrer: "https://mydomainremovedforprivacy.com/webmin/filemin/?xnavigation=1"
Looks like it’s seeking for PHP 7.3, and if I understood correctly Bullseye updates to PHP 7.4.
So I guessed that my nginx didn’t got reinstalled correctly.
│ APT update
│ - Command: apt-get -q update
│ - Exit code: 100
│ - DietPi version: v7.6.2 (MichaIng/master) | HW_MODEL: 4 | HW_ARCH: 2 | DISTRO: 6
│ - Image creator: DietPi Core Team
│ - Pre-image: Raspbian Lite
│ - Error log:
│ Hit:2 http://raspbian.raspberrypi.org/raspbian bullseye InRelease
│ Hit:3 https://packages.sury.org/php bullseye InRelease
│ Hit:4 https://archive.raspberrypi.org/debian bullseye InRelease
│ Hit:5 https://apt.ombi.app/develop jessie InRelease
│ Hit:6 https://apt.hrfee.dev trusty InRelease
│ Hit:7 https://repo.jellyfin.org/debian bullseye InRelease
│ Ign:8 https://download.mono-project.com/repo/debian raspbianbullseye InRelease
│ Ign:1 https://pkg.cloudflareclient.com bullseye InRelease
│ Err:10 https://download.mono-project.com/repo/debian raspbianbullseye Release
│ 404 Not Found [IP: 2606:2800:133:206e:1315:22a5:2006:24fd 443]
│ Err:9 https://pkg.cloudflareclient.com bullseye Release
│ 404 Not Found [IP: 2606:4700::6810:550f 443]
│ Ign:11 https://download.webmin.com/download/repository sarge InRelease
│ Hit:12 https://download.webmin.com/download/repository sarge Release
│ Reading package lists...
│ W: Target Packages (main/binary-armhf/Packages) is configured multiple times in /etc/apt/sources.list:1 and
│ /etc/apt/sources.list.d/pivpn-bullseye-repo.list:1
│ W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:1 and
│ /etc/apt/sources.list.d/pivpn-bullseye-repo.list:1
│ E: The repository 'https://download.mono-project.com/repo/debian raspbianbullseye Release' does not have a Release
│ file.
│ E: The repository 'http://pkg.cloudflareclient.com bullseye Release' does not have a Release file.
│ W: Target Packages (main/binary-armhf/Packages) is configured multiple times in /etc/apt/sources.list:1 and
│ /etc/apt/sources.list.d/pivpn-bullseye-repo.list:1
│ W: Target Packages (main/binary-all/Packages) is configured multiple times in /etc/apt/sources.list:1 and
│ /etc/apt/sources.list.d/pivpn-bullseye-repo.list:1
So I think the problem comes from me who got my apt repo wrong. But I don’t know how I can repair that.
My /etc/apt/sources.list file only contains :
deb http://raspbian.raspberrypi.org/raspbian/ bullseye main contrib non-free
So I’m not sure how to fix these errors. Could you help me on that ? (if it is what’s causing my problem with nginx, I’m still not 100% sure).
Thanks in advance for any answer, have a great day
Mono did not support Bullseye yet and would need to switched back to Buster. Pls have a look into /etc/apt/sources.list.d directory. There should be a mono.list file
According Cloudflare install guide, you would need to use HTTP instead of HTTPS https://pkg.cloudflareclient.com/install
Should be in file /etc/apt/sources.list.d/cloudflare-client.list
Thanks for your answer.
My apt repos are correct now ! Apt update runs without errors, which allowed me to update Dietpi to the latest version.
But the root page of my Nginx server is still broken with the 502 error. Do you know where I should search for this ?
Thanks in advance for your help,
Have a great day
I finally succeeded to reinstall all the softwares recommended to reinstall by the official dietpi guide. It reinstalled a lot of things including nginx and php. I had to re-configure some nginx settings so it redirects to my organizr folder with correct arguments. And it works ! My organizr is fully working, my apt repo are correct. Everything is fixed ! Thanks a lot for your help about the repos ! Have a wonderful day !