Home > Article > Backend Development > nginx source code learning resources
Original address: http://www.cnblogs.com/yjf512/archive/2012/06/13/2548515.html
nginx source code learning is a painful and happy process. Some nginx learning resources are listed below.
The first thing to do is of course to download a copy of the nginx source code. You can download the latest copy from the nginx official website.
After looking at the nginx source code, I found that this is a code with no comments and no configuration documentation at all.
What you want most now is a commented version of the nginx source code. You can download a copy from the link below:
https://github.com/jianfengye/nginx-1.0.14_comment
This The annotated source code will be continuously updated
Okay, first question, where is the main function of nginx?
src/core/nginx.c
Second question, what does nginx do when it starts? Refer to the following two articles:
http://www.pagefault.info/?p=188
http://www.pagefault.info/?p=201&cpage=1
The command to start nginx is nginx, restart The command is nginx -s reload. nginx has master and worker processes. How do they communicate with each other? You can refer to the following article:
http://simohayha.iteye.com/blog/467940
Okay, are your hands itchy? Want to debug nginx?
Are you a Linux programmer? Use gdb to debug.
How to debug nginx http://doyoueat.iteye.com/blog/1291164
gdb debugging nginx:
http://www.cnblogs.com/yjf512/archive/2012/05/10/2494635.html
Are you a windows programmer? Want to use vs to debug nginx? OK
Here is a debuggable project:
http://liyongping.sinaapp.com/?p=116
How to write a third-party module for nginx? Miller's article is very good, codinglabs' article is also good, recommended
http://www.codinglabs.org/html/intro-of-nginx-module-development.html
http://www.evanmiller.org/ nginx-modules-guide.html
There are many basic types of nginx, what are the meanings of each type
There are many, many articles of this kind, you can find many by searching on google
I recommend several people’s blogs:
http://blog.csdn.net/livelylittlefish/article/details/7262750
http://blog.csdn.net/dingyujie/article/details/7162919
nginx development from entry to proficiency http://tengine. taobao.org/book/
Note: It was made by a group of experts from Taobao, and many things are explained in great detail. It is also very systematic and highly recommended
Introduction to nginx module development http://www.162cm.com/p/ngx_ext.html
Note: Introductory tutorial
Tutorial book:
"In-depth understanding of Nginx -- module development and architecture Analysis》Tao Hui
Note: A very systematic talk about the module development and architecture of nginx
《In-depth analysis of Nginx》Gao Qunkai
The above introduces nginx source code learning resources, including github content. I hope it will be helpful to friends who are interested in PHP tutorials.