先通过apt-get remove删除系统下原有nginx,再添加源安装
sudo apt-get install python-software-properties sudo add-apt-repository ppa:nginx/stable sudo add-apt-repository ppa:uwsgi/release sudo apt-get update sudo apt-get install uwsgi nginx
过程中遇到问题,最后install无法完成,报错
dpkg: warning: files list file for package `nginx-common' missing, assuming package has no files currently installed. dpkg: warning: files list file for package `nginx-full' missing, assuming package has no files currently installed.
在网上查了很久,没有完全的解决方案,最后通过如下方式解决
sudo find / | grep nginx
查找系统所有的nginx残留文件并手动删除,然后运行
sudo apt-get clean sudo apt-get update sudo apt-get upgrade sudo apt-get install nginx --reinstall
ok,nginx成功更新。
更新:2011-09-17
没两天,uwsgi的默认安装部署发生了变化,改了个名字,需要如下安装
sudo apt-get install uwsgi-python
安装后各路径
sudo /etc/init.d/uwsgi-python restart /var/log/uwsgi-python/uwsgi.log /etc/uwsgi-python/apps-available/uwsgi.xml #默认配置文件 /etc/default/uwsgi-python #默认命令行启动参数设置
我的参数配置如下
/etc/default/uwsgi-python
DAEMON_OPTS=" \ --master \ --no-orphans \ --processes 2 \ --logdate \ --chmod-socket=666 \ --uid www-data \ --gid www-data \ --limit-as 256 \ --harakiri 60 \ --max-requests 1000 \ "
具体参数含义可参考 http://projects.unbit.it/uwsgi/wiki/Doc