自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

佼佼者

The perl way never say die

  • 博客(95)
  • 资源 (3)
  • 收藏
  • 关注

原创 CentOS Too many open files

打开Terminal提示下列报错There was an error creating the child process for this terminalFailed to create pipe for communicating withchild process (Too many open files) 解决方法vim /etc/security/limits.co...

2013-12-13 16:50:27 1035

Python expect模块

Expect python也是有支持的,只不过换个名字pexpext而已.status = pexpect.spawn('ssh %s "%s"' % (host,command)) #此处需要执行的命令    try:        i = status.expect(['password:', 'continue connecting (yes/no)?'], timeout=1)...

2013-12-07 12:40:43 2659

Perl实现批量安装NRPE客户端

近期要安装N多台Linux主机的NRPE客户端,话说我这么“懒”的人怎么可能会一个个自己安.批量处理的简单小程序就用perl来做吧! # tar -tf BatchNrpe.tar.gzBatchNrpe/BatchNrpe/install.shBatchNrpe/Check_Nrpe.plBatchNrpe/nrpe-2.15.tar.gzBatchNrpe/Batch_Instal...

2013-12-04 19:49:31 237

Perl Expect模块

Expect是Unix系统中用来进行自动化控制和测试的软件工具,由Don Libes制作,作为Tcl脚本语言的一个扩展,应用在交互式软件中如telnet、ftp、Passwd、fsck、rlogin、tip、ssh等等.该工具利用Unix伪终端包装其子进程,允许任意程序通过终端接入进行自动化控制;也可利用Tk工具,将交互程序包装在X11的图形用户界面中. 当然Perl也集成了Expect...

2013-12-04 19:29:23 506

vi/vim 快捷操作

删除空行:g/^$/d 替换空格为回车:s/ /\r/g 清空文件gg + dG 删除当前行到最后dG

2013-12-02 11:45:24 117

CentOS 部署Subversion + Apache版本控制服务器

安装前提安装步骤配置subversion一、安装前提 1.关闭防火墙# service iptables stop# chkconfig iptables off# service ip6tables stop# chkconfig ip6tables off 2.关闭SElinux# perl -i -p -e 's/=enf...

2013-11-30 12:08:55 183

Perl 操作符优先级

                                                                        操作符优先级结合性元数优先级无左无右右左左左左右无无左左左左无右右左右右左左02121222...

2013-11-26 22:52:36 821

firefox is already running

