搜索""的结果
LVS+keeplived+nginx+apache搭建高可用、高性能php集群 基于PHP的运行环境大家用的比较多的是以apache做中间件的LAMP(linux+apache+mysql+php)环境和以nginx做中间件的LNMP(linux+nginx+mysql+php)环境,apache是世界排名第一的web服务器,apache可以整合大多数应用,比如jsp,php,cgi,python等等,但是apache过于臃肿以及对静态文件响应过于缓慢是让人很不满意的;而nginx作为后起之秀,大有超越前辈的势头,从最近很多门户网站选用nginx就可见一斑,nginx速度快,占用资源少,高性能转发,很高的稳定性,支持热部署,杀手级的proxy和rewrite,但nginx对于php处理依托于fastcgi,fastcgi不够稳定,经常出现502错误,生成相对复杂的页面没有优势,反而会使php-cgi进程变为僵尸进程,多用户多站点的安全性不高,对于其它开发语言的整合,apache表现的更好;综上述对比,为了搭建高性能的php运行环境,就要考虑对apache、nginx进行整合,各取所长,nginx在处理静态内容上的效率较apache强很大,那么就用nginx在前端处理静态文件,把基于php的动态文件转发到后端的apache来处理,接下来我们就开始布署LNAMP(linux+nginx+a...
tomcat+Apache如何配置代理服务器转发端口号 因为tomcat只能配置一个网站,所以如果是自己单独的服务器,,那没有太大的影响,可以直接只安装一个tomcat便可以运行。但有时候,如果同时有多个,或是许多个,tomcat只能配置一个站点,所以要想运行多了个站点,那就只有多安装几个tomcat了。但另一方面那服务器的80总归只有一个,这样,配置多个tomcat的时候会发现,只能使用其它端口了,这样肯定是不行的。怎么办呢,那就只有想办法,将tomcat的非80端口使用代理了,这样,就成了80端口了,同时又可以运行多个网站。apache作代理服务器时,转发用户端口号到tomcat的方法有很多,这是其中之一,需要用到mod_rewrite 和 mod_headers这两个模块。下面是步骤:1.在apache配置文件中追加对上面两个module的引用,不同的系统方法略有区别。大致如下:[python]LoadModule rewrite_module /usr/lib64/apache2-prefork/mod_rewrite.so LoadModule headers_module /usr/lib64/apache2-prefork/mod_headers.so 2.然后在apache配置文件中追加...
How to Set Cores-Per-Socket Parameter for a Virtual Machine CTX126524Created onMar 26, 2014Updated onNov 10, 2014 40 found this helpful Article Topic : Configuration See Applicable Products Objective This article describes how to set the cores-per-socket parameter for a Windows Virtual Machine (VM). This procedure does not apply for Linux VMs.When you assign virtual CPUs to a VM, by default one virtual CPU is equal to one socket. Some VMs have higher core limitations. By setting the cores-per-socket parameter, it is possible to present a VM with a certain number of cores.Notes:This feature is only available in the Advanced, Enterprise, and Platinum editions and is not available in the free version of XenServer. For example, if you have a dual socket quad core server and a XenServer Advanced, Enterprise, or Platinum ...
XenServer6 虚拟机多vCPU配置方法在服务器虚拟化项目或者虚拟桌面项目中,经常会碰到这样的问题,虚机为高负载类型的业务,对CPU的要求很高的时候,我们希望为这些虚拟桌面分配更多的CPU资源,但是我们也发现,部分系统对CPU数量的支持有数量的限制,超过以后,即使分配,也没法利用到。也有一些软件会依据CPU的数量(socket的数量)来收费,所以也需要对CPU进行一些调整来减少费用。首先说一下,在CPU中有几个概念:Socket、Core、Hyper-Threading(HT)。首先得搞清楚这些。Socket:wikipedia的解释是连接到主板的一个CPU,通俗讲就是一个物理CPUCore:wikipedia的解释同一个CPU芯片上集成的多个核心,也就是所谓的多核的核Hyer-Threading:wikipedia的解释模拟的多线程,通俗讲在一个核心上模拟出两个CPU执行线程,能够提高多任务的性能搞明白了这些以后,我们就来说说系统本身对CPU这几方面的支持限制。操作系统对CPU的支持分Socket和Core两方面,而Hyper-Threading对操作系统来说基本是不可见的(其实可以通过CPU参数以及其他机制系统会知道开启了超线程)所以,HT可以简单理解为也是core。windows 2003等服务器操作系统对物理CPU(socket)以及多核CPU(multi-Core)的...
Mac OS X 安装Octave说明 第一: Xcode以及Command Line Tool (CLT) 第二: Xquatz,并建立软连接为X11sudo ln -sf /Applications/Utilities/XQuartz.app/ /Applications/Utilities/X11.app 第三:使用homebrew安装Octavebrew tap homebrew/sciencebrew install gmp --build-from-sourcebrew install gfortranbrew install octavebrew install gnuplot第四:设置环境变量echo "export GNUTERM='X11'" >> .bash_profile最后汇报一下安装的依赖, 方便以后想要卸载时好卸载干净Installing dependencies for gfortran: mpfr, libmpc, isl, cloogInstalling dependencies for octave: gnu-sed, texinfo, fftw, tbb, suit, glpk, graphicsmagick,szip,hdf5,pcre,cmake, qhull, dotwrp, qrupdate, fltk, gnuplot lua
Binary installer for OSX 10.9.1A binary installer for Mavericks can be found on Octave Forge.This installer will install all binaries for GNU Octave 3.8.0 itself and its dependencies under /usr/local/octave/3.8.0
And will create two entries in the Applications folder /Applications/Octave-cli.app
/Applications/Octave-gui.app
Which will start Octave in CLI and GUI mode respectively, these are just small wrappers containing a startup script and an icon to allow launching Octave from the Finder. If you wish to uninstall GNU Octave 3.8.0 and all other software installed by this installer you can simply move the three folders listed above to the Trash. Notice that you will need to authenticate with an administrator password to be allowed to do so.You may need to override Gatekeeper to allow installation. You may find instructions about how to do this on this page in the section labeled "How to open an app from a unidentified developer and exempt it from Gatekeeper". In shor...
apache的mod_speling模块安装配置说明这个模块你可以这样去生成1、下载一个与当前使用的apache一样版本的安装包2、解压安装包,然后进入其目录#cd /tmp/httpd-2.2.11/modules/mappers/#ls ,此目录有个mod_speling.c文件3、生成模块/usr/local/apache/bin/apxs -c -i -a mod_speling.c注:usr/local/apache/为我生产环境的apache目录,完成上述后会在/usr/local/apache/modules/目录下多一个mod_speling.so模块文件4、重启httpd服务 PS: <VirtualHost 192.168.1.227:80># ServerAdmin admin@zj.comDocumentRoot /var/www/html/# ErrorDocument 404 http://www.zj.com CheckSpelling On (加上这个)ServerName 122.222.222.222# ErrorLog /var/log/httpd/zjnetbarerror_log# CustomLog /var/log/httpd/zjnetbar_log combined</VirtualHost>默认情况下,在apahce服务器中,有网址 /Tansf/ ,但如果访问 /tansf/ ,apache是不能识别的(即不能把t改为T)。 &...
Shell脚本编程的常识七种文件类型正则表达式字符类描述shell的引号类型变量设置时的不同模式:条件测试命令执行顺序脚本调试一些常用的小trick打印一些头信息创建一个长度为0的空文件一些常用的shell变量$0的使用Shift的运用用head或tail指令指定查阅的行数awk使用规则第一个 awk多个字段外部脚本BEGIN 和 END 块规则表达式和块条件语句数值变量字符串化变量众多运算符字段分隔符字段数量记录号多行记录OFS 和 ORS将多行转换成用 tab 分隔的格式循环结构for 循环break 和 continue数组下标字符串化数组工具格式化输出字符串函数一些更耐人寻味的函数字符串替换特殊字符串形式sed使用规则sed 示例另一个 sed 示例地址范围带规则表达式的地址有关地址的更多内容替换规则表达式混乱更多字符匹配高级替换功能组合使用一个地址的多个命令附加、插入和更改行使用 sed 的几个示例linux常用脚本和函数linux常用命令关于文件/目录处理的指令:关于 Process 处理的指令:关于字符串处理的指令:联机查询的指令:网络运用指令:Vi常用技巧 Shell脚本编程的常识(这些往往是经常用到,但是各种网络上的材料都语焉不详的东西,个人认为比较有用)七种文件类型d &nb...
服务器跑一个应用,但是日志没有分割,导致日志文件很大,这里使用系统自带的logrotate来处理日志分割,分丢失部分信息。[root@cwtbs2 check]# cat /etc/logrotate.d/cwtserver /home/cwt/BS/cwtserver.log{ weekly missingok notifempty copytruncate size 500M create 0640 cwt cwt dateext rotate 32}
最新评论