Nagios调用WSDL WebServer接口发送短信
使用JAVA调用短信网关WebServiceimport java.text.SimpleDateFormat;import org.apache.commons.lang.StringEscapeUtils;import java.io.File;import java.io.FileWriter;import java.io.BufferedWriter;import java.io.PrintWriter;public class AddSMSList { pu...
按照标准建立SSH互信后,ssh仍需要输入密码
两台机器创建ssh互信后,从a ssh b没问题,但反过来不可以,b ssh自己也不行原因是b的/root目录权限不对,不知被谁改成777,改回755后正常。[@more@]
puppet使用rsync插件,导致部分文件未成功更新
puppet+rsync插件,默认设置。昨天更新代码后,今天发现功能仍是之前的功能,被管理的服务器上直接查看文件,发现文件并未更新。由于更新内容极少,又恰好更新前后文件字节数完全一样。由于默认puppet的rsync插件为了提升同步速度,使用了--size-only参数。只同步字节数不同的文件,导致了此问题的发生。修改方式也很简单,在定义rsync目录的地方,增加size-only => false,并且,由于要对所有的代码进行同步,时间会比较长,还需要增加一下超时时间timeout => 10理论上代码更新前后字节数完全没变的情况还是比较少见的,不过,正如
Linux升级内核后报No volume groups found错误
今天尝试重新编译Linux内核,将内核版本从2.6.18-274.el5升级至2.6.39编译过程略,新内核的make localmodconfig功能,根据内核历史使用情况,进行内核瘦身的功能很不错。安装完毕,重启后,出现No volume groups found unable to find volume group "VolGroup00"原因的老的sysfs在新版本内核中,默认不支持。解决方法,增加如下两行:CONFIG_SYSFS_DEPRECATED=yCONFIG_SYSFS_DEPRECATED_V2=y升级后一切正常。[@more@]
Linux网卡绑定实现带宽翻倍
之前有过一篇BLOG,是介绍如何简单的将Linux两张网卡进行绑定,已实现高可用。但在之前的模式里,仅仅能实现高可用,当两个网卡中的一个失效时并不会影响服务器的联通性。但是,如果有交换机的配合,是否可以时间负载均衡,同时达到带宽翻倍的目的呢?首先,需要先明确,绑定的各种模式0 - Sets a round-robin policy for fault tolerance and load balancing. Transmissions are received and sent out sequentially on each bonded slave interface beginning with the first one available.1 - Sets an active-backup policy for fault
SCSI error : <1 0 1 1> return code = 0x10000
由于存储光纤交换机重新做了配置,并保存了配置信息,导致所有连接此交换机的系统全部报错:Linux:Jun 13 17:51:01 bhcx kernel: SCSI error : <1 0 1 1> return code = 0x10000Jun 13 17:51:01 bhcx kernel: end_request: I/O error, dev sdg, sector 98990423Jun 13 17:51:01 bhcx kernel: SCSI error : <1 0 1 1> return code = 0x10000Jun 13 17:51:01 bhcx kernel: end_request: I/O error, dev sdg, sector 98990431Jun 13 17:51:39 bhcx kernel: SCSI error : <1 0 1 1> return code = 0x10000Jun 13 17:51:39
装nagios报You don't have permission to access /nagios/ on this server. 错误
没装PHP导致rpm -Uvh php-5.1.6-23.2.el5_3.x86_64.rpm php-cli-5.1.6-23.2.el5_3.x86_64.rpm php-common-5.1.6-23.2.el5_3.x86_64.rpm gmp-4.1.4-10.el5.x86_64.rpmapachectl stopapachectl start 问题解决[@more@]
Linux上进行并行压缩
虽然我们有很多的CPU,每个CPU有很多的核,但是,在GZIP或BZIP2的时候,仅仅只能使用其中的一个核,如果压缩很大的文件或文件夹,将会等待很长的时间。幸好,现在有并行的GZIP及BZIP2可以使用,具体情况请参见下面的连接:Parallel GZIP PIGZ:http://www.zlib.net/pigz/Parallel GZIP2 pbzip2:http://compression.ca/pbzip2/[@more@]
PHP无法加载MYSQL模块
http://bugs.mysql.com/bug.php?id=19817[@more@]
Failing when including --with-mysql
http://bugs.php.net/bug.php?id=35848[@more@][30 Dec 2005 6:38am UTC] shawn dot richards at ink dot ltd dot uk Description: ------------ Mac OS X patched up to date. Apache 2. PHP 5 (latest snap) Compilation with --with-mysql option fails. Have tried compiling with MySQL 4.x Standard, 5.x Standard (preferred) and 5.x Debug. Same error every compilation even though MySQL works every time. Reproduce code: --------------- ./configure --with-apxs2=/usr/local/apache/bin/apxs --enable-
Linux 2.1 AS 下安装ISA接口的UNPNP网卡
Linux 2.1 AS下安装ISA接口的UNPNP网卡 [@more@]Dell GX1 PC,3com509b网卡1.在DOS方式下运行网卡驱动程序中带的配置程序,查看网卡的IO DMA等设置,并将该网卡PNP功能取消。(如更改了网卡的PNP选项,则需要冷启动计算机)2.vi /etc/modules.conf 添加: alias eth0 3c509 option 3c509 io=0x3003.运行insmod /lib/modules/2.4.9-e.3/kernel/drivers/net/3c509.o4.如果3运行成功,则 vi /etc/rc.d/rc.local 增加: insmod /lib/modules/2.4.9-e.3/kernel/driver