[root@localhost]$ cat 20161102.csv|grep "20161027"
Binary file (standard input) matches
解决办法:grep判断该文件为二进制文件,需添加参数 -a
zip命令:-x exclude the following names -i include only the following names
但 zip -r aaa.zip aaa -x /bbb/* 无效
正确方法:zip -r aaa.zip aaa -x \ccc\*,需要用反斜杠,或者:zip -r aaa.zip aaa -xbbb/*
tar命令:-zcvf aaa.tar.gz aaa --exclude=1 --exclude=2 无效
正确方法:tar -zcvf aaa.tar.gz --exclude=1 --exclude=2 aaa,需要先排除,后指定目录
Linux的很多命令都是依赖libc.so.6的动态链接库,如果不小心把它删除了,基本上所有命令都不能使用
LD_PRELOAD=/lib64/libc-2.12.so ln -s /lib64/libc-2.12.so /lib64/libc.so.6
ftp -n -i $HOSTNAME >> ftp.log << END
user $USERNAME $PASSWORD
binary
prompt
cd $FTPDIR
ls
bye
END
0 1 * * * free && sync && echo 3 > /proc/sys/vm/drop_caches && echo "" && free
ssh -p 2222 user1@192.168.1.1
sftp -oPort=2222 user1@192.168.1.1
rpm -ivh --nodeps glibc-devel-2.12-1.192.el6.x86_64.rpm
jar tf quartz-1.6.6.jar |grep JobFactory
org/quartz/simpl/PropertySettingJobFactory.class
org/quartz/simpl/SimpleJobFactory.class
org/quartz/spi/JobFactory.class
chage -M 99999 nwom