find / ! -user root ! -user bin ! -user student -ls 2 > /dev/null
find / -perm +7000 -exec ls -l {} \;
ps axf -o pid,comm,%cpu,%mem,state,tty,euser,ruser,nice
ps aux
比较如下三种方法:
$ ps axo pid,comm|grep 'cups'
2734 cupsd
3502 eggcups
$ pgrep cups
2734
3502
$ pidof cupsd 获取进程 PID 最准确的方法
2734
( man 7 signal )
kill 3428 = kill -9 3428
kill -15 3428 = kill -SIGTERM 3428
killall syslogd
service syslog status
ping -c1 -W1 baidu.com
---------------------------------------------------------
ps axo pid,comm,pcpu --sort=-pcpu
top -d 2
top -b -n 2 > /tmp/top.log
top -d 2 -p 3721
pstree -Aup
dmesg | grep -i hd
uptime
uname -r
free -m
vmstat 1 3 (1/secs total:3)
vmstat -d
yum install -y sysstat
iostat -d 2 3
lsof -u root -a -U
lsof +d /dev
lsof -u root | grep bash
pifof init syslogd
man 7 signal (kill -l)
SIGHUP 1
SIGINT 2
SIGKILL 9
SIGTERM 15
SIGSTOP 17,19,23
kill -15 3721
killall -15 cupsd
PRI(new)=PRI(old) + nice
nice (-20 ~ 19)
root: -20 ~ 19
genuser: 0 ~ 19
nice -n -5 vi &
renice 10 3721
# Open telnet login for root
# delete or rename "/etc/securetty"
mv /etc/securetty /etc/securetty.bak
# vim /etc/pam.d/login and comment the item below
#auth required pam_securetty.so
# ATTENTION: I advise you not to do that..
54,1 Bot
阅读(1413) | 评论(0) | 转发(0) |