全部版块 我的主页
论坛 提问 悬赏 求职 新闻 读书 功能一区 学习笔记1.0
1018 1
2011-04-05
SYSTEMHardware | Statistics | Users | Limits | Runlevels | root password | Compile kernel | Repair grub
Running kernel and system information# uname -a # Get the kernel version (and BSD version) # lsb_release -a # Full release info of any LSB distribution # cat /etc/SuSE-release # Get SuSE version # cat /etc/debian_version # Get Debian version
Use /etc/DISTR-release with DISTR= lsb (Ubuntu), redhat, gentoo, mandrake, sun (Solaris), and so on. See also /etc/issue.

# uptime
# Show how long the system has been running + load

# hostname
# system's host name

# hostname -i
# Display the IP address of the host. (Linux only)

# man hier
# Description of the file system hierarchy

# last reboot
# Show system reboot history

Hardware Informations
Kernel detected hardware

# dmesg
# Detected hardware and boot messages

# lsdev
# information about installed hardware

# dd if=/dev/mem bs=1k skip=768 count=256 2>/dev/null | strings -n 8 # Read BIOS
Linux
# cat /proc/cpuinfo
# CPU model

# cat /proc/meminfo
# Hardware memory

# grep MemTotal /proc/meminfo
# Display the physical memory

# watch -n1 'cat /proc/interrupts'
# Watch changeable interrupts continuously

# free -m
# Used and free memory (-m for MB)

# cat /proc/devices
# Configured devices

# lspci -tv
# Show PCI devices

# lsusb -tv
# Show USB devices

# lshal

# Show a list of all devices with their properties

# dmidecode
# Show DMI/SMBIOS: hw info from the BIOS

FreeBSD
# sysctl hw.model
# CPU model

# sysctl hw
# Gives a lot of hardware information

# sysctl hw.ncpu
# number of active CPUs installed

# sysctl vm
# Memory usage

# sysctl hw.realmem
# Hardware memory

# sysctl -a | grep mem
# Kernel memory settings and info

# sysctl dev
# Configured devices

# pciconf -l -cv
# Show PCI devices

# usbdevs -v
# Show USB devices

# atacontrol list
# Show ATA devices

# camcontrol devlist -v
# Show SCSI devices
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

全部回复
2011-4-5 00:19:48
Load, statistics and messagesThe following commands are useful to find out what is going on on the system.# top                                # display and update the top cpu processes
# mpstat 1                           # display processors related statistics
# vmstat 2                           # display virtual memory statistics
# iostat 2                           # display I/O statistics (2 s intervals)
# systat -vmstat 1                   # BSD summary of system statistics (1 s intervals)
# systat -tcp 1                      # BSD tcp connections (try also -ip)
# systat -netstat 1                  # BSD active network connections
# systat -ifstat 1                   # BSD network traffic through active interfaces
# systat -iostat 1                   # BSD CPU and and disk throughput
# tail -n 500 /var/log/messages      # Last 500 kernel/syslog messages
# tail /var/log/warn                 # System warnings messages see syslog.conf
二维码

扫码加我 拉你入群

请注明:姓名-公司-职位

以便审核进群资格,未注明则拒绝

相关推荐
栏目导航
热门文章
推荐文章

说点什么

分享

扫码加好友,拉您进群
各岗位、行业、专业交流群