Menu Close

Oracle Database Appliance X6-2M硬件配置

1. 硬件环境

1.1. 硬件图片

1.2. 操作系统

机器型号:ODA X6-2M
操作系统版本:Oracle Linux Server release 6.8
备注:Oracle Database Appliance(ODA) X6-2M

2. 服务器硬件配置简介

DMI (Desktop Management Interface, DMI)就是帮助收集电脑系统信息的管理系统,DMI信息的收集必须在严格遵照SMBIOS规范的前提下进行。 SMBIOS(System Management BIOS)是主板或系统制造者以标准格式显示产品管理信息所需遵循的统一规范。SMBIOSDMI是由行业指导机构Desktop Management Task Force (DMTF)起草的开放性的技术标准,其中DMI设计适用于任何的平台和操作系统。DMI充当了管理工具和系统层之间接口的角色。它建立了标准的可管理系统更加方便了电脑厂商和用户对系统的了解。DMI的主要组成部分是Management Information Format (MIF)数据库。这个数据库包括了所有有关电脑系统和配件的信息。通过DMI,用户可以获取序列号、电脑厂商、串口信息以及其它系统配件信息。

Usage: dmidecode [OPTIONS]
Options are:
-d, --dev-mem FILE Read memory from device FILE (default: /dev/mem)
#从设备文件读信息,输出内容与不加参数标准输出相同
-h, --help Display this help text and exit
#显示帮助信息
-q, --quiet Less verbose output
#显示更少的简化信息
-s, --string KEYWORD Only display the value of the given DMI string
#只显示指定DMI字符串的信息
-t, --type TYPE Only display the entries of given type
#只显示指定条目的信息
-u, --dump Do not decode the entries
#显示未解码的原始条目内容
--dump-bin FILE Dump the DMI data to a binary file
--from-dump FILE Read the DMI data from a binary file
-V, --version Display the version and exit
#显示版本信息
~]# dmidecode -t system          //查看服务器相关信息, 或者用命令:dmidecode --type system
~]# dmidecode -t processor      //查看处理器信息,或者用命令:dmidecode --type processor
~]# dmidecode -t memory         //查看内存信息
~]# dmidecode -t bios           //查看BIOS器信息

3. 与服务器型号相关的参数

3.1. 查看服务器型号

~]#  dmidecode | grep "Product Name"

3.2. 查看服务器制造商、型号、序列号

~]# dmidecode|grep "System Information" -A9|egrep  "Manufacturer|Product|Serial"

3.3. 查看服务器主板型号

~]# dmidecode |grep -A16 "System Information$"

4. 与内存相关的参数

4.1. 查看内存概要信息

~]# dmidecode -t 16     //简单好记

该服务器应该有两组内存插槽,每组12个插槽,最大支持768G内存。

4.2. 查看内存型号

~]# dmidecode |grep -A16 "Memory Device$"

该内存条为三星制造,频率为2400MHz,类型为DDR4,单条内存大小为32G

4.3. 查看内存插槽数

~]# dmidecode|grep -A5 "Memory Device"|grep Size|grep -v Range

该服务器共有24个内存插槽,现使用8个插槽,每插槽内存大小为32G,合计共计8*32=256GB

5. 与CPU相关的参数

5.1. 查看CPU概要信息

~]# dmidecode -t 4             //简单好记

显示的信息如下:

# dmidecode 2.12
SMBIOS 2.8 present.

