【汇总】Superor作品:探索Perl的世界(到43集)下..

写在前面.非常非常感谢 Superor 拿出自己的时间,为中国的 Perl 界做出了第一个中文视频教程,象别的语言都有很好的教程。Perl 的相比起来还是少.看视频,在入门时还是相当方便的,就象电影来看就好了。我基本 Superor 老师每出一集我都看了。希望大家也认真看看。 记的,学习时要多写,只能看明白,只有 5% 是你的,练习都做一做,就有 30% 是你的啦。其它的如果能根据教程,...

作者: edgeman03 发布时间: 09-06

IPTABLES常用规则

#!/bin/sh #外网网卡 EXT_IF="eth0" FW_IP="61.137.85.21" #内网网卡 INT_IF="eth1" LAN_IP="192.168.0.1" LAN_IP_RANGE="192.168.0.0/255.255.255.0" #加载模块,一般已内建 #Module loading. #echo "modprobe modules" #modprode ip_tables #modprode ip_nat_ftp #modprode ip_conntrack #modprobe ip_conntrack_ftp #启用转发(forward)功能 echo "enabling IP FORWARDING....

作者: unixsly 发布时间: 09-06

删除过期文件shell

#!/bin/bash DelDateFile=`date -d '-10 day' +%Y-%m-%d` DirN=(/opt/dicc/logs /opt/dicc/jboss4.0.5.ccr/server/default/log ) for DirName in ${DirN[@]} do find $DirName -type f|grep $DelDateFile > /tmp/DelLogFile if [ ! -f /tmp/DelLogFile ] then exit 1 fi for FileName in `cat /tmp/DelLogFile` do rm -rf $FileName done done #要删除的文件名和要DelDateFi...

作者: dicc 发布时间: 09-03

shell 一句

1、tee将信息输出到多个文件 echo "ok" | tee -a a.txt b.txt c.txt 2、查看本机tcp连接状态及数目统计 netstat -n |awk '/^tcp/ {++S[$NF]} END {for(a in S) print a, S[a]}' | sort -n -k 2 -r 3、查出目前 ip_conntrack 记录最多的前五名 IP cat /proc/net/ip_conntrack | cut -d ' ' -f 10 | cut -d '=' -f 2 | sort | uniq -c | sort -nr | head -n 5 4、删除文件 fin...

作者: chibiaowu 发布时间: 09-02