IOS XR 4.0 release 以降において、"file" コマンドで "append" オプションを使用することにより、
複数のコマンド出力を一つのファイルに保存することが可能です。
以下のように "file" でコマンド出力をファイルに保存します。
-----
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#show running-config | file test.txt
Building configuration...
[OK]
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#show running-config | file harddisk:test.txt
Building configuration...
[OK]
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#more harddisk:test.txt
!! File saved at 06:48:23 UTC Tue Apr 17 2012 by cisco
!! IOS XR Configuration 4.1.2
!! Last configuration change at Tue Apr 17 06:47:45 2012 by cisco
!
end
RP/0/RP0/CPU0:ios#
-----
その後、append オプションを使用して "file" コマンドで上記と同じファイルにコマンド出力を保存できます。
-----
RP/0/RP0/CPU0:ios#show version brief | file append harddisk:test.txt
[OK]
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#more harddisk:test.txt
!! File saved at 06:48:23 UTC Tue Apr 17 2012 by cisco
!! IOS XR Configuration 4.1.2
!! Last configuration change at Tue Apr 17 06:47:45 2012 by cisco
!
end
================================================================================
^@show version brief | file append harddisk:test.txt
================================================================================
^@!! File saved at 06:48:51 UTC Tue Apr 17 2012 by cisco
Cisco IOS XR Software, Version 4.1.2[Default]
Copyright (c) 2011 by Cisco Systems, Inc.
ROM: System Bootstrap, Version 2.04(20110408:051659) [CRS ROMMON],
ios uptime is 1 day, 6 hours, 42 minutes
System image file is "bootflash:disk0/hfr-os-mbi-4.1.2/mbihfr-rp.vm"
cisco CRS-4/S (7457) processor with 4194304K bytes of memory.
7457 processor at 1197Mhz, Revision 1.2
Cisco CRS Series 4 Slots Line Card Chassis
1 Management Ethernet
1 TenGigE
10 GigabitEthernet
2 SONET/SDH
2 Packet over SONET/SDH
1019k bytes of non-volatile configuration memory.
38079M bytes of hard disk.
981440k bytees of disk0: (Sector size 512 bytes).
RP/0/RP0/CPU0:ios#
RP/0/RP0/CPU0:ios#
-----