1. echo 参数-n 不换行(默认换行)-e 使得转移字符有效例子ss='abc\n'echo -e $ssabc #换行起作用echo $ssabc2. 赋值时候=左右两侧不要带空格a = "hello" #错误a="hello"3. shell运算b=4let "c=$...
分类:
其他好文 时间:
2014-09-12 22:02:34
阅读次数:
298
while read line;do echo'kill '$line; kill $line;done ${db_name}# drop all table except finace tablemysql -h 192.168.107.253 -udkhs_data -pdkhs_...
分类:
其他好文 时间:
2014-09-12 18:47:43
阅读次数:
230
"connectionStrings" 路径是web.config所在的工程目录.1、加密EncryptWebConfig.bat@echo offC:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe-pef"connecti...
分类:
数据库 时间:
2014-09-12 16:52:24
阅读次数:
226
一般来说在header函数前不能输出html内容,类似的还有setcookie() 和 session 函数,这些函数需要在输出流中增加消息头部信息。如果在header()执行之前有echo等语句,当后面遇到header()时,就会报出 “Warning: Cannot modify header ...
分类:
其他好文 时间:
2014-09-12 16:48:03
阅读次数:
131
<?php
header("Content-type: text/html; charset=utf-8");
date_default_timezone_set(‘Asia/Shanghai‘);
set_time_limit(30);
tree("./ui");
function tree($directory) {
echo "$directory"."\n";
...
分类:
Web程序 时间:
2014-09-12 15:32:03
阅读次数:
229
1.开启block_dump,此时会把io信息输入到dmesg中echo1>/proc/sys/vm/block_dump统计当前占用IO最高的10个进程:dmesg|awk-F:‘{print$1}‘|sort|uniq-c|sort-rn|head-n102.测试完后,关闭block_dumpblock_dump参数echo0>/proc/sys/vm/block_dump
分类:
系统相关 时间:
2014-09-12 15:29:44
阅读次数:
299
#!/bin/bash
ip=`/sbin/ifconfig|grep"Bcast"|awk‘{print$2}‘|awk-F:‘{print$2}‘|head-n1`
cd/root/soft/memcached
#安装libevent
tarzxvflibevent-2.0.12-stable.tar.gz
cdlibevent-2.0.12-stable
./configure--prefix=/usr/local/libevent
make&&makeinstall
cd/root..
分类:
其他好文 时间:
2014-09-12 15:18:24
阅读次数:
176
xshell登录虚拟机能ping通,但是连接失败的问题。google了一下,发现是防火墙和sshd服务开启的问题。首先是关闭防火墙,同时开启22端口。然后是保证ssh服务的开户。我的系统(CENTOS6.5)下关闭防火墙命令如下:#/etc/init.d/iptablesstop#关闭防火墙#/etc/init.d/iptablesstatus..
分类:
其他好文 时间:
2014-09-12 15:16:34
阅读次数:
178