出现firefox is already running的原因是没有正常关闭firefox. 按照Google的方法将~/.mozilla/firefox/*.default目录下的lock删除掉 问题依旧. 自己动手丰衣足食:索性将.mozilla移走或删除即可....

2013-11-25 12:43:38 653

Kernel Panic - not syncing: Attempted to kill init!

Ghost CentOS新系统后提示报错: Kernel Panic - not syncing: Attempted to kill init! 解决方法将Bios中硬盘模式更改为AHCI即可

2013-11-19 16:58:41 222

Yum 参数

1.使yum安装i686以及X86_64全部软件包vim /etc/yum.conf新增一行multilib_policy=all 2.使yum安装非i686以及i386全部软件包vim /etc/yum.conf新增一行exclude=*.i?86  ...

2013-11-19 14:43:11 198

CentOS 释放内存

内存占用原因当读写文件的时候,Linux内核为了提高读写性能与速度,会将文件在内存中进行缓存,这部分内存就是Cache Memory.即使你的程序运行结束后,Cache Memory也不会自动释放.这就会导致你在Linux系统中程序频繁读写文件后,你会发现可用物理内存会很少. 处理方法一Cache Memory在你需要使用内存的时候会自动释放,所以你不必担心没有内存可用.处理方法二如果...

2013-11-18 15:59:22 285

no device found for connection 'System eth0'

使用cloneZlia Ghost CentOS系统后,启动会莫名其妙的出现网卡错误# ifconfig eth0eth0: unknown interface :No such device 使用ifconfig命令查看发现网卡认到eth1,那我们就将错就错将eth0变更为eth1# cp /etc/sysconfig/network-scripts/if...

2013-11-15 14:55:17 158

freeswitch configure: error: libtermcap, libcurses or libncurses are required!

编译安装freeswitch 1.2.14报错error: libtermcap, libcurses or libncurses are required! # yum install libtermcap# yum install ncurses-devel 

2013-11-13 16:33:53 992

CentOS 内核裁剪

1.下载系统对应内核版本https://www.kernel.org/pub/linux/kernel/ 2.将本机内核配置文件拷贝至新下载的内核包中# tar -zxvf linux-2.6.32.tar.gz# cd linux-2.6.32# cp /boot/config-2.6.32-279.el6.x86_64 .config 3.使用ma...

2013-11-11 19:18:47 924

CentOS 安装网卡驱动

1.查看网卡型号# lspci00:00.0 Host bridge: Intel Corporation 3rd Gen Core processor DRAM Controller (rev 09)00:01.0 PCI bridge: Intel Corporation 3rd Gen Core processor PCI Express Root Port (rev 09)00:...

2013-11-11 17:15:58 960

CentOS 安装显卡驱动

1.查看CentOS显卡型号# lspci00:00.0 Host bridge: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor DRAM Controller (rev 09)00:01.0 PCI bridge: Intel Corporation Xeon E3-1200 v2/3rd Gen Core p...

2013-11-11 16:44:22 681

No package 'gtk+-2.0' found

编译安装Gtk2提示No package 'gtk+-2.0' found 安装yum install libgnomeui-devel 重新编译即可

2013-11-07 17:30:57 3080

No package 'cairo' found

编译安装Cairo提示No package 'cairo' found 是缺少devel造成yum install glib-develyum install atk-develyum install pango-devel yum install cairo-devel 再次编译通过.

2013-11-07 17:16:12 6370

perl 引起构造

                                                       引起构造常用通用含义可否内插' ' " " ` ` ( ) / / s/ / / y/ / / "  "q/ / qq/ / qx/ / qw/ / m/ ...

2013-11-07 13:12:10 83

CentOS 6.3 X86_64 安装CitrixClient

下载Receiver for Linux 12.1登录至http://www.citrix.com/downloads/citrix-receiver/linux/receiver-for-linux-121.html  更改yum配置使yum安装i686以及X86_64全部软件包vim /etc/yum.conf新增一行multilib_policy=all ...

2013-11-05 18:03:47 406

Perl 布尔值 真真&&假假

Perl中,真总是在标量环境中处理.1.除""和"0"外,所有的字符串为真.2.除0外,所有数字为真.3.所有引用为真.4.所有未定义的值为假. 

2013-11-03 16:40:19 637

Monitoring Linux/Unix Machines

监控Linux或Unix主机  一、概述 有两种不同的方法监控linux/Unix主机的服务器和属性:第一种是使用共享SSH键和check_by_ssh插件来执行远程服务器上的插件.这种方法会导致被监控的服务器负载过高不推荐使用.第二种是使用NRPE插件,NRPE允许你执行远程服务器上的插件,推荐使用此种方式.  二、NRPE的使用1.概述a)设计NRP...

2013-11-03 16:19:25 148

fsck.ext3 no such file or directory while trying to open /dev/sdb1

问题现象解决步骤一、问题现象启动linux主机时提示fsck.ext3 no such file or directory while trying to open /dev/sdb1可是目前主机中只有sda硬盘,没有sdb这块硬盘. 二、解决步骤1.首先输入root密码进入bash中2.查看/etc/fstab中硬盘挂载情况,果不其然有一块sdb硬盘挂载至本...

2013-10-28 19:25:42 1620

批量编译安装Perl模块

查看当前系统安装模块批量编译安装Perl模块验证 一、查看当前系统安装模块# cat CheckModule.pl#!/usr/bin/perluse strict;use ExtUtils::Installed;my $inst = ExtUtils::Installed->new();my @modules = $inst->...

2013-10-24 13:21:16 362

Monitoring Windows Machines

监控windows主机1.概述如果想监控windwos主机就需要安装客户端,而这个客户端是Nagios plugin和windows机器之间的传递的介质.那么这个客户端是NSClient++,Nagios服务器端使用check_nt插件和NSClient++插件进行数据交互. 2.监控windows的步骤①.满足首次安装条件;②.在windows主机上安装客户端;③...

2013-10-23 15:22:02 172

Citrix Receiver for Linux 12.1:ERROR : machine architecture could not be decided

问题现象解决步骤一、问题现象安装 Receiver 报错ERROR : machine architecture could not be decided. 二、解决步骤# vi linuxx86/hinstecho $Arch|grep "i[0-9]86" >/dev/null 更改为echo$Arch|grep "86" >/dev/n...

2013-10-15 17:55:20 149

Citrix Receiver for Linux 12.1:nspluginwrapper: command not found

问题现象解决步骤一、问题现象安装Receiver 12.1时报错nspluginwrapper: command not found 二、解决步骤# vi linuxx86/hinst将所有nspluginwrapper替换为mozilla-plugi-config:%s/nspluginwrapper/mozilla-plugin-config/ ...

2013-10-15 17:49:08 179

Yum Warning: RPMDB altered outside of yum.

错误现象解决步骤一、错误现象# yum -y install libXfontLoaded plugins: fastestmirror, refresh-packagekit, securityLoading mirror speeds from cached hostfileSetting up Install ProcessResolving Depende...

2013-10-15 10:33:49 2924

sqlplus echo

sqlplus中可以通过控制echo的开关来停止关闭脚本执行中的显示过程 在sqlplus中执行sql脚本有三种形式1. start sql2. @sql3. @@sql echo设置默认关闭,关闭状态下的脚本执行只有结果,不显示执行过程SQL> show echoecho OFFSQL> host cat /tmp/select.sqls...

2013-10-11 21:56:05 487

sqlplus remark

数据库脚本中注释功能有三种 1.remarkSQL> help remark REMARK ------ Begins a comment in a script. SQL*Plus does not interpret the comment as a command. REM[ARK]rem或remark开头的数据库脚本行中,此行为注...

2013-10-11 21:39:16 605

edit sqlplus Buffer

修改追加插入删除无论对sqlplus buffer进行修改、追加还是插入操作都必须将操作的对象修改为当前行 设置当前行方式有两种1.直接输入行号2.list + 行号  一、修改 修改beffer中的值SQL> select count(*) 2 from bonus 3 ; COUNT(*)-...

2013-10-11 21:09:41 173

sqlplus PAUSE

假设bonus表中有1000行数据,通过sqlplus查询bonus表中的所有数据 select * from bonus;可以发现数据一行一行很快速的从你眼前飞过,如果有一个类似于linux下more或者less的工具就好了. of course!!!SQL> help pause PAUSE ----- Displays the speci...

2013-10-10 21:29:54 259

a.m. && p.m.

a.m. 与 p.m. 来源 a.m. 和 p.m. 都是简写,实际拼写 a.m.    ==    ante meridiemp.m.    ==    post meridiem meridiem拉丁语意译为“正午” ante [ˈænti]    <->    before [bɪˈfɔː(r)] before 表示“在...之前”...

2013-10-10 20:23:45 251

Perl DBI 操作数据库

连接实例显示sql结果实例模块名称DBI 一、连接实例my $sql = qw{ sql };my $dbh = DBI->connect("DBI:数据库类型:database=数据库名称;host=localhost","root","passwd", {'RaiseError' => 1});my $sth=$dbh->prepa...

2013-10-09 13:10:14 219

Perl CGI模块

导入使用CGI模块文本网页文本输入框多选项选择提交按钮字体设定字体颜色设定 一、导入使用CGI模块 第一、use CGI引用函数需要使用my $query = CGI->new;print $query->XXX. 第二、use CGI qw/:standard/;引用函数可直接使用print XXX....

2013-10-08 15:52:39 711

Linux Apache 2 增加Perl CGI支持

1.安装Apache mod_perl.so模块yum install mod_perl.so  2.修改Apache配置文件# vi /etc/httpd/conf/httpd.conf 第一:增加Perl支持AddHandler cgi-script .cgi修改为AddHandler cgi-script .cgi .pl 第二:重定向cgi脚...

2013-10-08 12:08:21 163

sqlplus HELP

使用sqlplus命令登录系统后,查看help$ sqlplus systemSQL*Plus: Release 11.2.0.1.0 Production on Tue Oct 1 09:33:36 2013Copyright (c) 1982, 2009, Oracle. All rights reserved.Enter password:Conne...

2013-10-01 09:43:15 246

Oracle Error ORA-01950

错误现象解决步骤 一、错误现象 使用SQL*Loader向scott用户的bonus表导入数据时,提示插入了数据$ sqlldr scott/tiger control=ldr_case.ctlSQL*Loader: Release 11.2.0.1.0 - Production on Mon Sep 30 16:06:18 2013Copyri...

2013-09-30 16:30:16 284

原创 Oracle 11G 创建scott用户

新装完Oracle 11GR2数据库后准备使用scott登录$ sqlplusSQL*Plus: Release 11.2.0.1.0 Production on Sun Sep 29 15:29:41 2013Copyright (c) 1982, 2009, Oracle. All rights reserved.Enter user-name: scott...

2013-09-29 15:41:09 763

Ubuntu 10.04 强制关机Target filesystem doesn't have /sbin/init错误

错误现象解决步骤 一、错误现象 Ubuntu 10.04 强制关机后启动提示mount: mounting /dev on /root/dev failed: No such file or directorymount: mounting /sys on /root/sys failed: No such file or directorymount: mo...

2013-09-29 11:31:27 781

Lesson 4 Are you a teacher

Lesson 4 Are you a teacher 新概念第一册

2013-08-10

Lesson 2 Sorry,sir

Lesson 2 Sorry,sir 新概念第一册第二课 sorry sir

2013-08-06

Lesson 1 Excuse me!

新概念第一册第一课 lesson 001 Excuse me!

2013-08-05

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除