重新拷贝 新项目 发现不显示 原来是 paramiko 没有装
proxy pass 端口换成 另一个 跟原来的不冲突
[root@ayibang-server soft_ware]# cp s10day11/demo.* s10ops/
[root@ayibang-server soft_ware]# cd s10ops/
[root@ayibang-server s10ops]# ls
aa.py db.sqlite3 demo.ini demo.py demo.pyc hosts manage.py s10ops statics templates uploads ????????
[root@ayibang-server s10ops]# vim demo.ini
[uwsgi]
socket = 0.0.0.0:9999
processes = 30
chdir = /data/soft_ware/s10ops/
pythonpath = /usr/local/bin/python
env = DJANGO_SETTINGS_MODULE=s10ops.settings
module = django.core.wsgi:get_wsgi_application()
[root@ayibang-server s10ops]# vim demo.py
#!/usr/bin/env python
#coding:utf-8
import os
from django.core.wsgi import get_wsgi_application
os.environ['DJANGO_SETTINGS_MODULE']='s10ops.settings'
application = get_wsgi_application()
[root@ayibang-server s10ops]# cd /etc/nginx/conf.d/
[root@ayibang-server conf.d]# ls
admin.conf api.conf.bak cms.conf default.conf django.conf img.conf.bak redmine.conf ssl.conf virtual.conf www.conf.bak
[root@ayibang-server conf.d]# cp django.conf office_djaong_uvpv.conf
[root@ayibang-server conf.d]# vim office_djaong_uvpv.conf
server {
listen 8888;
server_name 192.168.1.200;
location / {
include uwsgi_params;
uwsgi_pass 0.0.0.0:9999;
}
location /static {
alias /data/soft_ware/s10ops/statics;
}
}
平滑重启 nginx
[root@ayibang-server conf.d]# /etc/init.d/nginx reload
Reloading nginx: [ OK ]
报错
/data/soft_ware/s10ops/hosts/backends
[pid: 5418|app: 0|req: 4/33] 192.168.1.19 () {50 vars in 949 bytes} [Thu Dec 3 08:21:22 2015] POST /hosts/submit_task/ => generated 16 bytes in 109 msecs (HTTP/1.1 200) 3 headers in 102 bytes (1 switches on core 0)
Traceback (most recent call last):
File "/data/soft_ware/s10ops/hosts/backends/multi_task.py", line 26, in <module>
import paramiko_handle #多进程 批量处理脚本 文件
File "/data/soft_ware/s10ops/hosts/backends/paramiko_handle.py", line 4, in <module>
import paramiko,json #
ImportError: No module named paramiko
179
--res--task-- [{'bind_host__host__ip_addr': u'124.205.209.42', 'bind_host__host_user__username': u'root', 'event_log': u'N/A', 'bind_host__host__hostname': u'ubantu-1', 'result': u'unknown', 'date': datetime.datetime(2015, 12, 3, 8, 21, 22, 498018, tzinfo=<UTC>), 'id': 224}]
[pid: 5414|app: 0|req: 3/34] 192.168.1.19 () {42 vars in 819 bytes} [Thu Dec 3 08:21:22 2015] GET /hosts/gettaskresult/?task_id=179 => generated 214 bytes in 8 msecs (HTTP/1.1 200) 3 headers in 102 bytes (1 switches on core 0)
179
--res--task-- [{'bind_host__host__ip_addr': u'124.205.209.42', 'bind_host__host_user__username': u'root', 'event_log': u'N/A', 'bind_host__host__hostname': u'ubantu-1', 'result': u'unknown',‘
centos 安装 paramiko
[root@ayibang-server conf.d]# pip install paramiko
Collecting paramiko
Downloading paramiko-1.16.0-py2.py3-none-any.whl (169kB)
100% |################################| 172kB 6.5MB/s
Collecting ecdsa>=0.11 (from paramiko)
Downloading ecdsa-0.13-py2.py3-none-any.whl (86kB)
100% |################################| 90kB 58kB/s
Collecting pycrypto!=2.4,>=2.1 (from paramiko)
Downloading pycrypto-2.6.1.tar.gz (446kB)
100% |################################| 446kB 88kB/s
Installing collected packages: pycrypto, ecdsa, paramiko
Running setup.py install for pycrypto
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for __gmpz_init in -lgmp... no
checking for __gmpz_init in -lmpir... no
checking whether mpz_powm is declared... no
checking whether mpz_powm_sec is declared... no
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for inttypes.h... (cached) yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking stddef.h usability... yes
checking stddef.h presence... yes
checking for stddef.h... yes
checking for stdint.h... (cached) yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking wchar.h usability... yes
checking wchar.h presence... yes
checking for wchar.h... yes
checking for inline... inline
checking for int16_t... yes
checking for int32_t... yes
checking for int64_t... yes
checking for int8_t... yes
checking for size_t... yes
重新拷贝 新项目 发现不显示 原来是 paramiko 没有装的更多相关文章
- 在AndroidStudio v1.2.0中导入或增加新项目或工程(导入第三方类库或工程)
以下说明基于AndroidStdudio版本v1.2 由于AndroidStudio项目止录与Eclipse中的Worksapce在意义上的改变,所以导入新包或建立新项目时并不和以前那样了. 下面是我 ...
- 【Cocos2d-x for WP8 学习整理】(1)创建一个新项目
喜大普奔 10.1假期之前看到了一个很振奋的消息,就是随着Cocos2d-x 2.2的发布,WP8/WIN8有史以来第一次的合并到主版本了. 之前 V2 ...
- cocos2d-x3.2创建新项目失败的一种可能性(cygwin自带的python2.6被抢先执行)
之前一直使用cocos2d-x2.2写游戏,写了几个游戏后,想尝试下3.x版本的新功能,就下载了cocos2d-x3.2版本. 参照官方文档的说法,cocos2d-x3.x版本需要python2.7环 ...
- 复制新项目 ,tomcat部署时名字还是旧项目名
基于一个就项目 copy 成新项目 关于项目名注意点: 在工作空间下 copy一份新项目 1首先在目录将项目名字更改. 2.在新项目下 找到 [.project]文件 将里面的nama更改 3 ...
- 用Kotlin开发Android应用(II):创建新项目
这是关于Kotlin的第二篇.各位高手发现问题,请继续“拍砖”. 原文标题:Kotlin for Android(II): Create a new project 原文链接:http://anton ...
- cocos2d-x 3.2 创建新项目问题
cocos2d-x 3.2 执行cocos2d-x\tools\cocos2d-console\console下的cocos2d.py,输入相应的参数即可创建一个新的项目,具体参数网上介绍一大堆,就不 ...
- myeclipse下拷贝的项目,tomcat下部署名称和导出为war包的名称默认值修改
拷贝一个项目,作为一个新的项目,给它换了名字,这时候默认的部署名称等都是原来项目的,这时候要在属性里面修改一下.
- 如何向Openstack社区提交一个新项目
前几天有个朋友问我:自己有一个idea不错的项目,也把基本的框架写好了,想贡献到Openstack社区,却不知道应该怎么做.正好之前我有过类似的经历,那么来分享一下我是如何向Openstack社区提交 ...
- MyEclipse中拷贝J2EE项目,发布到tomcat中名字一样的解决办法
修改Eclipse工作空间下新拷贝项目下.settings文件夹中org.eclipse.wst.common.component的两个属性值. 为新项目名字: <?xml version=&q ...
随机推荐
- Java发展史之Java由来
Java:由Sun Microsystems公司于1995年5月推出的Java程序设计语言和Java平台的总称.Java语言是一种可以撰写跨平台应用软件的面向对象的程序设计语言,由当时任职太阳微系统的 ...
- c#String的不变特性,可读但不可写性
谈到字符串,大家自然觉得简单,但是总是有一些小的问题隐约出现,下面我就系统的说一下字符串的问题,有说不到日后再予补充. 1,首先String是一个类,string只是String类的一个别名,别名的意 ...
- linux load average
性能分析_linux服务器CPU_Load Average 理解Linux系统中的load average(图文版) 理解Load Average做好压力测试 top命令的Load average 含 ...
- 【翻译】Kinect Studio是? 三月 SDK Update的新机能
Kinect应用软件开发支援工具「Kinect Studio」的功能和用法的说明.由于可以记录/再生数据,让开发和调试变得更加简单. Kinect SDK v2预览版的RTM版的预定在发布之前 ...
- Unity 父物体与子物体位置
酷跑片段本来想做三条轨道,然后通过切换轨道来做,后面发现一种巧妙的方法,利用物体的父级偏移来实现轨道的切换. 比如上图,实际运动的是Car对象,通过修改MineControler的左右位置( ...
- javaWeb中servlet开发(1)——helloworld
1.servlet 1.1 servlet简介 1.2 servlet流程 不管是servlet还是jsp,所有的程序都是在服务器端处理的,所以必须了解一个servlet基本流程 servlet和JS ...
- Oracle 安装 INS-30131错误。
需要学习SDE配置相关知识,其中Oracle数据库安装遇到错误INS-30131,虽然未能最终解决,但找到了初步的思路,记录下来给大家提供参考.下文对很多知识的理解可能存在错误或不够精准,仅作参考. ...
- MySQL 绿色版(zip) 安装
设置环境变量Path,指向到MYSQL下的bin目录 修改MYSQL下的my-default.ini basedir=%MYSQL_HOME% datadir=%MYSQL_HOME%\data 到M ...
- 策略模式代替大量的if else
原代码 public class Example { public Double calRecharge(Double charge, RechargeTypeEnum type) { if (typ ...
- pro5
1.本次课学到的知识点 (1)循环结构的概念 在我们需要重复进行某个步骤是就需要运用到循环结构. (2)三种循环语句 for,while,do-while是三种常用的循环语句,其中while的适用范围 ...