Handle 0x005C, DMI type 4, 42 bytes
Processor Information
    Socket Designation: P0
    Type: Central Processor
    Family: Xeon
    Manufacturer: Intel
    ID: F1 06 04 00 FF FB EB BF
    Signature: Type 0, Family 6, Model 79, Stepping 1
    Flags:
        FPU (Floating-point unit on-chip)
        VME (Virtual mode extension)
        DE (Debugging extension)
        PSE (Page size extension)
        TSC (Time stamp counter)
        MSR (Model specific registers)
        PAE (Physical address extension)
        MCE (Machine check exception)
        CX8 (CMPXCHG8 instruction supported)
        APIC (On-chip APIC hardware supported)
        SEP (Fast system call)
        MTRR (Memory type range registers)
        PGE (Page global enable)
        MCA (Machine check architecture)
        CMOV (Conditional move instruction supported)
        PAT (Page attribute table)
        PSE-36 (36-bit page size extension)
        CLFSH (CLFLUSH instruction supported)
        DS (Debug store)
        ACPI (ACPI supported)
        MMX (MMX technology supported)
        FXSR (FXSAVE and FXSTOR instructions supported)
        SSE (Streaming SIMD extensions)
        SSE2 (Streaming SIMD extensions 2)
        SS (Self-snoop)
        HTT (Multi-threading)
        TM (Thermal monitor supported)
        PBE (Pending break enabled)
    Version: Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz
    Voltage: 1.8 V
    External Clock: 100 MHz
    Max Speed: 4000 MHz
    Current Speed: 2200 MHz
    Status: Populated, Enabled
    Upgrade: Socket LGA2011-3
    L1 Cache Handle: 0x0059
    L2 Cache Handle: 0x005A
    L3 Cache Handle: 0x005B
    Serial Number: Not Specified
    Asset Tag: Not Specified
    Part Number: 060F
    Core Count: 10
    Core Enabled: 10
    Thread Count: 20
    Characteristics:
        64-bit capable
        Multi-Core
        Hardware Thread
        Execute Protection
        Enhanced Virtualization
        Power/Performance Control

Handle 0x0060, DMI type 4, 42 bytes
Processor Information
    Socket Designation: P1
    Type: Central Processor
    Family: Xeon
    Manufacturer: Intel
    ID: F1 06 04 00 FF FB EB BF
    Signature: Type 0, Family 6, Model 79, Stepping 1
    Flags:
        FPU (Floating-point unit on-chip)
        VME (Virtual mode extension)
        DE (Debugging extension)
        PSE (Page size extension)
        TSC (Time stamp counter)
        MSR (Model specific registers)
        PAE (Physical address extension)
        MCE (Machine check exception)
        CX8 (CMPXCHG8 instruction supported)
        APIC (On-chip APIC hardware supported)
        SEP (Fast system call)
        MTRR (Memory type range registers)
        PGE (Page global enable)
        MCA (Machine check architecture)
        CMOV (Conditional move instruction supported)
        PAT (Page attribute table)
        PSE-36 (36-bit page size extension)
        CLFSH (CLFLUSH instruction supported)
        DS (Debug store)
        ACPI (ACPI supported)
        MMX (MMX technology supported)
        FXSR (FXSAVE and FXSTOR instructions supported)
        SSE (Streaming SIMD extensions)
        SSE2 (Streaming SIMD extensions 2)
        SS (Self-snoop)
        HTT (Multi-threading)
        TM (Thermal monitor supported)
        PBE (Pending break enabled)
    Version: Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz
    Voltage: 1.8 V
    External Clock: 100 MHz
    Max Speed: 4000 MHz
    Current Speed: 2200 MHz
    Status: Populated, Enabled
    Upgrade: Socket LGA2011-3
    L1 Cache Handle: 0x005D
    L2 Cache Handle: 0x005E
    L3 Cache Handle: 0x005F
    Serial Number: Not Specified
    Asset Tag: Not Specified
    Part Number: 060F
    Core Count: 10
    Core Enabled: 10
    Thread Count: 20
    Characteristics:
        64-bit capable
        Multi-Core
        Hardware Thread
        Execute Protection
        Enhanced Virtualization
        Power/Performance Control

CPU信息:主要查看 /proc/cpuinfo 文件

 总核数 = 物理CPU个数 X 每颗物理CPU的核数
 总逻辑CPU数 = 物理CPU个数 X 每颗物理CPU的核数 X 超线程数

