正在把 supervisord 换成init.d

唐如麟
清华大学物理系
基科22
----------------------
 Tang Rulin
 Department of Physics
 Tsinghua University
 E-mail: f (mailto:[email protected])[email protected]
             [email protected]


On Thursday, February 27, 2014 at 1:46 PM, 王康 wrote:

> 此刻wiki.tuna.tsinghua.edu.cn (http://wiki.tuna.tsinghua.edu.cn)依然无法访问
>  
>  
>  
>  
> 2014-02-26 20:39 GMT+08:00 唐如麟 <[email protected] 
> (mailto:[email protected])>:
> > 综述:
> >  
> > 这次wiki停止工作是由于/usr/bin/uwsgi的软链被修改,指向了另外一个版本引起的,可能是软件升级原因,现已修好,并采取措施避免下次发生。
> >  
> > 细节:
> >  
> > moin的位置在/srv/moin 其中有指向 /usr/local/lib/python2.6/dist-packages/MoinMoin  的软链
> >  
> > moin由supervisord启动 脚本在/etc/supervisor/conf.d/moin.conf  
> >  
> > wiki搬迁过程中,源里的uwsgi一直不好用,当时怀疑版本过低,我就自己编译了一个版本uwsgi-1.9.21.1,放在了/etc/alternatives/,并把/usr/bin/uwsgi指向了它。
> >  
> > 今天早上看到出了问题,发现/usr/bin/uwsgi指向/etc/alternatives/uwsgi-1.9.21.1的软链被指向了/etc/alternatives/uwsgi(版本1.2.3)。修改回去以后,恢复正常。
> >   
> >  
> > 为了避免以后此类情况发生,下午,从sid安装了1.9.17.1,/usr/bin/uwsgi指向/etc/alternatives/uwsgi。
> >  
> > 再次启动出错,查看日志:
> >  
> >   File "/usr/local/lib/python2.6/dist-packages/MoinMoin/Page.py", line 
> > 1318, in execute  
> >     exec code
> >   File "Homepage", line 2, in <module>
> > TypeError: 'dict' object is not callable
> > [pid: 19101|app: 0|req: 3/3] 2402:f000:9:7c01:1::801 () {38 vars in 650 
> > bytes} [Wed Feb 26 09:55:53 2014] GET / => generated 0 bytes in 47 msecs 
> > (HTTP/1.1 500) 0 headers in 0 bytes (0 switches on core 0)
> >  
> >  
> > google说是由于python版本升级引起的(貌似之前运行在2.6下),需要清理moin的cache:
> >  
> > root@web:/srv/moin/package/script# ./moin.py --config-dir=/srv/moin maint 
> > cleancache
> >  
> > 重启相关服务后恢复正常。  
> >  
> > 另外,pip install uwsgi可安装2.0.1,且启动不需要使用—plugin python参数
> >  
> > 感谢@heroxbd 学长的指导。
> >  
> >  
> >  
> > 唐如麟  
> > 清华大学物理系
> > 基科22
> > ----------------------
> >  Tang Rulin
> >  Department of Physics
> >  Tsinghua University
> >  E-mail: f (mailto:[email protected])[email protected] 
> > (mailto:[email protected])
> >              [email protected] (mailto:[email protected])
> >  
> >  
> > --  
> >   
> > ---  
> > 您收到此邮件是因为您订阅了 Google 网上论坛的“TUNA 主邮件列表”论坛。
> > 要退订此论坛并停止接收此论坛的电子邮件,请发送电子邮件到 [email protected] 
> > (mailto:tuna-general%[email protected])。
> > 要查看更多选项,请访问 https://groups.google.com/groups/opt_out。
>  
> --  
>   
> ---  
> 您收到此邮件是因为您订阅了 Google 网上论坛的“TUNA 主邮件列表”论坛。
> 要退订此论坛并停止接收此论坛的电子邮件,请发送电子邮件到 [email protected] 
> (mailto:[email protected])。
> 要查看更多选项,请访问 https://groups.google.com/groups/opt_out。

-- 

--- 
您收到此邮件是因为您订阅了 Google 网上论坛的“TUNA 主邮件列表”论坛。
要退订此论坛并停止接收此论坛的电子邮件,请发送电子邮件到 [email protected]。
要查看更多选项,请访问 https://groups.google.com/groups/opt_out。

回复