当前位置: 首页 > news >正文

南宁网站开发招聘小型微利企业所得税优惠政策

南宁网站开发招聘,小型微利企业所得税优惠政策,北京网站建设外包公司,两个网站合并建设实施方案写在前面#xff1a;如果此文有幸被某位朋友看见并发现有错的地方#xff0c;希望批评指正。如有不明白的地方#xff0c;愿可一起探讨。案例拓扑图安装keepalived和nginx安装keepalived# yum -y install keepalived创建nginx用户组及nginx用户# groupadd -r nginx # userad… 写在前面如果此文有幸被某位朋友看见并发现有错的地方希望批评指正。如有不明白的地方愿可一起探讨。案例拓扑图安装keepalived和nginx安装keepalived# yum -y install keepalived创建nginx用户组及nginx用户# groupadd -r nginx # useradd -g nginx -r nginx编译安装nginx-1.4.7# tar xf nginx-1.4.7.tar.gz  # cd nginx-1.4.7 # ./configure \--prefix/usr \--sbin-path/usr/sbin/nginx \--conf-path/etc/nginx/nginx.conf \--error-log-path/var/log/nginx/error.log \--http-log-path/var/log/nginx/access.log \--pid-path/var/run/nginx/nginx.pid  \--lock-path/var/lock/nginx.lock \--usernginx \--groupnginx \--with-http_ssl_module \--with-http_flv_module \--with-http_stub_status_module \--with-http_gzip_static_module \--http-client-body-temp-path/usr/local/nginx/client/ \--http-proxy-temp-path/usr/local/nginx/proxy/ \--http-fastcgi-temp-path/usr/local/nginx/fcgi/ \--http-uwsgi-temp-path/usr/local/nginx/uwsgi \--http-scgi-temp-path/usr/local/nginx/scgi \--with-pcre # make  make install检查配置文件是否有语法错误[rootlocalhost nginx-1.4.7]# nginx -t nginx: the configuration file /etc/nginx/nginx.conf syntax is ok nginx: [emerg] mkdir() /usr/local/nginx/client/ failed (2: No such file or directory) nginx: configuration file /etc/nginx/nginx.conf test failed修改错误# mkdir /usr/local/nginx再次检查配置文件是否有语法错误[rootlocalhost nginx-1.4.7]# nginx -t为nginx提供SysV init脚本# vim /etc/rc.d/init.d/nginx#!/bin/sh # # nginx - this script starts and stops the nginx daemon # # chkconfig:   - 85 15  # description:  Nginx is an HTTP(S) server, HTTP(S) reverse \ #               proxy and IMAP/POP3 proxy server # processname: nginx # config:      /etc/nginx/nginx.conf # config:      /etc/sysconfig/nginx # pidfile:     /var/run/nginx.pid# Source function library. . /etc/rc.d/init.d/functions# Source networking configuration. . /etc/sysconfig/network# Check that networking is up. [ $NETWORKING  no ]  exit 0nginx/usr/sbin/nginx prog$(basename $nginx)NGINX_CONF_FILE/etc/nginx/nginx.conf[ -f /etc/sysconfig/nginx ]  . /etc/sysconfig/nginxlockfile/var/lock/subsys/nginxmake_dirs() {# make required directoriesusernginx -V 21 | grep configure arguments: | sed s/[^*]*--user\([^ ]*\).*/\1/g -options$nginx -V 21 | grep configure arguments:for opt in $options; doif [ echo $opt | grep .*-temp-path ]; thenvalueecho $opt | cut -d  -f 2if [ ! -d $value ]; then# echo creating $valuemkdir -p $value  chown -R $user $valuefifidone }start() {[ -x $nginx ] || exit 5[ -f $NGINX_CONF_FILE ] || exit 6make_dirsecho -n $Starting $prog: daemon $nginx -c $NGINX_CONF_FILEretval$?echo[ $retval -eq 0 ]  touch $lockfilereturn $retval }stop() {echo -n $Stopping $prog: killproc $prog -QUITretval$?echo[ $retval -eq 0 ]  rm -f $lockfilereturn $retval }restart() {configtest || return $?stopsleep 1start }reload() {configtest || return $?echo -n $Reloading $prog: killproc $nginx -HUPRETVAL$?echo }force_reload() {restart }configtest() {$nginx -t -c $NGINX_CONF_FILE }rh_status() {status $prog }rh_status_q() {rh_status /dev/null 21 }case $1 instart)rh_status_q  exit 0$1;;stop)rh_status_q || exit 0$1;;restart|configtest)$1;;reload)rh_status_q || exit 7$1;;force-reload)force_reload;;status)rh_status;;condrestart|try-restart)rh_status_q || exit 0;;*)echo $Usage: $0 {start|stop|status|restart|condrestart|try-restart|reload|force-reload|configtest}exit 2 esac赋予nginx脚本执行权限# chmod x /etc/rc.d/init.d/nginx添加至服务管理列表并让其开机自动启动# chkconfig --add nginx # chkconfig nginx on提示在两个keepalivednginx主机上都需安装keepalkved和nginx服务配置nginx为反向代理服务器编辑nginx.conf配置文件# cd /etc/nginx/ # vim nginx.conf在nginx.conf配置文件中的http段内添加如下内容upstream webservers {server 10.170.2.101;server 10.170.2.102; } server {listen 80;server_name www.muluhe.com;location / {proxy_pass http://webservers;proxy_set_header X-Real-IP $remote_addr;} }提示在两台keepalivednginx主机的nginx.conf的配置文件所添加的内容一样配置keepalived编辑keepalived.conf配置文件# cd /etc/keepalived/ # vim keepalived.confIP地址为10.170.2.60的配置文件内容为! Configuration File for keepalived global_defs {notification_email {acassenfirewall.locfailoverfirewall.locsysadminfirewall.loc}notification_email_from Alexandre.Cassenfirewall.locsmtp_server 192.168.200.1smtp_connect_timeout 30router_id LVS_DEVEL } vrrp_instance VI_1 {state MASTERinterface eth0virtual_router_id 15priority 100advert_int 1authentication {auth_type PASSauth_pass 111111}virtual_ipaddress {10.170.2.100}notify_master /etc/init.d/nginx startnotify_backup /etc/init.d/nginx stopnotify_fault /etc/init.d/nginx stop }IP地址为10.170.2.61的配置文件内容为! Configuration File for keepalived global_defs {notification_email {acassenfirewall.locfailoverfirewall.locsysadminfirewall.loc}notification_email_from Alexandre.Cassenfirewall.locsmtp_server 192.168.200.1smtp_connect_timeout 30router_id LVS_DEVEL } vrrp_instance VI_1 {state BACKUPinterface eth0virtual_router_id 15priority 99advert_int 1authentication {auth_type PASSauth_pass 111111}virtual_ipaddress {10.170.2.100}notify_master /etc/init.d/nginx startnotify_backup /etc/init.d/nginx stopnotify_fault /etc/init.d/nginx stop }配置web1和web2服务器编辑web1测试页面# vim /var/www/html/index.html 内容为h1www1.muluhe.com/h1启动httpd服务# /etc/init.d/httpd start编辑web2测试页面# vim /var/www/html/index.html 内容为h1www2.muluhe.com/h1启动httpd服务# /etc/init.d/httpd start启动keepalived服务并进行测试启动keepalivednginx两台主机的keepalived服务# /etc/init.d/keepalived start在浏览器中键入10.170.2.100刷新几下可得到如下结果关闭IP地址为10.170.2.60那台主机的keepalived服务# /etc/init.d/keepalived stop再次在浏览器中键入10.170.2.100刷新几下查看结果如下由以上结果可以keepalived实现了nginx反向代理的高可用以及nginx实现了web的负载均衡效果。 转载于:https://blog.51cto.com/muluhe/1555180
http://www.zqtcl.cn/news/728848/