超线程技术就是利用特殊的硬件指令,把两个逻辑内核模拟成两个物理芯片,让单个处理器都能使用线程级并行计算,进而兼容多线程操作系统和软件,减少了CPU的闲置时间,提高的CPU的运行效率。
超线程技术是在一颗CPU同时执行多个程序而共同分享一颗CPU内的资源,理论上要像两颗CPU一样在同一时间执行两个线程,虽然采用超线程技术能同时执行两个线程,但它并不象两个真正的CPU那样,每个CPU都具有独立的资源。当两个线程都同时需要某一个资源时,其中一个要暂时停止,并让出资源,直到这些资源闲置后才能继续。因此超线程的性能并不等于两颗CPU的性能。

判断超线程是否打开:如果有两个逻辑CPU具有相同的”core id”,那么超线程是打开的。

5.2. 查看CPU型号

~]# dmidecode -s processor-version
OR:
~]# cat /proc/cpuinfo | grep name | cut -f2 -d: | uniq -c


说明:该服务器有40个逻辑CPU,CPU型号为Intel® Xeon® E5-2630 V4,主频为2.20GHz

5.3. 查看物理CPU个数

~]# cat /proc/cpuinfo| grep "physical id"| sort| uniq| wc -l

5.4. 查看每个物理CPU中core的个数(即核数)

~]# cat /proc/cpuinfo| grep "cpu cores"| uniq

5.5. 查看逻辑CPU的个数

~]# cat /proc/cpuinfo| grep "processor"| wc -l

5.6. 查看CPU是否启用超线程

~]# cat /proc/cpuinfo | grep 'physical id' | uniq -c

~]# cat /proc/cpuinfo | grep -e  "cpu cores"  -e "siblings" | sort | uniq

NOTE:siblings区别出了超线程CPU中的逻辑CPU核心。一颗超线程CPU,其physical id是一样的,但是siblings是不同的。

5.7. 查看当前CPU运行模式是32位还是64位

~]#  getconf LONG_BIT

6. 与硬盘相关的参数

6.1. 查看硬盘相关的参数

~]# cat /proc/scsi/scsi


对于使用了LSI MegaRAID卡搭建RAID的, 通过LSI公司提供的MegaCli工具, 就可以实现对RAID卡和硬盘的监控。
注: DELL PERC5/6(PowerEdge RAID ControllerPERC)阵列卡实际上也就是LSI MegaRAID SAS controllers.
NOTE:ODA默认已经安装了。

~]# rpm -ivh Lib_Utils-1.00-09.noarch.rpm
~]# rpm -ivh MegaCli-8.02.21-1.noarch.rpm   //安装MegaCli工具

6.2. 查看所有逻辑磁盘组信息

~]#  /opt/MegaRAID/MegaCli/MegaCli64 -LDInfo -Lall -aALL

RAID级别如何查看?? RAID型号对应表信息如下:

['Primary-0, Secondary-0, RAID Level Qualifier-0'] = RAID-0
['Primary-1, Secondary-0, RAID Level Qualifier-0'] = RAID-1
['Primary-5, Secondary-0, RAID Level Qualifier-3'] = RAID-5
['Primary-6, Secondary-0, RAID Level Qualifier-3'] = RAID-6
['Primary-1, Secondary-3, RAID Level Qualifier-0'] = RAID-10
  • State : Optimal //这是正常的状态。
  • Strip Size : 1.0MB
  • Number Of Drives per span:2 //表示每2个物理盘做成一个RAID1盘组
  • Span Depth : 1 //深度若是1,说明实际只是RAID 1。2表示可以是RAID 10

6.3. 查看Raid卡型号,Raid设置,Disk相关信息

~]# /opt/MegaRAID/MegaCli/MegaCli64  -cfgdsply -aAll

6.4. 查看RAID卡信息

~]#  /opt/MegaRAID/MegaCli/MegaCli64 -ADPallInfo -aALL

6.5. 查看RAID中的硬盘信息

