nginx 安装失败 没有/etc/nginx目录

47 篇文章 0 订阅
36 篇文章 0 订阅

Failed to start A high performance web server and a reverse proxy server

apt-get remove --purge xxx # 移除应用及配置
apt-get autoremove # 移除没用的包




Since you managed to install it anyhow first thing you've to do is to remove it completely with the configuration files

Follow these steps to remove it completely and install it again.

  • Open terminal and execute these commands:

    sudo apt-get autoremove nginx
    sudo apt-get --purge remove nginx
    sudo apt-get autoremove && sudo apt-get autoclean
    sudo find / | grep nginx | sudo xargs rm -rf
    

    the last command will remove the repository also so you've to add it again by:

    sudo add-apt-repository ppa:nginx/stable
    

    Now try to install it again by:

    sudo apt-get update && sudo apt-get -f install nginx
    
  • Hope it would solve your issue. Reply if you get any error at any particular command describing the command.

This is the output of

sudo dpkg -l | grep nginx:

ii  nginx                                       1.4.3-1~precise0                                    small, powerful, scalable web/proxy server
ii  nginx-common                                1.4.3-1~precise0                                    small, powerful, scalable web/proxy server - common files
ii  nginx-full                                  1.4.3-1~precise0                                    nginx web/proxy server (standard version)

whereis nginx:

nginx: /usr/sbin/nginx /etc/nginx /usr/share/nginx /usr/share/man/man1/nginx.1.gz
share improve this answer

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值