# vim /etc/resolv.conf
# yum install gcc-c++
# tar jxvf Python-2.6.5.tar.bz2
# cd Python-2.6.5
# ./configure
# make && make install
# python -V
# /usr/local/bin/python2.6 -V
# mv /usr/bin/python /usr/bin/python.bak
# ln -s /usr/local/bin/python2.6 /usr/bin/python
# python -V
# tar xvzf tornado-1.2.1.tar.gz
# cd tornado-1.2.1
# python setup.py build
# sudo python setup.py install
开启服务,运行hello world程序
#cd user/tornado-2.0
#ls
#ls ./demos
#vim ./demos/helloworld/helloworld.py
#./demos/helloworld/helloworld.py
此时打开浏览器,地址栏输入:http://127.0.0.1:8888,即可看到hello,world
步骤:将工作目录改为tornado所在目录->检查是否存在demos目录->检查demos目录下是否有helloworld->查看helloworld代码->运行程序
tornado的中文文档:http://www.tornadoweb.cn/documentation