目 录
一、检查状态及性能 ....................................................................................................................... 1
1.1、概述 .................................................................................................................................. 1 1.2、几个有用的管理命令 .................................................................................................... 13 1.3、使用statit命令 .............................................................................................................. 15 1.4、执行特殊的BOOT命令 ............................................................................................... 17 二、检查状态及性能管理 ............................................................................................................. 25
2.1、检查系统 ........................................................................................................................ 25
2.1.1、sysconfig ............................................................................................................. 25 2.1.2、sysstat .................................................................................................................. 28 2.1.3、与优化CPU性能的options命令 ..................................................................... 28
一、检查状态及性能
1.1、概述
识别管理权限命令(priv admin) 解释管理权限命令的功能
定义一些对于管理员非常有用的普通命令 普通权限的管理命令用于日常管理
高级权限的管理命令用于特殊任务,比如系统调优、测试、统计等。这种命令如果使用不当可能毁坏数据,所以推荐别在高级权限模式长时间停留。 Options类的命令
Flash启动命令在设备启动阶段可以获得
命令行提供4种类型的命令用于基本的系统管理或者排错。
普通权限的命令在命令行打问号可以获得提示,主要是为了磁盘管理、网络和系统管理、物理或者虚拟接口管理等。下面是一系列普通权限的命令: Configuration类—黄色的是这一类命令
一些命令解释(software、source):
tan> softwar命令用于从HTTP或HTTPS服务器下载DataONTAP软件镜像到filer,管理软件并安装或升级它们,一般是SETUP.EXE(NETAPP发布的)文件,软件下载后保存在根卷的/etc/software。 tan> arp –a ====将IP地址解析成MAC地址 (192.168.0.1) at (incomplete) tan> arp -n tan tan (192.168.0.105) -- no entry tan> source -v /etc/rc =读取和执行包含filer命令的文件、一行行执行,但是其中一行出错,并不报错,继续执行,但执行结果会有问题,文件写全路径名,因为DataONTAP没有当前路径的概念。 #Auto-generated by setup Wed Mar 24 05:06:20 GMT 2010 hostname tan ifconfig ns0 `hostname`-ns0 mediatype auto route add default 192.168.0.1 1 add net default: gateway 192.168.0.1: entry already exists routed on options dns.enable off options nis.enable off
Disk Management类
一些命令解释,storage命令详解: dns –显示DNS信息,控制DNS子系统 tan> dns info ===显示DNS解析器的状态 DNS is disabled tan> dns flush ===删除DNS cache中的所有条目 DNS cache flushed. storage –这个命令用来管理存储子系统中的磁盘、SCSI和光纤卡。可以enable或者disable卡,列出disk 的信息。 tan> storage show adapter Slot: v0 == 适配器在哪个slot Description: Fibre Channel Host Adapter v0 (Network Appliance VHA rev. 15) Firmware Rev: 42 FC Node Name: d:c7b:f40500:000000 FC Packet Size: 2112 Link Data Rate: 0 Gbit SRAM Parity: Yes External GBIC: No State: Enabled In Use: Yes Redundant: Yes = 是否冗余 Slot: v1 Description: Fibre Channel Host Adapter v1 (Network Appliance VHA rev. 15) Firmware Rev: 42 FC Node Name: d:d7b:f40500:000000 FC Packet Size: 2112 Link Data Rate: 0 Gbit SRAM Parity: Yes External GBIC: No State: Enabled In Use: Yes Redundant: Yes 。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。 tan> storage show adapter v0 === 指定适配器的名字,显示具体某个适配器 Slot: v0 Description: Fibre Channel Host Adapter v0 (Network Appliance VHA rev. 15) Firmware Rev: 42 FC Node Name: d:c7b:f40500:000000 FC Packet Size: 2112 Link Data Rate: 0 Gbit SRAM Parity: Yes External GBIC: No State: Enabled In Use: Yes Redundant: Yes tan> storage show == 显示所有元件 Slot: v0 Description: Fibre Channel Host Adapter v0 (Network Appliance VHA rev. 15) Firmware Rev: 42 FC Node Name: d:c7b:f40500:000000 FC Packet Size: 2112 Link Data Rate: 0 Gbit SRAM Parity: Yes External GBIC: No State: Enabled In Use: Yes Redundant: Yes storage show hub [ -a ] [ System and networking Management类 一些命令解释: maxfiles命令 –增加卷可以拥有的文件数量 tan> maxfiles vol0 Volume vol0: maximum number of files is currently 19990 (6054 used). tan> maxfiles vol0 30000 =增加vol0的文件数 The new maximum number of files specified is more than twice as big as it needs to be, based on current usage patterns. Increasing the maximum number of files consumes disk space, and the number can never be decreased. Configuring a large number of inodes can also result in less available memory after an upgrade, which means you might not be able to run WAFL_check. The new maximum number of files will be rounded to 29985. Are you sure you want to increase the maximum number of files? yes tan> maxfiles vol0 Volume vol0: maximum number of files is currently 29985 (6053 used). tan> uptime =系统已经启动多长时间 5:32am up 2:11 0 NFS ops, 0 CIFS ops, 0 HTTP ops, 0 FCP ops, 0 iSCSI ops vscan命令 –控制存储上面文件的病毒扫描 tan> vscan on Warning: CIFS clients will not be allowed to open files because there are no virus scanners registered with the filer. Are you sure? yes Thu Apr 1 05:39:35 GMT [vscan.server.connectedNone:warning]: CIFS: Virus scanning is enabled but no vscan (anti-virus) servers are connected to the filer. Thu Apr 1 05:39:35 GMT [vscan.enable:info]: CIFS: Virus scanning has been enabled. Virus scanning is enabled tan> vscan Virus scanning is enabled. No vscan servers are connected. List of extensions to scan: 001,002,386,3GR,??_,ACE,ACM,ADE,ADP,ADT,AP?,ARC,ARJ,ASA,ASD,ASP,AX?,B64,BA?,BIN,BMP,BO?,BZ?,CAB,CC?, CDR,CDX,CEO,CGI,CHM,CL?,CMD,CNV,CO?,CPL,CPT,CPY,CRT,CSC,CSS,CSV,D?B,DAT,DEV,DIF,DL?,DO?,DOC,DOT, DQY,DRV,EE?,EFV,EML,EX?,EXE,FDF,FMT,FO?,FPH,FPW,GF?,GIM,GIX,GMS,GNA,GW?,GWI,GZ?,HDI,HHT,HLP,HT?, HWD,ICE,ICS,IM?,IN?,IQY,ISP,ITS,JAR,JP?,JS?,LGP,LIB,LNK,LWP,LZH,M3U,MB0,MB1,MB2,MBR,MD?,MHT,MOD,MPD, MPP,MPT,MRC,MS?,MSG,MSO,NAP,NEW,NWS,OB?,OC?,OFT,OL?,OLE,OTM,OV?,PCD,PCI,PD?,PDF,PF?,PHP,PI?,PLG, POT,PP?,PPZ,PRC,PWZ,QLB,QPW,QQY,QTC,RAR,REG,RMF,RQY,RTF,SCR,SCT,SH?,SIS,SKV,SLK,SMM,SPL,SRF,SWF,SYS, TAR,TAZ,TBZ,TD0,TFT,TGZ,TLB,TSP,UNP,URL,UUU,VB?,VBS,VS?,VVV,VWP,VXD,WBK,WIZ,WMV,WP?,WRI,WRL,WRZ, WS?,X32,XL?,XML,XRF,XSL,XTP,XX?,Z0M,Z??,ZI?,ZIP,ZL?,ZZZ List of extensions not to scan: Extensions-not-to-scan list is empty. Number of files scanned: 0 Number of scan failures: 0 Number of throttled requests: 0 useradmin命令 –管理存储的访问控制 useradmin user command argument... useradmin domainuser command argument... useradmin group command argument... useradmin role command argument... useradmin whoami user可以放到一个或多个group里 domainuser:必须CIFS起来,通过windows域来验证。 group是user和domainuser的容器,可以有一个或多个角色 role一组能力(可以执行某些动作的能力) 有六组内置的能力: login-*, cli-*,api-*, security-*, compliance-* and filerview-readonly tan> useradmin role add tanyx -a login-*,cli-help*,cli-ifconfig* ===新建一个role Thu Apr 1 06:57:58 GMT [useradmin.added.deleted:info]: The role 'tanyx' has been added. Role Service and protoocls类 Files and diretories类 Device control类 1.2、几个有用的管理命令 tan> ifstat ns0 ----- print i/f, driver statistics -- interface ns0 (0 hours, 10 minutes, 32 seconds) -- RECEIVE Frames/second: 0 | Bytes/second: 0 | Errors/minute: 0 Discards/minute: 0 | Total frames: 221 | Total bytes: 14548 Total errors: 0 | Total discards: 0 | Multi/broadcast: 221 No buffers: 0 | Non-primary u/c: 0 | Tag drop: 0 Vlan tag drop: 0 | Vlan untag drop: 0 | Read errors: 0 TRANSMIT Frames/second: 0 | Bytes/second: 0 | Errors/minute: 0 Discards/minute: 0 | Total frames: 32 | Total bytes: 3376 Total errors: 0 | Total discards: 0 | Multi/broadcast: 32 Queue overflows: 0 | No buffers: 0 | Write errors: 0 LINK_INFO Current state: up | Up to downs: 0 | Speed: 100m Duplex: full | Flowcontrol: none tan> nfsstat ----displays statistical information about NFS (Net-work File System) and RPC (Remote Procedure Call) for the filer. Server rpc: TCP: calls badcalls nullrecv badlen xdrcall 0 0 0 0 0 UDP: calls badcalls nullrecv badlen xdrcall 0 0 0 0 0 Server nfs: calls badcalls 0 0 Server nfs V2: (0 calls) null getattr setattr root lookup readlink read 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% wrcache write create remove rename link symlink 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% mkdir rmdir readdir statfs 0 0% 0 0% 0 0% 0 0% Read request stats (version 2) 0-511 512-1023 1K-2047 2K-4095 4K-8191 8K-16383 16K-32767 32K-65535 64K-131071 > 131071 0 0 0 0 0 0 0 0 0 0 Write request stats (version 2) 0-511 512-1023 1K-2047 2K-4095 4K-8191 8K-16383 16K-32767 32K-65535 64K-131071 > 131071 0 0 0 0 0 0 0 0 0 0 Server nfs V3: (0 calls) null getattr setattr lookup access readlink read 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% write create mkdir symlink mknod remove rmdir 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% rename link readdir readdir+ fsstat fsinfo pathconf 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% 0 0% commit 0 0% Read request stats (version 3) 0-511 512-1023 1K-2047 2K-4095 4K-8191 8K-16383 16K-32767 32K-65535 64K-131071 > 131071 0 0 0 0 0 0 0 0 0 0 Write request stats (version 3) 0-511 512-1023 1K-2047 2K-4095 4K-8191 8K-16383 16K-32767 32K-65535 64K-131071 > 131071 0 0 0 0 0 0 0 0 0 0 tan> sysstat CPU NFS CIFS HTTP Net kB/s Disk kB/s Tape kB/s Cache in out read write read write age 0% 0 0 0 0 0 3 14 0 0 >60 0% 0 0 0 0 0 5 22 0 0 >60 tan*> wrfile /etc/test ==如何编辑一个文件 test1 ==按ctrl+C退出 read: error reading standard input: Interrupted system call tan*> rdfile /etc/test ==读文件内容 test1 tan*> wrfile -a /etc/test test2 ==追加一行 tan*> rdfile /etc/test ===注意提示符 test1 test2 tan*> mv /etc/test /etc/test1 1.3、使用statit命令 Statit命令生成一个报告,内容是详细的系统利用率,由于输出内容很多,所以最好捕捉输出到文件或者可滚动的屏幕。 只有在高级管理状态才可以使用此命令。 tan> priv set advanced tan*> statit -b tan*> statit -e Hostname: tan ID: 0099908572 Memory: 512 MB NetApp Release 7.3: Thu Jul 24 12:55:28 PDT 2008 statit命令可以查看以下内容: CPU statistics Multiprocessor statistics CSMP domain switches Miscellaneous statistics WAFL® statistics RAID statistics Network interface statistics Disk statistics Aggregate statistics Spares and other disks FCP statistics iSCSI statistics Tape statistics 1.4、执行特殊的BOOT命令 如何访问特殊boot命令,当执行了halt或者reboot命令后,按CTRL+C后就可以进入特殊boot命令。 进入这个状态主要是为了新安装系统和troubleshooting. 执行(2)或者(5)的时候,一般用于排错,执行(4)或者(4a)的时候,一般在系统安装的时候非常有用。 选择(1)其实就是正常启动。 选择(2)也是执行正常启动,但是不按照/etc/rc里面的配置,这时候可以手工执行rc文件里面的内容,比如ifconfig,cifs setup,NFS等,以排除因为/etc/rc里面配置的问题,造成系统不正常。 选择(3)忘记密码的时候用。 选择(4),这个命令一般就在安装的时候执行一次,它会格式化所有的盘,而且一旦确认就不可挽回,这个操作持续时间很长,取决于有多少盘,一般持续几个小时,以前硬盘上所有数据,全部丢失。 选择(6),这个状态只有部分命令可以执行,通常用来执行硬盘相关的问题,/etc/rc文件不会被解释,WAFL volume可以识别但是不可用,很少的系统服务会启动,NFS和CIFS不可用等。 除了重启命令执行后,可以进入特殊boot状态,执行此命令也可以进入此状态: 先halt系统 然后执行setenv floppy-boot?true This session is logged in /sim/node1/sessionlogs/log floppy boot? yes NetApp Release 7.3: Thu Jul 24 12:55:28 PDT 2008 Copyright (c) 1992-2008 Network Appliance, Inc. Starting boot on Sat Apr 3 10:43:43 GMT 2010 (1) Normal boot. (2) Boot without /etc/rc. (3) Change password. (4) Initialize all disks. (4a) Same as option 4, but create a flexible root volume. (5) Maintenance mode boot. Selection (1-5)? *> ? ==注意提示符 fcadmin sasadmin storage aggr fcstat sasstat sysconfig disk halt sata version disk_list help scsi vol disk_mung raid_config sesdiag xortest environment Selection (1-5)? 4a ===选择4a的结果 Zero disks and install a new file system? yes This will erase all the data on the disks, are you sure? yes Zeroing disks takes about 56 minutes. .................................................................. Sat Apr 3 11:35:36 GMT [raid.disk.zero.done:notice]: Disk v0.16 Shelf ? Bay ? [NETAPP VD-100MB 0042] S/N [13740500] : disk zeroing complete .Sat Apr 3 11:35:37 GMT [raid.disk.zero.done:notice]: Disk v0.18 Shelf ? Bay ? [NETAPP VD-100MB 0042] S/N [13740502] : disk zeroing complete Sat Apr 3 11:35:37 GMT [raid.disk.zero.done:notice]: Disk v0.17 Shelf ? Bay ? [NETAPP VD-100MB 0042] S/N [13740501] : disk zeroing complete ................... 格式化完了,会让执行setup.重新格式化所有的license全部丢失了。 node1> aggr offline aggr2 ==在正常模式下,如果aggr上有灵活卷,不允许offline aggr offline: Cannot offline aggregate 'aggr2' because it contains one or more flexible volumes. *> aggr offline aggr2 ===在维护模式,就可以实现,说明维护模式可以做一些正常模式做不了的 Aggregate 'aggr2' is now offline. *> aggr read_fsid aggr2 ===这个命令只有在服务模式才可以获得,每个aggr的fsid必须不同 Aggregate aggr2 has an FSID of 0x4caba711. *> aggr read_fsid aggr0 Aggregate aggr0 has an FSID of 0x4caba506. (1) Normal boot. (2) Boot without /etc/rc. (3) Change password. (4) Initialize all disks. (4a) Same as option 4, but create a flexible root volume. (5) Maintenance mode boot. Selection (1-5)? 2 ====选择2模式 booting without /etc/rc and without various system daemons.. > ifconfig –a ===看见网卡并没有IP地址,就是因为没有读/etc/rc ns0: flags=8042 秘密的启动命令,键入22/7见下图: Selection (1-5)? Readonly ===选择readonly启动 Selection (1-5)? vol_clear_inconsistent vol1 aggr2 vol_clear_inconsistent: successfully enqueued Selection (1-5)? WAFL_check In a cluster, you MUST ensure that the partner is (and remains) down, or that takeover is manually disabled on the partner node, because clustering software is not started or fully enabled in WAFL_check mode. FAILURE TO DO SO CAN RESULT IN YOUR FILESYSTEMS BEING DESTROYED Continue with boot? yes Check aggr2? yes Check aggr0? yes Checking aggr2... WAFL_check NetApp Release 7.3 Starting at Sat Apr 3 12:15:52 GMT 2010 Phase 1: Verify fsinfo blocks. Phase 2: Verify metadata indirect blocks. Phase 3: Scan inode file. Phase 3a: Scan inode file special files. Phase 3a time in seconds: 0 Phase 3b: Scan inode file normal files. Phase 3b time in seconds: 0 Phase 3 time in seconds: 0 Phase 4: Scan directories. Phase 4 time in seconds: 1 Phase 5: Check volumes. Phase 5a: Check volume inodes Phase 5a time in seconds: 0 Phase 5b: Check volume contents Checking volume vol1... Phase [5.1]: Verify fsinfo blocks. Phase [5.2]: Verify metadata indirect blocks. Phase [5.3]: Scan inode file. Phase [5.3a]: Scan inode file special files. Phase [5.3a] time in seconds: 0 Phase [5.3b]: Scan inode file normal files. Phase [5.3b] time in seconds: 0 Phase [5.3] time in seconds: 0 Phase [5.4]: Scan directories. Phase [5.4] time in seconds: 0 Phase [5.6]: Clean up. Phase [5.6a]: Find lost nt streams. Phase [5.6a] time in seconds: 0 Phase [5.6b]: Find lost files. Phase [5.6b] time in seconds: 0 Phase [5.6c]: Find lost blocks. Phase [5.6c] time in seconds: 0 Phase [5.6d]: Check blocks used. Phase [5.6d] time in seconds: 0 Phase [5.6] time in seconds: 0 Volume vol1 WAFL_check time in seconds: 0 (No filesystem state changed.) Phase 5b time in seconds: 0 Phase 6: Clean up. Phase 6a: Find lost nt streams. Phase 6a time in seconds: 0 Phase 6b: Find lost files. Phase 6b time in seconds: 3 Phase 6c: Find lost blocks. Phase 6c time in seconds: 0 Phase 6d: Check blocks used. Phase 6d time in seconds: 0 Phase 6 time in seconds: 3 WAFL_check total time in seconds: 5 (No filesystem state changed.) Checking aggr0... WAFL_check NetApp Release 7.3 Starting at Sat Apr 3 12:15:57 GMT 2010 Phase 1: Verify fsinfo blocks. Phase 2: Verify metadata indirect blocks. Phase 3: Scan inode file. Phase 3a: Scan inode file special files. Phase 3a time in seconds: 0 Phase 3b: Scan inode file normal files. Phase 3b time in seconds: 0 Phase 3 time in seconds: 0 Phase 4: Scan directories. Phase 4 time in seconds: 0 Phase 5: Check volumes. Phase 5a: Check volume inodes Phase 5a time in seconds: 0 Phase 5b: Check volume contents Checking volume vol0... Phase [5.1]: Verify fsinfo blocks. Phase [5.2]: Verify metadata indirect blocks. Phase [5.3]: Scan inode file. Phase [5.3a]: Scan inode file special files. Phase [5.3a] time in seconds: 0 Phase [5.3b]: Scan inode file normal files. Phase [5.3b] time in seconds: 0 Phase [5.3] time in seconds: 0 Phase [5.4]: Scan directories. Phase [5.4] time in seconds: 1 Phase [5.6]: Clean up. Phase [5.6a]: Find lost nt streams. Phase [5.6a] time in seconds: 0 Phase [5.6b]: Find lost files. Phase [5.6b] time in seconds: 0 Phase [5.6c]: Find lost blocks. Phase [5.6c] time in seconds: 0 Phase [5.6d]: Check blocks used. Phase [5.6d] time in seconds: 0 Phase [5.6] time in seconds: 0 Volume vol0 WAFL_check time in seconds: 1 (No filesystem state changed.) Phase 5b time in seconds: 1 Phase 6: Clean up. Phase 6a: Find lost nt streams. Phase 6a time in seconds: 0 Phase 6b: Find lost files. Phase 6b time in seconds: 0 Phase 6c: Find lost blocks. Phase 6c time in seconds: 0 Phase 6d: Check blocks used. Phase 6d time in seconds: 0 Phase 6 time in seconds: 0 WAFL_check total time in seconds: 2 (No filesystem state changed.) Press Enter to reboot system. Selection (1-5)? wafliron add net 127.0.0.0: gateway 127.0.0.1 Sat Apr 3 12:19:39 GMT [fmmb.current.lock.disk:info]: Disk v0.18 is a local HA mailbox disk. Sat Apr 3 12:19:39 GMT [fmmb.current.lock.disk:info]: Disk v0.17 is a local HA mailbox disk. Sat Apr 3 12:19:39 GMT [fmmb.instStat.change:info]: normal mailbox instance on local side. Sat Apr 3 12:19:40 GMT [fmmb.current.lock.disk:info]: Disk v4.16 is a partner HA mailbox disk. Sat Apr 3 12:19:40 GMT [fmmb.instStat.change:info]: normal mailbox instance on partner side. Sat Apr 3 12:19:42 GMT [raid.vol.replay.nvram:info]: Performing raid replay on volume(s) Restoring parity from NVRAM Sat Apr 3 12:19:42 GMT [raid.cksum.replay.summary:info]: Replayed 0 checksum blocks. Sat Apr 3 12:19:42 GMT [raid.stripe.replay.summary:info]: Replayed 0 stripes. Sat Apr 3 12:19:43 GMT [wafl.iron.start:notice]: Starting wafliron on aggregate aggr0. Sat Apr 3 12:19:43 GMT [wafl.iron.start:notice]: Starting wafliron on volume vol0. Replaying WAFL log . Sat Apr 3 12:19:47 GMT [rc:notice]: The system was down for 874 seconds Sat Apr 3 12:19:47 GMT [javavm.javaDisabled:warning]: Java disabled: Missing /etc/java/rt131.jar. Sat Apr 3 12:19:47 GMT [dfu.firmwareUpToDate:info]: Firmware is up-to-date on all disk drives Sat Apr 3 12:19:48 GMT [netif.linkUp:info]: Ethernet ns0: Link up. Sat Apr 3 12:19:48 GMT [netif.linkUp:info]: Ethernet ns1: Link up. add net default: gateway 192.168.0.1 Sat Apr 3 12:19:48 GMT [perf.archive.start:info]: Performance archiver started. Sampling 20 objects and 187 counters. Sat Apr 3 12:19:49 GMT [httpd.servlet.jvm.down:warning]: Java Virtual Machine is inaccessible. FilerView cannot start until you resolve this problem. Sat Apr 3 12:19:49 GMT [snmp.agent.msg.access.denied:warning]: Permission denied for SNMPv3 requests from root. Reason: Password is too short (SNMPv3 requires at least 8 characters). Sat Apr 3 12:19:49 GMT [sysconfig.sysconfigtab.openFailed:notice]: sysconfig: table of valid configurations (/etc/sysconfigtab) is missing. Sat Apr 3 12:19:50 GMT [mgr.boot.disk_done:info]: NetApp Release 7.3 boot complete. Last disk update written at Sat Apr 3 12:04:59 GMT 2010 Sat Apr 3 12:19:50 GMT [cf.fm.unexpectedAdapter:warning]: Warning: clustering is not licensed yet an interconnect adapter was found. NVRAM will be divided into two parts until adapter is removed Sat Apr 3 12:19:50 GMT [cf.fm.unexpectedPartner:warning]: Warning: clustering is not licensed yet the node once had a cluster partner Sat Apr 3 12:19:50 GMT [mgr.boot.reason_ok:notice]: System rebooted after running WAFL_check. Sat Apr 3 12:19:50 GMT [wafl.scan.start:info]: Starting wafliron demand on aggregate aggr0. Sat Apr 3 12:19:50 GMT [wafl.scan.start:info]: Starting wafliron demand on volume vol0. Password: Sat Apr 3 12:19:51 GMT [wafl.iron.completion.times:info]: Mounting phase of volume vol0 took 3s 770ms. Sat Apr 3 12:19:51 GMT [wafl.iron.completion.times:info]: Inode scanning phase of volume vol0 took 1s 450ms. Sat Apr 3 12:19:51 GMT [wafl.iron.completion.times:info]: Lost blocks search phase of volume vol0 took 190ms. Sat Apr 3 12:19:51 GMT [wafl.iron.completion.times:info]: Lost inodes search phase of volume vol0 took 30ms. Sat Apr 3 12:19:52 GMT [wafl.scan.iron.done:info]: Volume vol0, wafliron completed. Sat Apr 3 12:19:53 GMT [wafl.iron.completion.times:info]: Mounting phase of aggregate aggr0 took 4s 449ms. Sat Apr 3 12:19:53 GMT [wafl.iron.completion.times:info]: Inode scanning phase of aggregate aggr0 took 3s 139ms. Sat Apr 3 12:19:53 GMT [wafl.iron.completion.times:info]: Lost blocks search phase of aggregate aggr0 took 11ms. Sat Apr 3 12:19:53 GMT [wafl.iron.completion.times:info]: Lost inodes search phase of aggregate aggr0 took 30ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Rootdir mount phase of aggregate aggr0 took 40ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Activemap mount phase of aggregate aggr0 took 20ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Snap inofiles mount phase of aggregate aggr0 took 0ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Snap selfcover mount phase of aggregate aggr0 took 0ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Snapdir mount phase of aggregate aggr0 took 20ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Snapmaps mount phase of aggregate aggr0 took 0ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Summary map mount phase of aggregate aggr0 took 0ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Refcnt mount phase of aggregate aggr0 took 10ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Metadir mount phase of aggregate aggr0 took 160ms. Sat Apr 3 12:19:53 GMT [wafl.iron.mount.times:info]: Flex vols mount phase of aggregate aggr0 took 140ms. Sat Apr 3 12:19:53 GMT [wafl.scan.iron.done:info]: Aggregate aggr0, wafliron completed. 二、检查状态及性能管理 2.1、检查系统 好的性能是硬件、软件和通讯协议之间一起以最佳状态运行。持续的监控系统和用一组NETAPP命令可以调整你的系统减少等待时间、改进数据吞吐量、达到最优性能。下面介绍一组工具关于检查系统中不同元件的状态和健康情况。 2.1.1、sysconfig 第一个命令就是sysconfig,用这个命令可以看见以下输出: 内存是否正确 显示盘柜 显示磁带驱动器 显示NIC tan> sysconfig NetApp Release 7.3: Thu Jul 24 12:55:28 PDT 2008 System ID: 0099908572 (tan) System Serial Number: 987654-32-0 (tan) Model Name: Simulator Processors: 1 slot 0: NetApp Virtual SCSI Host Adapter v0 3 Disks: 0.3GB 1 shelf with LRC slot 1: NetApp Virtual SCSI Host Adapter v1 25 Disks: 13.0GB 2 shelves with LRC slot 2: NetApp Virtual SCSI Host Adapter v2 slot 3: NetApp Virtual SCSI Host Adapter v3 slot 4: NetApp Virtual SCSI Host Adapter v4 3 Disks: 0.3GB 1 shelf with LRC slot 5: NetApp Virtual SCSI Host Adapter v5 25 Disks: 13.0GB 2 shelves with LRC slot 6: NetApp Virtual SCSI Host Adapter v6 slot 7: NetApp Virtual SCSI Host Adapter v7 slot 8: NetApp Virtual SCSI Host Adapter v8 4 Tapes: VT-100MB VT-100MB VT-100MB VT-100MB tan> sysconfig –a ==显示每个I/O的详细信息 tan> sysconfig –c ==检查系统硬件配置 sysconfig: There are no configuration errors. tan> sysconfig –d ==显示系统中的盘 Device HA SHELF BAY CHAN Disk Vital Product Information ---------- --------------- ----- ------------------------------ v4.16 v4 1 0 FC:B 13740500 v4.17 v4 1 1 FC:B 13740501 v4.18 v4 1 2 FC:B 13740502 v5.16 v5 1 0 FC:B 10604900 v5.17 v5 1 1 FC:B 10604901 v5.18 v5 1 2 FC:B 10604902 v5.19 v5 1 3 FC:B 10604903 v5.20 v5 1 4 FC:B 10604904 v5.21 v5 1 5 FC:B 10604905 v5.22 v5 1 6 FC:B 10604906 v5.24 v5 1 8 FC:B 10604907 v5.25 v5 1 9 FC:B 10605008 v5.26 v5 1 10 FC:B 10605009 v5.27 v5 1 11 FC:B 10605010 v5.28 v5 1 12 FC:B 10605011 v5.29 v5 1 13 FC:B 10605012 v5.32 v5 2 0 FC:B 10605013 v5.33 v5 2 1 FC:B 10605014 v5.34 v5 2 2 FC:B 10605015 v5.35 v5 2 3 FC:B 10605016 v5.36 v5 2 4 FC:B 10605017 v5.37 v5 2 5 FC:B 10605018 v5.38 v5 2 6 FC:B 10605019 v5.39 v5 2 7 FC:B 10605020 v5.40 v5 2 8 FC:B 10605021 v5.41 v5 2 9 FC:B 10605022 v5.42 v5 2 10 FC:B 10605023 v5.43 v5 2 11 FC:B 10605024 tan> sysconfig –t ==显示系统中的磁带驱动器信息 Tape drive (v8.0) NETAPP VT-100MB rst0l - rewind device, format is: VT-100MB (100 MB) nrst0l - no rewind device, format is: VT-100MB (100 MB) urst0l - unload/reload device, format is: VT-100MB (100 MB) rst0m - rewind device, format is: VT-100MB (100 MB) nrst0m - no rewind device, format is: VT-100MB (100 MB) urst0m - unload/reload device, format is: VT-100MB (100 MB) rst0h - rewind device, format is: VT-100MB (100 MB) nrst0h - no rewind device, format is: VT-100MB (100 MB) urst0h - unload/reload device, format is: VT-100MB (100 MB) rst0a - rewind device, format is: VT-100MB (w/compression) nrst0a - no rewind device, format is: VT-100MB (w/compression) urst0a - unload/reload device, format is: VT-100MB (w/compression) tan> sysconfig –v ===显示DATAONTAP版本,PCI插槽上的所有设备和内存,显示每个东西。 上图的存储相关硬件示意图。 2.1.2、sysstat 最好的命令看CPU利用率是sysstat [interval]. Sysstat 1指定每一秒更新一次(缺省是15秒) 我们可以判断并回答以下命令: 使用是稳定的还是波动的 CPU利用率是否过高以致无法响应输入输出行为。 tan> sysstat 1 CPU NFS CIFS HTTP Net kB/s Disk kB/s Tape kB/s Cache in out read write read write age 0% 0 0 0 0 0 0 0 0 0 >60 0% 0 0 0 0 0 0 0 0 0 >60 第一列表示CPU的忙闲程度,如果是70%-80%则说明比较忙 第二列表示网络流量每秒/千字节。 第三列表示每秒/千字节磁盘的I/O.filer用NVRAM来限制到磁盘的写流量,用RAM去缓存读数据,磁盘读发生在数据部在cache中,理想状态下,磁盘写每10秒发生一次,所以9行的输入是0,然后是一个大的写入,持续的写会增加CPU的负载,最后影响写的性能。 2.1.3、与优化CPU性能的options命令 tan> options raid.reconstruct raid.reconstruct.perf_impact medium ==控制raidgroup重构的时候,CPU的利用情况,如果想提高重构速度,则降低此值 tan> options raid.scrub raid.scrub.duration 360 raid.scrub.enable on raid.scrub.perf_impact low raid.scrub.schedule tan> options vol.copy vol.copy.throttle 10 tan> options wafl.max ==定义最大的目录大小 wafl.maxdirsize 5242 tan> vol options vol0 maxdirsize 5000 ==定义vol最大的目录大小
因篇幅问题不能全部显示,请点此查看更多更全内容