易截截图软件、单文件、免安装、纯绿色、仅160KB

Linux查看系统配置常用命令

系统
# uname -a               # 查看内核/操作系统/CPU信息
# head -n 1 /etc/issue   # 查看操作系统
版本
# cat /proc/cpuinfo      # 查看CPU信息
# hostname               # 查看计算机名
# lspci -tv              # 列出所有PCI设备
# lsusb -tv              # 列出所有USB设备
# lsmod                  # 列出加载的内核模块
# env                    # 查看环境变量
资源
# free -m                # 查看内存使用量和交换区使用量
# df -h                  # 查看各分区使用情况
# du -sh <目录名>        # 查看指定目录的大小
# grep MemTotal /proc/meminfo   # 查看内存总量
# grep MemFree /proc/meminfo    # 查看空闲内存量
# uptime                 # 查看系统运行时间、用户数、负载
# cat /proc/loadavg      # 查看系统负载
磁盘和分区
# mount | column -t      # 查看挂接的分区状态
# fdisk -l               # 查看所有分区
# swapon -s              # 查看所有交换分区
# hdparm -i /dev/hda     # 查看磁盘参数(仅适用于IDE设备)
# dmesg | grep IDE       # 查看启动时IDE设备检测状况


相关文档:

Linux kernel Development second Edition

1. Technically speaking, and in this book, the operating
system
is considered the parts of the system responsible for basic use
and administration. This includes the kernel and device drivers, boot loader,
command shell or other user interface, and basic file and system utilities ......

Linux的initcalls调用机制

只要看看 include/linux/init.h中的定义就清楚了:
#define core_initcall(fn)        __define_initcall("1",fn)
#define postcore_initcall(fn)        __define_initcall("2",fn)
#define arch_initcall(fn)     &n ......

LINUX进程管理

1. 进程是什么?
一个进程就是出于执行期的程序, 包括:可执行程序代码(代码段), 打开的文件, 挂起的信号, 内核内部数据, 处理器状态, 地址空间, 一个或多个执行线程, 当然还包括用来存放全局变量的数据段, 等等.
 
2. 什么是线程?它和进程的关系是什么样的? 线程在LINUX中具体是怎么样实现的?
是在进程中活动的对象 ......

linux中的块设备和字符设备

      系统中能够随机(不需要按顺序)访问固定大小数据片(chunks)的设备被称作块设备,这些数据片就称作块。最常见的块设备是硬盘,除此以外,还有软盘驱动器、CD-ROM驱动器和闪存等等许多其他块设备。注意,它们都是以安装文件系统的方式使用的——这也是块设备一般的访问方式。
& ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号