1

I've been trying to use Apache2 to put an SSL certificate on my Ubuntu Server 18.04.4 LTS for Nextcloud, and I can't even get a far as to start Apache. I keep getting this error:

Error Picture

I've looked up solutions to this and found about a hundred of them, each of them not working, or I just don't know how to solve it properly.

Help would be much appreciated, I've been suck on this for a few days now. :(

Beto Damian
  • 11
  • 1
  • 1
  • 2

3 Answers3

1

there is already something bound to that port, that's why apache complains.

Try this to find out what is using port 80/tcp:

# ss --listening --tcp --numeric --processes

you should get a list of open listening sockets with the local address:port combination and the process that has opened each of them. Find out which one has opened port 80, stop that process and start apache again, it should work.

natxo asenjo
  • 5,739
  • 2
  • 26
  • 27
0

the solution for me is:

  • allocate in this path /snap/nextcloud use unlink to remove all link in this location.

  • use ps -edaf | grep http and kill -9 all httpd processes.

mforsetti
  • 2,666
  • 2
  • 16
  • 20
0

Per Nextcloud

Enabling SSL

You can use Nextcloud over plain HTTP, but we strongly encourage you to use SSL/TLS to encrypt all of your server traffic, and to protect user’s logins and data in transit.

Apache installed under Ubuntu comes already set-up with a simple self-signed certificate. All you have to do is to enable the ssl module and the default site.

Open a terminal and run:

a2enmod ssl
a2ensite default-ssl
service apache2 reload

You can also may want to put your instance into maintenance mode