Linux信息查看

查看有几个插口用了几个插口

1
2
3
4
5
6
7
8
9
# dmidecode -t memory |grep Size
Size: 1024 MB
Size: 1024 MB
Size: 1024 MB
Size: 1024 MB
Size: No Module Installed
Size: No Module Installed
Size: No Module Installed
Size: No Module Installed

查看服务器多少位

1
2
3
4
# getconf LONG_BIT
32
# uname -a
Linux longyuan 2.6.18-8.10AX #1 SMP Tue Aug 14 04:52:14 EDT 2007 i686 i686 i386 GNU/Linux

查看Linux内核版本的命令

1
2
3
4
5
# uname -a
Linux xxcloud 2.6.32-71.el6.x86_64 #1 SMP Fri May 20 03:51:51 BST 2011 x86_64 x86_64 x86_64 GNU/Linux

# cat /proc/version
Linux version 2.6.32-71.el6.x86_64 (mockbuild@c6b6.centos.org) (gcc version 4.4.4 20100726 (Red Hat 4.4.4-13) (GCC) ) #1 SMP Fri May 20 03:51:51 BST 2011

*linux 下怎样启用PAE(让32位支持4G以上内存)

1
2
3
   # cat /boot/config-*|grep PAE
   # Linux kernel version: 2.6.18-8.10AXPAE
   CONFIG_X86_PAE=y

查看是什么linux

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
[root@wocloud .ssh]# cat /etc/redhat-release
CentOS release 6.3 (Final)

[root@wocloud ~]# cat /etc/issue 
CentOS release 6.3 (Final)
Kernel \r on an \m

[cgg@longyuan ~]$ cat /etc/issue
Asianux Server 3 (Quartet)
Kernel \r on an \m

john@li388-108:~$ cat /etc/issue
Ubuntu 10.10 \n \l

MyBookLive:~# cat /etc/issue
Debian GNU/Linux 5.0 \n \l

看内存情况

1
2
3
4
5
john@localhost:~$ free -m
             total       used       free     shared    buffers     cached
Mem:           496        464         31          0        126        197
-/+ buffers/cache:        140        356
Swap:          255          0        255
原文地址:http://dlj.bz/R1zcWY

Comments