~]#  /opt/MegaRAID/MegaCli/MegaCli64 -pdlist -aALL

以下是显示信息:

Adapter #0

Enclosure Device ID: 252
Slot Number: 0
Drive's position: DiskGroup: 0, Span: 0, Arm: 0
Enclosure position: N/A
Device Id: 8
WWN: 5002538c40304fa1
Sequence Number: 2
Media Error Count: 0
Other Error Count: 0
Predictive Failure Count: 0
Last Predictive Failure Event Seq Number: 0
PD Type: SATA

Raw Size: 447.130 GB [0x37e436b0 Sectors]
Non Coerced Size: 446.630 GB [0x37d436b0 Sectors]
Coerced Size: 446.102 GB [0x37c34800 Sectors]
Sector Size:  512
Logical Sector Size:  512
Physical Sector Size:  512
Firmware state: Online, Spun Up
Commissioned Spare : No
Emergency Spare : No
Device Firmware Level: 0R3Q
Shield Counter: 0
Successful diagnostics completion on :  N/A
SAS Address(0): 0x4433221100000000
Connected Port Number: 0(path0)
Inquiry Data: S2UBNX0H600389      MS4SC2JH2ORA480G                        GXM10R3Q
FDE Capable: Not Capable
FDE Enable: Disable
Secured: Unsecured
Locked: Unlocked
Needs EKM Attention: No
Foreign State: None
Device Speed: 6.0Gb/s
Link Speed: 6.0Gb/s
Media Type: Solid State Device
Drive:  Not Certified
Drive Temperature :34C (93.20 F)
PI Eligibility:  No
Drive is formatted for PI information:  No
PI: No PI
Port-0 :
Port status: Active
Port's Linkspeed: 6.0Gb/s
Drive has flagged a S.M.A.R.T alert : No

Enclosure Device ID: 252
Slot Number: 1
Drive's position: DiskGroup: 0, Span: 0, Arm: 1
Enclosure position: N/A
Device Id: 9
WWN: 5002538c40304fa2
Sequence Number: 2
Media Error Count: 0
Other Error Count: 0
Predictive Failure Count: 0
Last Predictive Failure Event Seq Number: 0
PD Type: SATA

Raw Size: 447.130 GB [0x37e436b0 Sectors]
Non Coerced Size: 446.630 GB [0x37d436b0 Sectors]
Coerced Size: 446.102 GB [0x37c34800 Sectors]
Sector Size:  512
Logical Sector Size:  512
Physical Sector Size:  512
Firmware state: Online, Spun Up
Commissioned Spare : No
Emergency Spare : No
Device Firmware Level: 0R3Q
Shield Counter: 0
Successful diagnostics completion on :  N/A
SAS Address(0): 0x4433221101000000
Connected Port Number: 1(path0) 
Inquiry Data: S2UBNX0H600390      MS4SC2JH2ORA480G                        GXM10R3Q
FDE Capable: Not Capable
FDE Enable: Disable
Secured: Unsecured
Locked: Unlocked
Needs EKM Attention: No
Foreign State: None
Device Speed: 6.0Gb/s
Link Speed: 6.0Gb/s
Media Type: Solid State Device
Drive:  Not Certified
Drive Temperature :35C (95.00 F)
PI Eligibility:  No
Drive is formatted for PI information:  No
PI: No PI
Port-0 :
Port status: Active
Port's Linkspeed: 6.0Gb/s
Drive has flagged a S.M.A.R.T alert : No

Exit Code: 0x00

6.6. 查看硬盘及分区

~]# lsblk

6.7. 查看各分区使用情况

~]# df -lhT

ASM集群文件系统ACFS(ASM Cluster File System)
http://blog.csdn.net/laoshangxyc/article/details/12645889
http://www.cnblogs.com/riskyer/archive/2013/08/18/3266515.html
http://www.kgc.cn/bbs/post/30858.shtml
http://blog.chinaunix.net/uid-20785090-id-4047193.html
http://www.oracle.com/technetwork/cn/database/database-technologies/cloud-storage/index.html 官网

