Last one (I think): where is the Nginx parameter set for the SSL certificate?

Nginx is failing on start up. Complains that the SSL cert for the admin user or main domain is missing. But the domain it is trying is from when I was testing and the production domain is different.
Let it be known that the user-data folder was copied over from an existing MiaB where the server seems to be failing (it is going very very slow).

FAILED: service nginx restart


Job for nginx.service failed because the control process exited with error code.
See “systemctl status nginx.service” and “journalctl -xeu nginx.service” for details.

home**$ systemctl status nginx.service

× nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2024-05-01 16:27:47 MST; 1min 53s ago
Process: 18572 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=1/FAILURE)
May 01 16:27:46 mail.server.pminj.org systemd[1]: Starting A high performance web server and a reverse proxy server…
May 01 16:27:47 mail.server.pminj.org nginx[18572]: nginx: [emerg] cannot load certificate “/home/user-data/ssl/ppgcloud.com-20240226-8c875793.pem”: BIO_new_file() failed (SSL: error:80000002:system library::No such file or directory:calling fopen(/home/user-data/ssl/ppgcloud.com-202>
May 01 16:27:47 mail.server.pminj.org nginx[18572]: nginx: configuration file /etc/nginx/nginx.conf test failed
May 01 16:27:47 mail.server.pminj.org systemd[1]: nginx.service: Control process exited, code=exited, status=1/FAILURE
May 01 16:27:47 mail.server.pminj.org systemd[1]: nginx.service: Failed with result ‘exit-code’.
May 01 16:27:47 mail.server.pminj.org systemd[1]: Failed to start A high performance web server and a reverse proxy server.

home**$ journalctl -xeu nginx.service

May 01 16:27:47 mail.server.pminj.org nginx[18572]: nginx: [emerg] cannot load certificate “/home/user-data/ssl/ppgcloud.com-20240226-8c875793.pem”: BIO_new_file() failed (SSL: error:80000002:system library::No such file or directory:calling fopen(/home/user-data/ssl/ppgcloud.com-202>
May 01 16:27:47 mail.server.pminj.org nginx[18572]: nginx: configuration file /etc/nginx/nginx.conf test failed
May 01 16:27:47 mail.server.pminj.org systemd[1]: nginx.service: Control process exited, code=exited, status=1/FAILURE

I looked and googled a whole lot and I can’t find where this parameter is being set. It needs to be refreshed to the correct value. All the correct SSL certs are in the directory specified where it can not find the SSL cert with which it is incorrectly looking.

sudo nginx -s reload [doesn’t work unfortunately]

nginx: [emerg] cannot load certificate “/home/user-data/ssl/ppgcloud.com-20240226-8c875793.pem”: BIO_new_file() failed (SSL: error:80000002:system library::No such file or directory:calling fopen(/home/user-data/ssl/ppgcloud.com-20240226-8c875793.pem, r) error:10000080:BIO routines::no such file)

Searched for another hour or so and found that the issue was this file;
/etc/nginx/conf.d*/local.conf

It had the list of all the domains from the previous set up. I copied the file from the misbehaving server. Got past the Nginx part of the install but then failed at

Installing Munin (system monitoring)…

FAILED: apt-get -y -o Dpkg::Options::=–force-confdef -o Dpkg::Options::=–force-confnew install munin munin-node libcgi-fast-perl

E: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 52539 (apt-get)
E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), is another process using it?

I give up. Going to start over and reinstall Ubuntu 22.04 from scratch. Will take me less than an hour…

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.