配置apache2 https

版本:Apache/2.4.23
很简单

加上下面的link文件就可以了,分别在mods-available和sites-available(默认没有下面的link文件)

lrwxrwxrwx 1 root root   40 Feb 16 19:29 000-default-ssl -> /etc/apache2/sites-available/default-ssl
lrwxrwxrwx 1 root root   45 Feb 16 19:32 000-default-ssl.conf -> /etc/apache2/sites-available/default-ssl.conf
lrwxrwxrwx 1 root root   26 Feb 16 18:17 ssl.conf -> ../mods-available/ssl.conf
lrwxrwxrwx 1 root root   26 Feb 16 18:17 ssl.load -> ../mods-available/ssl.load


注:
--启动错误ssl.conf,注释了下面3行
 38     #   Inter-Process Session Cache:
 39     #   Configure the SSL Session Cache: First the mechanism 
 40     #   to use and second the expiring timeout (in seconds).
 41     #   (The mechanism dbm has known memory leaks and should not be used).
 42     #SSLSessionCache         dbm:${APACHE_RUN_DIR}/ssl_scache
 43     #SSLSessionCache        shmcb:${APACHE_RUN_DIR}/ssl_scache(512000)
 44     #SSLSessionCacheTimeout  300

--生成证书,参见下面,这个apach2的版本已经不需要这个配置了,自己生成也没有问题,使用原来的可以(default-ssl.conf)
http://www.cnblogs.com/best-jobs/p/3298258.html

--遇到问题可以查看apache2的log文件,/var/log/apache2,也许会找到线索

--注意DocumentRoot的设置
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值