相关文章:

  • 旅游网站开发团队四川住房和城乡建设网站
  • 网站框架设计商城网站制作需要多少费用
  • 网站建设哪个公司个人网站做哪种能赚钱
  • 福建建设人才与科技发展中心seo导航站
  • 修文县生态文明建设局网站郑州制作网站哪家好
  • 泉州网站优化排名东莞长安做网站公司
  • 网站制作公司 顺的有口碑的赣州网站建设
  • 成都网站设计制作苏州新闻
  • 黑色网站设计iis 网站 红
  • 专业做家居的网站佛山做网站永网
  • 医疗网站建设讯息企业门户网站建设思路
  • 四川建设安全监督管理局网站网站传送门怎么做
  • 哪家网站做推广好优化师和运营区别
  • 鹰潭网站建设公司南宁行业平台开发公司
  • 织梦如何仿手机网站源码奉贤区专业建网站
  • 上海网站建设接单wordpress htaccess 404
  • 长春网站优化指导网站怎样做301跳转
  • 做网站域名是什么意思临沧网站开发
  • 怎么在网站上做网页专业图库网站 西安
  • 龙南建设局网站wordpress 购物导航网站
  • 做数据分析好看的网站自己做背景的网站
  • 做纸棋的网站制作什么网站做毕业设计
  • 上海易雅达网站建设公司广元网站开发
  • 网站备案注销北京优化健康宝
  • 网站地图怎么做XML深圳公共资源交易中心
  • 高碑店做网站的公司湛江专业建站推荐
  • 中国建设银行官网的网站首页c2c电子商务网站建设栏目结构图
  • 做网站的软件图标上海建站外贸
  • 保定网站建设推广成都移动端网站建设
  • 服务平台型网站做那个网站比较好