django +mysql配置(centos)

1 安裝mysql 不用說python

2  安裝django不用說mysql

3 還須要安裝一個 ez_setup.py web

4 下載 MySQLdbsql

5 若是安裝不上出現shell

Traceback (most recent call last):
  File "setup.py", line 16, in <module>
    metadata, options = get_config()
  File "/site/shell_test/python/MySQL-python-1.2.2/setup_posix.py", line 43, in get_config
    libs = mysql_config("libs_r")
  File "/site/shell_test/python/MySQL-python-1.2.2/setup_posix.py", line 24, in mysql_config
    raise EnvironmentError, "%s not found" % mysql_config.path

EnvironmentError: mysql_config not founddjango

須要安裝 yum  install mysql-server mysql-client libmysqlclient-dev  app

 6 出現spa

/usr/bin/ld: cannot find -lmysqlclient_rorm

須要安裝  mysql-develserver

7  使用 python manage.py runfcgi method=threaded host=127.0.0.0 port=8000 若是出現

ERROR: No module named flup

  Unable to load the flup package.  In order to run django

  as a FastCGI application, you will need to get flup from

  http://www.saddi.com/software/flup/   If you've already

  installed flup, then make sure you have it in your PYTHONPATH.

須要安裝 flup   wget http://www.saddi.com/software/flup/dist/flup-1.0.2.tar.gz
相關文章
相關標籤/搜索