~]# time dd if=/dev/zero of=/data/test bs=8k count=1000000  //测试磁盘纯写速度

~]# time dd if=/data/test of=/dev/null bs=8k count=1000000    //测试磁盘纯读速度

~]# hdparm -tT /dev/sda1               //使用hdparm命令测试磁盘读写速度

7. 与网卡相关的参数

7.1. 查看网卡型号

~]# lspci | grep Eth

~]# dmesg | grep -i eth

7.2. Linux bonding

Linux bonding驱动提供了一种方法,用以把多个网络接口(network interface)组合成一个逻辑的"bonded"接口。Bonded接口的工作方式取决于驱动的模式:不同的模式提供了热备份或负载均衡等不同的服务。此外,驱动还会监控链路的可用性。
Bonding驱动最早来自Donald Becker针对Linux 2.0内核的beowulf补丁。现在已经有了很多的变化,最早的来自beowulf网站的工具已经不能和现在的驱动一起使用。
查看网口绑定情况

~]# cat /proc/net/bonding/btbond1

切换主网卡

~]# ifenslave -c btbond1 em2

7.3. Ethtool 工具

ethtool 是用于查询及设置网卡参数的命令。
使用概要:

ethtool ethx //查询ethx网口基本设置,其中 x 是对应网卡的编号,如eth0、eth1等等 
ethtool –h //显示ethtool的命令帮助(help) 
ethtool –i ethX //查询ethX网口的相关信息 
ethtool –d ethX //查询ethX网口注册性信息 
ethtool –r ethX //重置ethX网口到自适应模式 
ethtool –S ethX //查询ethX网口收发包统计 
ethtool –s ethX [speed 10|100|1000] [duplex half|full] [autoneg on|off] //设置网口速率10/100/1000M、设置网口半/全双工、设置网口是否自协商
[root@linux /]# ethtool eth1 //查看网卡1信息
[root@linux /]# ethtool -i eth1 //查看网卡型号等 
[root@linux /]# ethtool -S eth1 //查看数据率等
[root@linux /]# ethtool -s eth1 autoneg off speed 100 duplex full//强制修改网卡速率,配置成百兆网卡,autoneg off是一定要用,如果是on的话就是自适应配置,自动根据机器等进行配置。

示例:

~]# ethtool em1

7.4. mii-tool工具

mii-tool 在更改网络设备通信协商方式的方法比较简单,用 -v 参数来查看网络接口的状态;看下面的例子;
mii-tool 更改网络接口协商的方法;

~]# mii-tool --help
usage: mii-tool [-VvRrwl] [-A media,... | -F media] [interface ...]
-V, --version display version information 
-v, --verbose more verbose output 注:显示网络接口的信息; 
-R, --reset reset MII to poweron state 注:重设MII到开启状态; 
-r, --restart restart autonegotiation 注:重启自动协商模式; 
-w, --watch monitor for link status changes 注:查看网络接口连接的状态变化; 
-l, --log with -w, write events to syslog 注:写入事件到系统日志; 
-A, --advertise=media,... advertise only specified media 注:指令特定的网络接口; 
-F, --force=media force specified media technology 注:更改网络接口协商方式; 
media: 100baseT4, 100baseTx-FD, 100baseTx-HD, 10baseT-FD, 10baseT-HD, 
(to advertise both HD and FD) 100baseTx, 10baseT
更改网络接口的协商方式,我们要用到-F选项,后面可以接 100baseT4, 100baseTx-FD, 100baseTx-HD, 10baseT-FD, 10baseT-HD等参数;

如果我们想把网络接口eth0改为 1000Mb/s全双工的模式应该怎么办呢?

~]# mii-tool -F 100baseTx-FD
~]#mii-tool -v eth0

7.5. 网卡的负载测试工具

Tcpdump 工具