知识库信普知识库总结
Posted 多安分
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了知识库信普知识库总结相关的知识,希望对你有一定的参考价值。
C# 程序运行后不希望Winform窗体大小再随鼠标拉动变化怎么办?
窗体FormBorderStyle属性设置为:FixedSingle,再把最大化禁用就可以了
CC内线外线接法
1、3接外线:连接原有电话线路; 2、4接内线:连接坐席电话。
centos下postgresql的安装与配置
2、安装或者升级postgresql-libs yum upgrade postgresql-libs 3、安装postgresql yum install postgresql postgresql-server 4、初始化数据库以及启动服务 service postgresql initdb service postgresql start
centos下安装nginx
/etc/init.d/nginx start 1、GCC编译器及相关工具。 yum -y install gcc gcc-c++ autoconf automake 2、使用yum命令安装或下载源码包编译安装这些模块依赖的库: yum -y install zlib zlib-devel openssl openssl--devel pcre pcre-devel 3、下载nginx并解压安装。http://nginx.org/en/download.html tar zxvf nginx-版本号.tar.gz cd nginx-版本号 ./configure make make install 4、Nginx的启动,停止,平滑重启 启动Nginx /usr/local/nginx/sbin/nginx -c /usr/local/nginx/conf/nginx.conf (参数“-c”指定了配置文件的路径,如果不加“-c”参数,Nginx会默认加载其安装目录的conf子目录中的nginx.conf文件) Nginx的停止 (1)从容停止Nginx。 kill - QUIT Nginx主进程号 或者 kill -QUIT `/usr/local/webserver/nginx/logs/nginx.pid` (2)快速停止Nginx kill - TERM Nginx主进程号 或者 kill -TERM `/usr/local/webserver/nginx/logs/nginx.pid` kill - INT Nginx主进程号 或者 kill -INT `/usr/local/webserver/nginx/logs/nginx.pid` (3)强制停止所有Nginx进程 pkill –9 nginx Nginx的平滑重启
his
ls top cleatr clear service ftpd status ? help ftp ps -aux|grep java ps -e cd /usr/local/ wget ftp://ftp.csx.cam.ac.uk/pub/programming/pcre/pcre-8.21.tar.gz wget ftp://ftp.csx.cam.ac.uk/pub/software/programming/pcre/pcre-8.21.tar.gz /etc/sysconfig/ exprot LC_ALL=\'zh_CN.utf8\' echo $LANGUAGE poweroff cd /usr/local/ ls cd nginx ls cd sb cd sbin/ ls nginx ls ./nginx ifconfig cd /etc/sysconfig/network-scripts/ ls ifcfg-eth0 vi ifcfg-eth0 service network stop service network start service network restart vi ifcfg-eth0 service network restart cd service network restart vi /etc/udev/rules.d/70-persistent-net.rules cd /etc/sysconfig/network-scripts/ifcfg-eth0 vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart vi /etc/sysconfig/network-scripts/ifcfg-eth0 vi /etc/udev/rules.d/70-persistent-net.rules vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart ifconfig vi /etc/udev/rules.d/70-persistent-net.rules vi /etc/sysconfig/network-scripts/ifcfg-eth0 ifconfig service network restart vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart ifconfig -a vi /etc/udev/rules.d/70-persistent-net.rules ifconfig -a vi /etc/sysconfig/network-scripts/ifcfg-eth0 service network restart vi /etc/sysconfig/network-scripts/ifcfg- rm -rf /etc/udev/rules.d/70-persistent-net.rules reboot -h now ps grep|n .. 你好 .. 你好 ifconfig service network restart ifconfig /usr/local/nginx/sbin/nginx service iptables stop ping 92.168.1.100 service network restart ifconfig service network restart ifconfig vi /etc/init.d/nginx chmod a+x /etc/init.d/nginx /etc/init.d/nginx statues /etc/init.d/nginx status /etc/init.d/nginx start /etc/init.d/nginx stop /etc/init.d/nginx start /etc/init.d/nginx restat /etc/init.d/nginx restart vi /etc/rc.local reboot cd /usr/local/ ls chmod 777 *.sh ./install_mysql.sh ps -A|grep my ps -A|grep n ps -A|grep m ps -A|grep n ps -A|grep cry ps -A|grep sql ps -A|grep mysql /etc/init.d/nginx stop /etc/init.d/nginx start /etc/init.d/nginx restart ls cd mysql cdMYSQL cd MYSQL ls chmod 777 *.rpm cd.. cd ls cd /usr/local/ ls ./install_MySQL.sh cd MYSQL/ ls rpm -ivh MySQL-server-5.0.27-0.i386.rpm service mysqld start chkconfig --list mysqld chkconfig --list MySQLD rpm -qa|grep mysql rpm -e -nodeps mysql-5.1.66-2.el6_3.x86_64 rpm -e mysql-5.1.66-2.el6_3.x86_64 rpm -e mysql-libs-5.1.66-2.el6_3.x86_64 rpm -e mysql-connector-odbc-5.1.5r1144-7.el6.x86_64 rpm -qa|grep mysql rpm -e mysql-libs-5.1.66-2.el6_3.x86_64 .. cd.. rd.. cd.. cd./ cd. cd cd /usr/local/ ls ./install_MySQL.sh whereis mysql service mysql start service mysqld start service MYSQL start which mysql ps =aux|grep mysql rpm -qa|grep mysql netstat -an|grep :3306 rpm -qa|grep -i mysql rpm -e --nodeps MySQL-client-5.0.27-0.i386 rpm -e --nodeps MySQL-python-1.2.3-0.3.c1.1.el6.x86_64 rpm -e --nodeps mysql-libs-5.1.66-2.el6_3.x86_64 rpm -qa|grep -i mysql rm -fr /usr//lib/mysql rm -fr /usr/include/mysql ls cd MYSQL ls rpm -vih MySQL-server-5.0.27-0.i386.rpm rpm -qa|grep -i mysql ls cd.. cd .. ls rpm -ivh MySQL-server-5.1.7-0.i386.rpm tar MySQL-server-5.1.7-0.i386.rpm tar xvfz MySQL-server-5.1.7-0.i386.rpm ls rpm -ivh MySQL-server-5.1.7-0.i386.rpm \' rpm -ivh MySQL-server-5.1.7-0.i386.rpm libc.so.6 is needed by MySQL-server-5.1.7-0.i386 getconf LONG_BIT netstat -nlp|grep 3306 ps aux|grep mysql service mysql stop service mysqld stop rpm -e --nodeps mysql-libs-5.1.61-4.el6.x86_64 top clear cd /usr/local/ ls version show list date cal 2007 cal 2013 logout
linux U盘备份 压缩包回复
linux查看80端口被什么程序占用
lsof -i :80 查看80端口被什么程序占用 netstat -an | grep :80 查看80端口的是否已在使用中,可验证使用该端口的服务是否已正常运行 netstat -tunlp | grep :80 查看80端口是被哪个服务使用着 [root@www.linuxidc.com log]# netstat -tunlp | grep 80 tcp 0 0 :::80 :::* LISTEN 1013/httpd ps aux | grep httpd 查看httpd服务是否已启动
linux关闭防火墙方法
service iptables stop 我采用NAT模式,之前用putty,连接类型为ssh,连接我的VM中的linux一直出现"Connection reset by peer",采用楼上的\'service iptables stop\'的方法,成功了! 停止防火墙 service iptables stop 启动防火墙 service iptables start 查看防火墙配置 iptables -L -n 有防火墙存在的情况下连接远程putty失败的可以采用此方法。 从配置菜单关闭防火墙是不起作用的,索性在安装的时候就不要装防火墙 查看防火墙状态: /etc/init.d/iptables status 暂时关闭防火墙: /etc/init.d/iptables stop 禁止防火墙在系统启动时启动 /sbin/chkconfig --level 2345 iptables off 重启iptables: /etc/init.d/iptables restart 题外话: BT或者骡子速度慢用不着关防火墙,只要把相应端口开放就可以了 在文件 /etc/sysconfig/iptables 在系统原始配置的:RH-Firewall-1-INPUT规则链增加类似这样的行: -A RH-Firewall-1-INPUT -m state --state NEW -m tcp -p tcp --dport 39764 -j ACCEPT -A RH-Firewall-1-INPUT -m state --state NEW -m udp -p udp --dport 39764 -j ACCEPT 如果发现原有-j REJECT一类的语句,上面两句要放在它的前面
linux系统中的mysql备份和还原
备份:
还原:
mysql -uroot -psimperfect CrystalCallDB</simperfect/DataBack/mysql.sql
linux下卸载MYSQL
卸载mysql 1、查找以前是否装有mysql 命令:rpm -qa|grep -i mysql 可以看到mysql的两个包: mysql-4.1.12-3.RHEL4.1 mysqlclient10-3.23.58-4.RHEL4.1 2、删除mysql 删除命令:rpm -e --nodeps 包名 ( rpm -ev mysql-4.1.12-3.RHEL4.1 ) 3、删除老版本mysql的开发头文件和库 命令:rm -fr /usr/lib/mysql rm -fr /usr/include/mysql 注意:卸载后/var/lib/mysql中的数据及/etc/my.cnf不会删除,如果确定没用后就手工删除 rm -f /etc/my.cnf rm -fr /var/lib/mysql 安装mysql 安装前准备:两个rpm包 MySQL-client-5.1.20-0.glibc23.i386.rpm MySQL-server-5.1.20-0.glibc23.i386.rpm 1、安装服务端: 命令:rpm -ivh MySQL-server-5.1.20-0.glibc23.i386.rpm 安装成功会出现.... warning: MySQL-server-5.1.20-0.glibc23.i386.rpm: V3 DSA signature: NOKEY, key ID 5072e1f5 Preparing... ########################################### [100%] 1:MySQL-server ########################################### [100%] 080220 13:58:27 [Note] Plugin \'InnoDB\' disabled by command line option 080220 13:58:28 [Note] Plugin \'InnoDB\' disabled by command line option PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER ! To do so, start the server, then issue the following commands: /usr/bin/mysqladmin -u root password \'new-password\' /usr/bin/mysqladmin -u root -h localhost.localdomain password \'new-password\' See the manual for more instructions. Please report any problems with the /usr/bin/mysqlbug script! The latest information about MySQL is available on the web at http://www.mysql.com Support MySQL by buying support/licenses at http://shop.mysql.com Starting MySQL.[ OK ] 2、安装客户端 命令:rpm -ivh MySQL-client-5.1.20-0.glibc23.i386.rpm 成功表现: [root@localhost ~]# rpm -ivh MySQL-client-5.1.20-0.glibc23.i386.rpm warning: MySQL-client-5.1.20-0.glibc23.i386.rpm: V3 DSA signature: NOKEY, key ID 5072e1f5 Preparing... ########################################### [100%] 1:MySQL-client ########################################### [100%] 3、登陆mysql 登陆MySql的命令是mysql,mysql 的使用语法如下: mysql [-u username] [-h host] [-p[password]] [dbname] username 与 password 分别是 MySQL 的用户名与密码,mysql的初始管理帐号是root,没有密码,
注意:这个root用户不是Linux的系统用户。MySQL默认用户是root,由于初始没有密码,第一次进时只需键入mysql即可 [root@localhost ~]# mysql Welcome to the MySQL monitor. Commands end with ; or \\g. Your MySQL connection id is 2 Server version: 5.1.20-beta MySQL Community Server (GPL) Type \'help;\' or \'\\h\' for help. Type \'\\c\' to clear the buffer. mysql> 出现了“mysql>”提示符,恭喜你,安装成功! 增加了密码后的登录格式如下: mysql -u root -p Enter password: (输入密码) 其中-u后跟的是用户名,-p要求输入密码,回车后在输入密码处输入密码。 注意:这个mysql文件在/usr/bin目录下,与后面讲的启动文件/etc/init.d/mysql不是一个文件。 补: 通过rpm包安装、配置及卸载mysql的详细过程. 以MySQL-server-4.0.14-0.i386.rpm为例,放在/data目录下 cd /data rpm -ivh MySQL-server-4.0.14-0.i386.rpm 安装完成后在/usr/share/mysql目录中会有一个mysql的启动脚本mysql.server及示例配置文件等(如my-huge.cnf、my-large.cnf、my-medium.cnf) 拷贝一个示例配置文件作为mysql的配置文件: cp /usr/share/mysql/my-medium.cnf /etc/my.cnf rpm包安装完后自动将mysql安装成系统服务,所以可以使用下面命令启动、停止mysql 启动mysql /etc/init.d/mysql start 或 service mysql start 停止mysql /etc/init.d/mysql stop 或 service mysql stop 到此,mysql服务就安装配置完成。 安装mysql客户端 rpm -ivh MySQL-client-4.0.14-0.i386.rpm mysql安装好后目录结构如下: 工具程序在/usr/bin目录中---ls /usr/bin/mysql* 服务器程序/usr/sbin/mysqld 数据目录/var/lib/mysql 默认情况下mysql将错误日志文件、二进制日志文件及进程文件写在/var/lib/mysql目录中,如localhost.err、localhost.pid、localhost-bin.001等 要改变这些情况可以修改/etc/my.cnf文件 如将日志文件写在/var/log目录中,可以在my.cnf文件中加入下面两行: [mysqld_safe] err-log = /var/log/mysqld.log 有个实用程序/usr/bin/mysql_install_db,该程序可以用来初始化 mysql数据库,即创建/var/log/mysql目录,
及创建mysql数据库(mysql授权表等信息)及test数据库(空库),如果不小心删 除了/var/log/mysql目录可以通过该程序来初始化. 卸载mysql rpm -qa|grep -i mysql rpm -ev MySQL-server-4.0.14-0 MySQL-client-4.0.14-0 卸载后/var/lib/mysql中的数据及/etc/my.cnf不会删除,如果确定没用后就手工删除 rm -f /etc/my.cnf rm -rf /var/lib/mysql mysql 1130错误解决方法: 通过MySQL-Front或mysql administrator连接mysql的时候发生的这个错误 ERROR 1130: Host ***.***.***.*** is not allowed to connect to this MySQL server 说明所连接的用户帐号没有远程连接的权限,只能在本机(localhost)登录。 需更改 mysql 数据库里的 user表里的 host项 把localhost改称% 具体步骤:登陆到mysql 首先 use mysql; 按照别人提供的方式update的时候,出现错误。 mysql> update user set host=\'%\' where user = \'root\'; ERROR 1062 (23000): Duplicate entry \'%-root\' for key \'PRIMARY\' 然后查看了下数据库的host信息如下: mysql> select host from user where user = \'root\'; +-----------------------+ | host | +-----------------------+ | % | | 127.0.0.1 | | localhost.localdomain | +-----------------------+ 3 rows in set (0.00 sec) host已经有了%这个值,所以直接运行命令: mysql>flush privileges; 再用mysql administrator连接...成功!!! tar.gz版本安装: 版本1: 1。把MYSQL安装包放置并解压到/usr/local下 tar zxvf mysql-standard-5.0.27-linux-i686-glibc23.tar.gz 2。为目录建立符号链接 ln -s mysql-standard-4.0.24-pc-linux-gnu-i686 mysql 3。建立MYSQL组和用户 groupadd mysql useradd -g mysql mysql 4。改变mysql目录的所属用户和组 chown -R mysql . #注意保证此时的当前目录是/usr/lcoal/mysql chgrp -R mysql . 5。以mysql用户执行配置脚本 su mysql #切换到mysql用户 cd /usr/local/mysql #注意切换用户以后,工作目录已经不是/usr/local/mysql。所以得重新进去 ./configure #执行配置脚本 6。进入数据库,检查安装是否成功 /usr/local/mysql/bin/mysql 如果出现mysql的提示符且进入,说明安装成功! 7。在系统启动时自动打开mysql服务 su - #切换回root用户 cd /usr/local/mysql cp support-files/mysql.server /etc/rc.d/init.d/mysql #把mysql的脚本文件拷到系统的启动目录下 cd /etc/rc.d/init.d/ chmod +x mysql #改为可执行文件属性 chkconfig --add mysql #将mysql加到启动服务列表里 chkconfig mysql on #让系统启动时自动打开mysql服务 重起系统后,执行 /usr/local/mysql/bin/mysql ,如果出现mysql的提示符,说明整个安装成功 版本2: mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz 是mysql4.0.24版本的安装文件,是一个二进制的压缩包,所以我们的安装方式就为二进制分发安装。 安装步骤: 1.将 mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz 拷贝到一个目录中 2.shell> tar zvxf mysql-standard-4.0.24-pc-linux-gnu-i686.tar.gz 3.上面的命令将在当前目录下生成一个mysql-standard-4.0.24-pc-linux-gnu-i686文件夹 4.shell>mv mysql-standard-4.0.24-pc-linux-gnu-i686 /usr/local/mysql 5.上面的命令是将mysql-standard-4.0.24-pc-linux-gnu-i686下的所有东东,剪切到/usr/local/mysql 下,进行这一步是为了以后的方便。 6.shell> groupadd mysql 增加一个名为mysql的用户组 7.shell> useradd -g mysql mysql 在mysql用户组中加一个名为mysql的用户 如果上面的两个命令不能执行,那么要切换到root用户下执行 shell>su root - 8.shell> cd /usr/local/mysql 9.shell> cp support-files/my-medium.cnf /etc/my.cnf 这时会问是否覆盖重名文件,回答y 10.shell> scripts/mysql_install_db --user=mysql 以mysql用户初始化数据库,必须以mysql用户 11.shell> chown -R root 注意后面有点,表示将当前目录下的所有文件与子目录的拥有者设 定为root用户 12.shell> chown -R mysql data 表示将当前目录下的data目录的拥有者设定为mysql用户 13.shell> chgrp -R mysql . 注意后面有点,表示将当前目录下的文件的文件组设为mysql组 14.shell> bin/mysqld_safe --user=root & 此时如果没有出现“……ended”字样,大功告成! 15.回车显示shell> 此时你可以 通过 shell>netstat –atln 命令查看3306端口是否已经启用 也可以 shell>ps -ef | grep mysqld 查看当前系统中的mysqld的进程 或直接 shell>bin/mysql –u root 进入mysql客户端,进行mysql操作 或shell>bin/mysqladmin shutdown 停止mysql服务 记住:此时你的root用户是没有密码的,任何身份都可以用root进入,你可以 通过shell> bin /mysqladmin -u root password \'新口令\'来设定root用户的口令,此口令将在进入mysql客户端和停止mysql服务时需要输入 提示:在启单个服务的时候,可以通过修改/etc/my.cnf文件来配置 可以用VI编辑器打开my.cnf ,怎么打开呢,看下面 shell>vi my.cnf 打开my.cnf 找到下面这段 [mysqld] port = 8888 socket = /tmp/mysql.sock 可以在后面加上相应的配置 log = /var/log/mysql.log datadir = /free/mysqldbf 如 log = /* 改变log的保存位置 datadir = /free/mysqldbf 改变data的保存位置 希望对遇到同样问题的朋友有点点帮助 常用命令: 启动 MySQL: service mysql start /etc/init.d/mysql start /usr/share/mysql/mysql.server start [mysql.server] # 注释掉 basedir 行,否则 MySql 可能不能启动 # 据说是 MySql 的 bug # basedir=/var/lib root登录时,自动启动mysql: 在 /root/.bash_profile 文件中增加1行: /usr/share/mysql/mysql.server start 查看启动日志: /var/log/messages 显示MySQL所有用户: use mysql; select host,user,password from user; 添加 MySQL 用户(user name:user1,password:sql): grant all on *.* to user1@\'%\' identified by \'sql\' with grant option; 删除 MySQL 用户: delete from user where user=\'user1\'; 配置环境变量: PATH=$JAVA_HOME/bin:$CATALINA_HOME/bin:/usr/local/mysql/bin:$PATH
linux中如何修改机器的IP地址
修改IP永久生效按以下方法 vi /etc/sysconfig/network-scripts/ifcfg-eth0(eth0,第一块网卡,如果是第二块则为eth1) 按如下修改ip DEVICE=eth0(如果是第二块刚为eth1) BOOTPROTO=static IPADDR=192.168.0.11(改成要设置的IP) NETMASK=255.255.255.0 (子网掩码) GATEWAY=192.168.0.1(网关) ONBOO=yes 然后 service network restart IP地址生效,重启系统后不变 如果是临时修改IP重启系统后恢复原始IP则用以下命令 ifconfig IP地址 netmask 子网掩码 在使用vmware迁移linux系统过程中,发现部署后的linux系统无法启动网卡 报错为 Bringing up interface eth0: Device eth0 does not seem to be present,delaying initialization 错误原因,是因为linux网卡绑定了原mac地址导致 解决方法为 1.使用ifcnfig -a 查看当前主机mac地址 2.修改eth0网卡硬件地址为当前地址 vi /etc/sysconfig/network-scripts/ifcfg-eth0 保存退出 其实在network-scripts下查看是没有eth1网卡的 3.删除70-persistent-net.rules文件 rm -rf /etc/udev/rules.d/70-persistent-net.rules 4.重启系统 reboot -h now 一切OK
log
ls cd .. ls cd opt ls cd .. cd home ls cd .. ls cd root ls cd .. cd usr ls cd .. python sudo ap-get apt-get apt-cache apt-cache search pip apt-get install pip pip sudo apt-get install pip sudo apt-get install python-pip pip pip help exit ls cd .. pip python pip search django pip help pip search django ls pip search django nano ls whereis pip.conf cd /usr/bin/pip cd /usr/bin ls cd pip/ cd / ls find . name \'pip.conf\' cd ~ ls cd .. ls whereis pip pip install django==1.6.2 sudo pip search django whereis .pip cd ~/.pip/ ls vim pip.conf ls whereis pip.conf exit() ; exit virtualenv pip search python-virtualenv pip search python-virtualenv --timeout=10 virtualenv apt-get install python-virtualenv virtualenv virtualenv env ls cd env ls cd .. ls rm -rf env ls cd .. ls cd opt/ ls virtualenv env ls cd env/ ls pip help cd ~ ls vim install.sh ls cd .pip/ ls vim pip.conf pip search django --timeout=10 ls vim pip.log vim pip.conf pip search django --timeout=10 easy_install pip pip search aaaaaaaaaaaaaaaaaaaaaaaaa pip search django pip search django==1.6.2 pip search Django==1.6.2 pip install Django==1.6.2 python ls cd .. ls ls cd opt/ ls cd env ls cd ~ ls python -m SimpleHTTPServer 8000 ping 113.46.123.206 python -serve_forever SimpleHTTPServer python -h python -serve_forever SimpleHTTPServer-serve_forever python SimpleHTTPServer.searve_forever python SimpleHTTPServer - python -m SimpleHTTPServer.searve_forever python -m SimpleHTTPServer - searve_forever python -m SimpleHTTPServer -searve_forever python -m SimpleHTTPServer fg exit ls cd .. cd opt/ ls cd env ls cd bin ls cd .. ls source bin/activate ls python pip install django-1.6.2 Could not find any downloads that satisfy the requirement django-1.6.2 which python pip install django whereis django-admin.py python apt-get install git ls whereis git man bin man man help man --help git lssitepackages lsitepackages lssitepackages deactivate ls source env source bin/activate cd bin ls vim activate cd .. ls git -- git --version deactivate source bin/active source bin/activate decativate deactivate source bin/activate deactivate exit ls cd .. ls cd opt/ ls cd env ls pip search python-virtualenv pip search virtualenv cd .. ls source ./bin/activate source env/bin/activate deactivate ls rm -rf env ls cd .. ls cd opt/ ls python django-admin.py startproject petanne ls cd petanne/ ls cd petanne/ ls vim vim settings.py vim urls.py ls django --version django help django-admin.py help django-admin.py --version vim urls.py vim settings.py ls cd .. ls python manage.py runserver ls cd petanne/ ls cd .. django-admin.py startapp cms ls cd cms ls cd .. ls cd petanne/ ls vim urls.py ls vim settings.py ls cd .. ls rm -rf cms ls django-admin.py startapp pets ls cd pet rm -rf pets django-admin.py startapp cms ls cd petanne/ ls vim urls.py vim settings.py cd .. cd cms/ ls vim urls.py ls vim views.py cd .. cd opt/ ls cd petanne/ ls cd cms ls vim views.py ls cd ,, cd .. ls cd petanne/ ls vim settings.py ls mkdir static ls mkdir template ls vim s ls vim settings.py ls cd .. ls python manage.py runserver python manage.py shell ls cd petanne/ ls vim settings.py ls cd .. python manage.py runserver pip install uwsgi ls apt-get install build-essential python pip install uwsgi gcc gcc=gcc pip install uwsgi apt-get install build-essential python apt-get updaye apt-get update apt-get install build-essential python pip install uwsgi apt-get install python2.7-dev pip install uwsgi ls cd .. ls cd opt/ ls cd petanne/ ls python manage.py runserver python manage.py runserver 0.0.0.0:8000 ls cd petanne/ ls vim urls.py cd .. ls python manage.py runserver 0.0.0.0:8000 cd petanne/ vim settings.py ls cd .. python manage.py shell ls cd petanne/ vim settings.py cd .. ls vim startLocal.cmd ls vim restart.sh ls restart.sh file restart.sh sh restart.sh ;s ls cd petanne/ vim settings.py ls cd template/ ls rm -rf template ls cd .. rm -rf template/ ls mkdir templates ls cd templates/ vim index.html cd .. ls cd .. ls sh restart.sh exit cd .. cd opt/ ls cd petanne/ ls cd petanne/ ls cd templates/ ls vim index.html cd .. ls cd . cd .. ls sh restart.sh exit cd ../opt/petanne/ ls cd petanne/ ls cp settings.py settings_production.py ls cd .. ls vim restart.sh ls cp manage.py manage_production.py re sh restart.sh vim manage_production.py sh restart.sh ls cd petanne/ ls vim settings_production.py ls cd .. ls cd cms ;s ls vim views.py ls cd .. ls sh rw sh restart.sh exit ls cd .. ls cd opt/ ls cd petanne/ ls nginx uwsgi ls cd .. ls cd petanne/ ls vim djangi-uwsgi.xml ls pwd ls vim djangi-uwsgi.xml ls cd / ls cd var/ ls cd log ls mkdir nginx ls pwd cd n cd nginx/ ls pwd cd ~ ls cd .. ls cd opt/ ls cd petanne/ ls cd petanne/ ls mkdir media ls cd .. ls vim anne-nginx.conf nginx -s reload apt-get install nginx-full nginx -s reload nginx -c /opt/petanne/anne-nginx.conf ls vim anne-nginx.conf nginx -c /opt/petanne/anne-nginx.conf vim anne-nginx.conf whereis uwsgi cd /usr//local//bin/ ls cd uwsgi vim uwsgi ls cd ~ ls cd .. ls cd opt/petanne/ ls nginx -c /opt/petanne/anne-nginx.conf vim /etc/nginx/uwsgi_params vim anne-nginx.conf nginx -c /opt/petanne/anne-nginx.conf vim anne-nginx.conf nginx -c /opt/petanne/anne-nginx.conf vim anne-nginx.conf nginx -c /opt/petanne/anne-nginx.conf top ps nginx -c /opt/petanne/anne-nginx.conf nginx -s reload ls mv djangi-uwsgi.xml django-uwsgi.xml ls uwsgi -x django-uwsgi.xml cd /var/log/ ls mkdir uwsgi ls cd uwsgi/ ls vim uwsgi.log ls cd ~ cd ../opt/petanne/ uwsgi -x django-uwsgi.xml nginx -s reload ps -ef|grep uwsgi ps -ef|grep uwsgi|grep -v grep ps ls cd petanne/ ls cd templates/ ls vim index.html ls cd .. ls cd .. ls cd cms ls vim views.py cd /var/log/nginx/ ls vim anneaccess.log cd ~ cd .. cd opt/ cd petanne/ ls cd petanne/ ls cd templates/ vim index.html ls cd .. ls cd cms/ ls vim views.py cd .. ls vim django-uwsgi.xml vim anne-nginx.conf nginx uwsgi ls vim manage.py vim manage_production.py cd petanne/ ls vim settings.py ps ps -ef ls cd ../cms/ vim views.py l ls cd .. cd s cd cms/ vim admin.py cd .. ls python manage_production.py runserver ps -ef | grep nginx kill -QUIT 23681 ps -ef | grep nginx ls python manage_production.py runserver python manage_production.py runserver 8001 python manage_production.py runserver r 80 python manage_production.py runserver r 8080 python manage_production.py runserver r 8002 python manage_production.py runserver r 8001 python manage_production.py runserver r 127.0.0.1:8001 python manage_production.py runserver 8001 ls cd .. ls cd opt/petanne/ ls python manage_production.py python manage_production.py runserver ls vim restart.sh python manage_production.py runserver 0.0.0.0:8000 ls uwsgi -x django-uwsgi.xml nginx 以上是关于知识库信普知识库总结的主要内容,如果未能解决你的问题,请参考以下文章