Ubuntu 12.04和Apache 2.4.9上的自签名证书

时间:2014-06-12 18:39:34

标签: apache ubuntu ssl

我正在尝试在Apache服务器上安装自签名证书。首先,我做了

sudo a2enmod ssl

并获得以下输出:

Considering dependency setenvif for ssl:
Module setenvif already enabled
Considering dependency mime for ssl:
Module mime already enabled
Considering dependency socache_shmcb for ssl:
Enabling module socache_shmcb.
Enabling module ssl.
See /usr/share/doc/apache2/README.Debian.gz on how to configure SSL and create self-signed certificates.
To activate the new configuration, you need to run:
  service apache2 restart

然后,我重新启动了apache2并收到以下错误:

(98)Address already in use: AH00072: make_sock: could not bind to address [::]:443
(98)Address already in use: AH00072: make_sock: could not bind to address 0.0.0.0:443
no listening sockets available, shutting down
AH00015: Unable to open logs

ports.conf 中,我有以下内容:

# If you just change the port or add more ports here, you will likely also
# have to change the VirtualHost statement in
# /etc/apache2/sites-enabled/000-default.conf

Listen 80


<IfModule ssl_module>
        Listen 443
</IfModule>

<IfModule mod_gnutls.c>
        Listen 443
</IfModule>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

如果我对Listen 443内的<IfModule ssl_module>行发表评论,我就不会有任何错误。但是,这似乎让我无法听取443个请求。

我能做些什么才能听听443并且没有错误?

0 个答案:

没有答案