Linux服务器常用性能监控命令(日常命令参见更多more>>),整理如下
1、操作系统
[root@centos6 ~]# uname -a@b@Linux centos6.7.s2 2.6.32-573.el6.x86_64 #1 SMP Thu Jul 23 15:44:03 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux@b@[root@centos6 ~]# lsb_release -a@b@LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-noarch:graphics-4.0-amd64:graphics-4.0-noarch:printing-4.0-amd64:printing-4.0-noarch@b@Distributor ID: CentOS@b@Description: CentOS release 6.7 (Final)@b@Release: 6.7@b@Codename: Final@b@[root@centos6 ~]# cat /proc/version@b@Linux version 2.6.32-573.el6.x86_64 (mockbuild@c6b9.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-16) (GCC) ) #1 SMP Thu Jul 23 15:44:03 UTC 2015@b@[root@centos6 ~]# cat /etc/redhat-release@b@CentOS release 6.7 (Final)@b@@b@[root@centos6 ~]# lsblk@b@NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINT@b@sr0 11:0 1 1024M 0 rom @b@sdb 8:16 0 800G 0 disk /data210202@b@sda 8:0 0 500G 0 disk @b@├─sda1 8:1 0 500M 0 part /boot@b@└─sda2 8:2 0 499.5G 0 part @b@ ├─vg_centos6-lv_root (dm-0) 253:0 0 50G 0 lvm /@b@ ├─vg_centos6-lv_swap (dm-1) 253:1 0 2.9G 0 lvm [SWAP]@b@ └─vg_centos6-lv_home (dm-2) 253:2 0 446.6G 0 lvm /home
2、CPU
[root@centos6 ~]# lscpu@b@Architecture: x86_64@b@CPU op-mode(s): 32-bit, 64-bit@b@Byte Order: Little Endian@b@CPU(s): 3@b@On-line CPU(s) list: 0-2@b@Thread(s) per core: 1@b@Core(s) per socket: 1@b@Socket(s): 3@b@NUMA node(s): 1@b@Vendor ID: GenuineIntel@b@CPU family: 6@b@Model: 13@b@Stepping: 3@b@CPU MHz: 3192.000@b@BogoMIPS: 6384.00@b@Hypervisor vendor: KVM@b@Virtualization type: full@b@L1d cache: 32K@b@L1i cache: 32K@b@L2 cache: 4096K@b@NUMA node0 CPU(s): 0-2@b@[root@centos6 ~]# cat /proc/cpuinfo@b@processor : 0@b@vendor_id : GenuineIntel@b@cpu family : 6@b@model : 13@b@model name : QEMU Virtual CPU version (cpu64-rhel6)@b@stepping : 3@b@microcode : 1@b@cpu MHz : 3192.000@b@cache size : 4096 KB@b@physical id : 0@b@siblings : 1@b@core id : 0@b@cpu cores : 1@b@apicid : 0@b@initial apicid : 0@b@fpu : yes@b@fpu_exception : yes@b@cpuid level : 4@b@wp : yes@b@flags : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pse36 clflush mmx fxsr sse sse2 syscall nx lm unfair_spinlock pni cx16 hypervisor lahf_lm abm@b@bogomips : 6384.00@b@clflush size : 64@b@cache_alignment : 64@b@address sizes : 39 bits physical, 48 bits virtual@b@power management:@b@@b@processor : 1@b@vendor_id : GenuineIntel@b@cpu family : 6@b@model : 13@b@model name : QEMU Virtual CPU version (cpu64-rhel6)@b@stepping : 3@b@microcode : 1@b@cpu MHz : 3192.000@b@cache size : 4096 KB@b@physical id : 1@b@siblings : 1@b@core id : 0@b@cpu cores : 1@b@apicid : 1@b@initial apicid : 1@b@fpu : yes@b@fpu_exception : yes@b@cpuid level : 4@b@wp : yes@b@flags : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pse36 clflush mmx fxsr sse sse2 syscall nx lm unfair_spinlock pni cx16 hypervisor lahf_lm abm@b@bogomips : 6384.00@b@clflush size : 64@b@cache_alignment : 64@b@address sizes : 39 bits physical, 48 bits virtual@b@power management:@b@@b@processor : 2@b@vendor_id : GenuineIntel@b@cpu family : 6@b@model : 13@b@model name : QEMU Virtual CPU version (cpu64-rhel6)@b@stepping : 3@b@microcode : 1@b@cpu MHz : 3192.000@b@cache size : 4096 KB@b@physical id : 2@b@siblings : 1@b@core id : 0@b@cpu cores : 1@b@apicid : 2@b@initial apicid : 2@b@fpu : yes@b@fpu_exception : yes@b@cpuid level : 4@b@wp : yes@b@flags : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pse36 clflush mmx fxsr sse sse2 syscall nx lm unfair_spinlock pni cx16 hypervisor lahf_lm abm@b@bogomips : 6384.00@b@clflush size : 64@b@cache_alignment : 64@b@address sizes : 39 bits physical, 48 bits virtual@b@power management:@b@@b@[root@centos6 ~]# top@b@top - 19:50:06 up 79 days, 21:00, 1 user, load average: 1.00, 1.00, 1.00@b@Tasks: 273 total, 2 running, 271 sleeping, 0 stopped, 0 zombie@b@Cpu(s): 19.0%us, 1.5%sy, 0.0%ni, 78.3%id, 0.8%wa, 0.1%hi, 0.1%si, 0.3%st@b@Mem: 10016248k total, 9711172k used, 305076k free, 1513624k buffers@b@Swap: 3031036k total, 343412k used, 2687624k free, 4995860k cached@b@@b@ PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND @b@ 3007 root 20 0 304m 20m 4248 R 87.2 0.2 50991:07 metacity @b@ 1857 root 20 0 6468m 669m 66m S 1.7 6.8 205:19.55 java @b@ 4010 root 20 0 4424m 1.4g 6844 S 1.7 14.5 1523:15 java @b@32054 root 20 0 15160 1232 808 R 1.7 0.0 0:00.09 top @b@ 1 root 20 0 19356 1088 868 S 0.0 0.0 0:27.12 init @b@ 2 root 20 0 0 0 0 S 0.0 0.0 0:01.36 kthreadd @b@ 3 root RT 0 0 0 0 S 0.0 0.0 0:01.26 migration/0 @b@ 4 root 20 0 0 0 0 S 0.0 0.0 0:38.42 ksoftirqd/0 @b@ 5 root RT 0 0 0 0 S 0.0 0.0 0:00.00 stopper/0 @b@ 6 root RT 0 0 0 0 S 0.0 0.0 0:08.02 watchdog/0 @b@ 7 root RT 0 0 0 0 S 0.0 0.0 0:01.27 migration/1 @b@ 8 root RT 0 0 0 0 S 0.0 0.0 0:00.00 stopper/1 @b@ 9 root 20 0 0 0 0 S 0.0 0.0 1:17.54 ksoftirqd/1 @b@ 10 root RT 0 0 0 0 S 0.0 0.0 0:08.85 watchdog/1 @b@ 11 root RT 0 0 0 0 S 0.0 0.0 0:01.30 migration/2 @b@ 12 root RT 0 0 0 0 S 0.0 0.0 0:00.00 stopper/2 @b@ 13 root 20 0 0 0 0 S 0.0 0.0 0:29.10 ksoftirqd/2 @b@ 14 root RT 0 0 0 0 S 0.0 0.0 0:06.09 watchdog/2 @b@ 15 root 20 0 0 0 0 S 0.0 0.0 2:00.11 events/0 @b@ 16 root 20 0 0 0 0 S 0.0 0.0 3:47.08 events/1 @b@ 17 root 20 0 0 0 0 S 0.0 0.0 2:38.27 events/2 @b@ 18 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events/0 @b@ 19 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events/1 @b@ 20 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events/2 @b@ 21 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events_long/0 @b@ 22 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events_long/1 @b@ 23 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events_long/2 @b@ 24 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events_power_ef @b@ 25 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events_power_ef @b@ 26 root 20 0 0 0 0 S 0.0 0.0 0:00.00 events_power_ef @b@ 27 root 20 0 0 0 0 S 0.0 0.0 0:00.00 cgroup @b@ @b@[root@centos6 ~]# vmstat@b@procs -----------memory---------- ---swap-- -----io---- --system-- -----cpu-----@b@ r b swpd free buff cache si so bi bo in cs us sy id wa st@b@ 1 0 343412 303140 1513636 4995860 0 0 77 42 2 2 19 2 78 1 0@b@[root@centos6 ~]# sar -u@b@Linux 2.6.32-573.el6.x86_64 (centos6.7.s2) 2021年04月24日 _x86_64_ (3 CPU)@b@@b@00时00分01秒 CPU %user %nice %system %iowait %steal %idle@b@00时10分01秒 all 33.76 0.00 0.73 0.07 0.04 65.40@b@00时20分01秒 all 33.68 0.00 0.72 0.05 0.07 65.48@b@00时30分01秒 all 33.61 0.00 0.69 0.08 0.18 65.44@b@00时40分01秒 all 33.70 0.00 0.71 0.01 0.09 65.50@b@00时50分01秒 all 33.68 0.00 0.70 0.05 0.03 65.54@b@01时00分01秒 all 33.79 0.00 0.73 0.04 0.05 65.39@b@01时10分01秒 all 33.60 0.00 0.72 0.06 0.26 65.37@b@01时20分01秒 all 33.67 0.00 0.69 0.01 0.07 65.55@b@01时30分01秒 all 33.70 0.00 0.71 0.02 0.03 65.53@b@01时40分01秒 all 33.80 0.00 0.75 0.08 0.05 65.32@b@01时50分01秒 all 33.64 0.00 0.71 0.04 0.13 65.
3、内存
[root@centos6 ~]# free@b@ total used free shared buffers cached@b@Mem: 10016248 9731524 284724 631356 1514712 5012000@b@-/+ buffers/cache: 3204812 6811436 @b@Swap: 3031036 339452 2691584 @b@[root@centos6 ~]# cat /proc/meminfo@b@MemTotal: 10016248 kB@b@MemFree: 285096 kB@b@Buffers: 1514736 kB@b@Cached: 5012024 kB@b@SwapCached: 46668 kB@b@Active: 4757916 kB@b@Inactive: 4347864 kB@b@Active(anon): 2255232 kB@b@Inactive(anon): 957412 kB@b@Active(file): 2502684 kB@b@Inactive(file): 3390452 kB@b@Unevictable: 18916 kB@b@Mlocked: 8696 kB@b@SwapTotal: 3031036 kB@b@SwapFree: 2691584 kB@b@Dirty: 92 kB@b@Writeback: 0 kB@b@AnonPages: 2554236 kB@b@Mapped: 730048 kB@b@Shmem: 631356 kB@b@Slab: 406128 kB@b@SReclaimable: 309912 kB@b@SUnreclaim: 96216 kB@b@KernelStack: 9856 kB@b@PageTables: 86752 kB@b@NFS_Unstable: 0 kB@b@Bounce: 0 kB@b@WritebackTmp: 0 kB@b@CommitLimit: 8039160 kB@b@Committed_AS: 5420696 kB@b@VmallocTotal: 34359738367 kB@b@VmallocUsed: 42160 kB@b@VmallocChunk: 34359690416 kB@b@HardwareCorrupted: 0 kB@b@AnonHugePages: 1093632 kB@b@HugePages_Total: 0@b@HugePages_Free: 0@b@HugePages_Rsvd: 0@b@HugePages_Surp: 0@b@Hugepagesize: 2048 kB@b@DirectMap4k: 8180 kB@b@DirectMap2M: 10231808 kB@b@[root@centos6 ~]# vmstat -s@b@ 10016248 total memory@b@ 9731028 used memory@b@ 4757916 active memory@b@ 4347868 inactive memory@b@ 285220 free memory@b@ 1514740 buffer memory@b@ 5012024 swap cache@b@ 3031036 total swap@b@ 339452 used swap@b@ 2691584 free swap@b@ 390972846 non-nice user cpu ticks@b@ 17797 nice user cpu ticks@b@ 30657740 system cpu ticks@b@ 1609269318 idle cpu ticks@b@ 16799621 IO-wait cpu ticks@b@ 1763503 IRQ cpu ticks@b@ 1159679 softirq cpu ticks@b@ 5500783 stolen cpu ticks@b@ 1578468120 pages paged in@b@ 857590933 pages paged out@b@ 36962 pages swapped in@b@ 114439 pages swapped out@b@ 3940809011 interrupts@b@ 3311054395 CPU context switches@b@ 1612363802 boot time@b@ 669350 forks
4、网络
[root@centos6 ~]# netstat@b@Active Internet connections (w/o servers)@b@Proto Recv-Q Send-Q Local Address Foreign Address State @b@tcp 0 0 192.168.1.202:ncube-lm 192.168.1.202:59388 ESTABLISHED @b@tcp 0 0 192.168.1.202:ncube-lm 192.168.1.202:41539 ESTABLISHED @b@tcp 0 0 192.168.1.202:ncube-lm 192.168.1.202:35569 ESTABLISHED @b@tcp 0 0 192.168.1.202:ncube-lm 192.168.1.202:59405 ESTABLISHED @b@...@b@@b@[root@centos6 ~]# sar -n DEV@b@Linux 2.6.32-573.el6.x86_64 (centos6.7.s2) 2021年04月24日 _x86_64_ (3 CPU)@b@@b@00时00分01秒 IFACE rxpck/s txpck/s rxkB/s txkB/s rxcmp/s txcmp/s rxmcst/s@b@00时10分01秒 lo 1.55 1.55 0.09 0.09 0.00 0.00 0.00@b@00时10分01秒 eth0 78.60 206.47 5.22 304.80 0.00 0.00 0.00@b@00时10分01秒 virbr0 0.00 0.00 0.00 0.00 0.00 0.00 0.00@b@00时10分01秒 virbr0-nic 0.00 0.00 0.00 0.00 0.00 0.00 0.00@b@00时20分01秒 lo 1.55 1.55 0.09 0.09 0.00 0.00 0.00@b@00时20分01秒 eth0 20.35 51.14 1.82 75.11 0.00 0.00 0.00@b@00时20分01秒 virbr0 0.00 0.00 0.00 0.00 0.00 0.00 0.00@b@00时20分01秒 virbr0-nic 0.00 0.00 0.00 0.00 0.00 0.00 0.00@b@00时30分01秒 lo 1.55 1.55 0.09 0.09 0.00 0.00 0.00@b@00时30分01秒 eth0 1.62 0.36 0.56 0.03 0.00 0.00 0.00@b@00时30分01秒 virbr0 0.00 0.00 0.00 0.00 0.00 0.00 0.00@b@@b@...@b@[root@centos6 ~]# ethtool --version @b@ethtool version 3.5@b@@b@[root@centos6 ~]# traceroute 192.168.1.201@b@traceroute to 192.168.1.201 (192.168.1.201), 30 hops max, 60 byte packets^C@b@[root@centos6 ~]# traceroute 192.168.1.202@b@traceroute to 192.168.1.202 (192.168.1.202), 30 hops max, 60 byte packets@b@ 1 192.168.1.202 (192.168.1.202) 0.020 ms 0.006 ms 0.004 ms@b@[root@centos6 ~]# traceroute www.baidu.com@b@traceroute to www.baidu.com (182.61.200.6), 30 hops max, 60 byte packets@b@ 1 192.168.1.1 (192.168.1.1) 0.624 ms 1.008 ms 0.973 ms@b@ 2 115.173.172.1 (115.173.172.1) 4.588 ms 14.004 ms 13.980 ms@b@ 3 sjgmx-3.dev (10.64.131.18) 13.952 ms 10.64.131.6 (10.64.131.6) 13.908 ms sjgmx-3.dev (10.64.131.18) 13.878 ms@b@ 4 14.197.243.245 (14.197.243.245) 13.847 ms 13.667 ms 14.197.149.101 (14.197.149.101) 13.468 ms@b@ 5 14.197.244.145 (14.197.244.145) 13.440 ms 14.197.228.201 (14.197.228.201) 13.403 ms 14.197.241.149 (14.197.241.149) 13.373 ms@b@ 6 14.197.196.97 (14.197.196.97) 33.623 ms 14.197.221.33 (14.197.221.33) 29.365 ms 14.197.252.41 (14.197.252.41) 29.579 ms@b@ 7 14.197.252.54 (14.197.252.54) 29.463 ms 14.197.148.62 (14.197.148.62) 29.796 ms 14.197.252.50 (14.197.252.50) 31.210 ms@b@ 8 14.197.178.102 (14.197.178.102) 31.626 ms 14.197.249.122 (14.197.249.122) 31.137 ms 14.197.249.126 (14.197.249.126) 31.550 ms@b@ 9 182.61.255.2 (182.61.255.2) 30.005 ms 30.438 ms 182.61.255.28 (182.61.255.28) 29.786 ms@b@10 182.61.255.45 (182.61.255.45) 47.064 ms 47.226 ms 47.188 ms@b@11 * * *@b@12 * * *@b@13 * * *@b@14 * * *@b@15 * * *@b@16 * * *@b@17 * * *@b@18 * * *@b@19 * * *@b@20 * * *@b@21 * * *@b@22 * * *@b@23 * * *@b@24 * * *@b@25 * * *@b@26 * * *@b@27 * * *@b@28 * * *@b@29 * * *@b@30 * * *@b@@b@[root@centos6 ~]# tcpdump@b@tcpdump: verbose output suppressed, use -v or -vv for full protocol decode@b@listening on eth0, link-type EN10MB (Ethernet), capture size 65535 bytes@b@19:58:12.654761 IP 192.168.1.202.ssh > 192.168.1.144.61869: Flags [P.], seq 1790379653:1790379849, ack 3768747181, win 141, length 196@b@19:58:12.672379 IP 192.168.1.202.39823 > 192.168.1.1.domain: 8042+ PTR? 144.1.168.192.in-addr.arpa. (44)@b@19:58:12.674697 IP 192.168.1.1.domain > 192.168.1.202.39823: 8042 NXDomain* 0/1/0 (107)@b@19:58:12.674771 IP 192.168.1.202.54097 > 192.168.1.1.domain: 9688+ PTR? 202.1.168.192.in-addr.arpa. (44)@b@19:58:12.678777 IP 192.168.1.1.domain > 192.168.1.202.54097: 9688 NXDomain* 0/1/0 (99)@b@19:58:12.678884 IP 192.168.1.202.40792 > 192.168.1.1.domain: 44180+ PTR? 1.1.168.192.in-addr.arpa. (42)@b@19:58:12.679531 IP 192.168.1.202.ssh > 192.168.1.144.61869: Flags [P.], seq 196:376, ack 1, win 141, length 180@b@19:58:12.681674 IP 192.168.1.144.61869 > 192.168.1.202.ssh: Flags [.], ack 376, win 256, length 0@b@19:58:12.682493 IP 192.168.1.1.domain > 192.168.1.202.40792: 44180 NXDomain* 0/1/0 (105)@b@19:58:12.683548 IP 192.168.1.202.ssh > 192.168.1.144.61869: Flags [P.], seq 376:1212, ack 1, win 141, length 836@b@...
5、IO及磁盘
[root@centos6 ~]# df@b@Filesystem 1K-blocks Used Available Use% Mounted on@b@/dev/mapper/vg_centos6-lv_root@b@ 51475068 4146640 44706988 9% /@b@tmpfs 5008124 734708 4273416 15% /dev/shm@b@/dev/sda1 487652 42208 419844 10% /boot@b@/dev/mapper/vg_centos6-lv_home@b@ 460832816 28118276 409298940 7% /home@b@/dev/sdb 825567656 582341300 201283316 75% /data210202@b@@b@[root@centos6 aliyun]# du -sh /home/bak/aliyun@b@20K /home/bak/aliyun@b@[root@centos6 aliyun]# dd@b@^C记录了0+0 的读入@b@记录了0+0 的写出@b@0字节(0 B)已复制,14.2851 秒,0.0 kB/秒@b@@b@[root@centos6 aliyun]# sar -d@b@Linux 2.6.32-573.el6.x86_64 (centos6.7.s2) 2021年04月24日 _x86_64_ (3 CPU)@b@@b@00时00分01秒 DEV tps rd_sec/s wr_sec/s avgrq-sz avgqu-sz await svctm %util@b@00时10分01秒 dev8-16 0.12 29.34 0.00 250.40 0.00 13.20 10.07 0.12@b@00时10分01秒 dev8-0 3.65 0.51 51.23 14.16 0.00 1.06 0.86 0.31@b@00时10分01秒 dev253-0 0.61 0.13 4.83 8.09 0.00 2.45 1.10 0.07@b@00时10分01秒 dev253-1 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00@b@00时10分01秒 dev253-2 7.04 0.37 46.39 6.64 0.01 1.91 0.35 0.25@b@00时20分01秒 dev8-16 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00
6、句柄
[root@centos6 aliyun]# lsof -p@b@lsof: no process ID specified@b@lsof 4.82@b@ latest revision: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/@b@ latest FAQ: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/FAQ@b@ latest man page: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_man@b@ usage: [-?abhlnNoOPRtUvVX] [+|-c c] [+|-d s] [+D D] [+|-f[gG]] [+|-e s]@b@ [-F [f]] [-g [s]] [-i [i]] [+|-L [l]] [+m [m]] [+|-M] [-o [o]] [-p s]@b@[+|-r [t]] [-s [p:s]] [-S [t]] [-T [t]] [-u s] [+|-w] [-x [fl]] [-Z [Z]] [--] [names]@b@Use the ''-h'' option to get more help information.@b@[root@centos6 aliyun]# @b@[root@centos6 aliyun]# @b@[root@centos6 aliyun]# @b@[root@centos6 aliyun]# ulimit -a@b@core file size (blocks, -c) 0@b@data seg size (kbytes, -d) unlimited@b@scheduling priority (-e) 0@b@file size (blocks, -f) unlimited@b@pending signals (-i) 39005@b@max locked memory (kbytes, -l) 64@b@max memory size (kbytes, -m) unlimited@b@open files (-n) 1024@b@pipe size (512 bytes, -p) 8@b@POSIX message queues (bytes, -q) 819200@b@real-time priority (-r) 0@b@stack size (kbytes, -s) 10240@b@cpu time (seconds, -t) unlimited@b@max user processes (-u) 39005@b@virtual memory (kbytes, -v) unlimited@b@file locks (-x) unlimited@b@[root@centos6 aliyun]# cat /etc/security/limits.conf @b@# /etc/security/limits.conf@b@#@b@#Each line describes a limit for a user in the form:@b@#@b@#<domain> <type> <item> <value>@b@#@b@#Where:@b@#<domain> can be:@b@# - a user name@b@# - a group name, with @group syntax@b@# - the wildcard *, for default entry@b@# - the wildcard %, can be also used with %group syntax,@b@# for maxlogin limit@b@#@b@#<type> can have the two values:@b@# - "soft" for enforcing the soft limits@b@# - "hard" for enforcing hard limits@b@#@b@#<item> can be one of the following:@b@# - core - limits the core file size (KB)@b@# - data - max data size (KB)@b@# - fsize - maximum filesize (KB)@b@# - memlock - max locked-in-memory address space (KB)@b@# - nofile - max number of open file descriptors@b@# - rss - max resident set size (KB)@b@# - stack - max stack size (KB)@b@# - cpu - max CPU time (MIN)@b@# - nproc - max number of processes@b@# - as - address space limit (KB)@b@# - maxlogins - max number of logins for this user@b@# - maxsyslogins - max number of logins on the system@b@# - priority - the priority to run user process with@b@# - locks - max number of file locks the user can hold@b@# - sigpending - max number of pending signals@b@# - msgqueue - max memory used by POSIX message queues (bytes)@b@# - nice - max nice priority allowed to raise to values: [-20, 19]@b@# - rtprio - max realtime priority@b@#@b@#<domain> <type> <item> <value>@b@#@b@@b@#* soft core 0@b@#* hard rss 10000@b@#@student hard nproc 20@b@#@faculty soft nproc 20@b@#@faculty hard nproc 50@b@#ftp hard nproc 0@b@#@student - maxlogins 4@b@@b@# End of file@b@@b@[root@centos6 aliyun]# ls /proc/4010/fdinfo|wc -l@b@239
7、其他
[root@centos6 aliyun]# hostname@b@centos6.7.s2@b@[root@centos6 aliyun]# cat /etc/passwd@b@root:x:0:0:root:/root:/bin/bash@b@bin:x:1:1:bin:/bin:/sbin/nologin@b@daemon:x:2:2:daemon:/sbin:/sbin/nologin@b@adm:x:3:4:adm:/var/adm:/sbin/nologin@b@lp:x:4:7:lp:/var/spool/lpd:/sbin/nologin@b@sync:x:5:0:sync:/sbin:/bin/sync@b@shutdown:x:6:0:shutdown:/sbin:/sbin/shutdown@b@halt:x:7:0:halt:/sbin:/sbin/halt@b@mail:x:8:12:mail:/var/spool/mail:/sbin/nologin@b@uucp:x:10:14:uucp:/var/spool/uucp:/sbin/nologin@b@operator:x:11:0:operator:/root:/sbin/nologin@b@games:x:12:100:games:/usr/games:/sbin/nologin@b@gopher:x:13:30:gopher:/var/gopher:/sbin/nologin@b@ftp:x:14:50:FTP User:/var/ftp:/sbin/nologin@b@nobody:x:99:99:Nobody:/:/sbin/nologin@b@dbus:x:81:81:System message bus:/:/sbin/nologin@b@usbmuxd:x:113:113:usbmuxd user:/:/sbin/nologin@b@vcsa:x:69:69:virtual console memory owner:/dev:/sbin/nologin@b@rpc:x:32:32:Rpcbind Daemon:/var/cache/rpcbind:/sbin/nologin@b@rtkit:x:499:497:RealtimeKit:/proc:/sbin/nologin@b@avahi-autoipd:x:170:170:Avahi IPv4LL Stack:/var/lib/avahi-autoipd:/sbin/nologin@b@abrt:x:173:173::/etc/abrt:/sbin/nologin@b@rpcuser:x:29:29:RPC Service User:/var/lib/nfs:/sbin/nologin@b@nfsnobody:x:65534:65534:Anonymous NFS User:/var/lib/nfs:/sbin/nologin@b@haldaemon:x:68:68:HAL daemon:/:/sbin/nologin@b@gdm:x:42:42::/var/lib/gdm:/sbin/nologin@b@ntp:x:38:38::/etc/ntp:/sbin/nologin@b@apache:x:48:48:Apache:/var/www:/sbin/nologin@b@saslauth:x:498:76:Saslauthd user:/var/empty/saslauth:/sbin/nologin@b@postfix:x:89:89::/var/spool/postfix:/sbin/nologin@b@pulse:x:497:496:PulseAudio System Daemon:/var/run/pulse:/sbin/nologin@b@sshd:x:74:74:Privilege-separated SSH:/var/empty/sshd:/sbin/nologin@b@tcpdump:x:72:72::/:/sbin/nologin@b@oracle:x:500:501::/home/oracle:/bin/bash@b@sanlock:x:179:179:sanlock:/var/run/sanlock:/sbin/nologin@b@radvd:x:75:75:radvd user:/:/sbin/nologin@b@qemu:x:107:107:qemu user:/:/sbin/nologin@b@[root@centos6 aliyun]# date@b@2021年 04月 24日 星期六 20:16:49 CST