キャンセル
次の結果を表示 
次の代わりに検索 
もしかして: 
cancel
15329
閲覧回数
0
いいね!
0
コメント
yushimaz
Cisco Employee
Cisco Employee

 

1. はじめに

 
ACI の Troubleshooting において TAC Engineer がよくお願いする command をまとめたものです。
TAC Engineer から tac-outputs の取得をお願いしますと言われた場合、2. tac-outpus に記載されている command を APIC で順番に実行し、/data/techsupport/ に保存されているtac-outputs.tgz を TAC へ送付してください。 Switch に関する障害の場合、APIC に加え、該当 Switch でも取得してください。
 

2. tac-outputs

 
bash

mkdir /tmp/tac-outputs
cd /tmp/tac-outputs
icurl 'http://localhost:7777/api/class/firmwareARunning.xml' > /tmp/tac-outputs/firmwareARunning.xml
icurl 'http://localhost:7777/api/class/fabricNode.xml' > /tmp/tac-outputs/fabricNode.xml
icurl 'http://localhost:7777/api/class/faultInfo.xml' > /tmp/tac-outputs/faultInfo.xml
icurl 'http://localhost:7777/api/class/aaaModLR.xml?order-by=aaaModLR.created|desc&page-size=100000' > /tmp/tac-outputs/aaaModLR.xml
icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000' > /tmp/tac-outputs/faultRecord.xml
icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=1' > /tmp/tac-outputs/faultRecord-1.xml
icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=2' > /tmp/tac-outputs/faultRecord-2.xml
icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=3' > /tmp/tac-outputs/faultRecord-3.xml
icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=4' > /tmp/tac-outputs/faultRecord-4.xml
icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000' > /tmp/tac-outputs/eventRecord.xml
icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=1' > /tmp/tac-outputs/eventRecord1.xml
icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=2' > /tmp/tac-outputs/eventRecord2.xml
icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=3' > /tmp/tac-outputs/eventRecord3.xml
icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=4' > /tmp/tac-outputs/eventRecord4.xml

cd /tmp
tar zcvf tac-outputs.tgz tac-outputs
cp tac-outputs.tgz /data/techsupport
rm -rf /tmp/tac-outputs
rm tac-outputs.tgz
取得後、File が正常に生成されているかを確認してください。
取得情報が多い場合、取得に失敗し、File Size が 0 となっている場合があります。
その場合には、page-size=100000 の箇所を page-size=50000 のように小さくして再度取得してください。
上記例の場合、100000 record の情報を 5 page 分 (100000 x 5 = 500000 records) 取得しています。
page-size を変更した場合、取得する合計 record 数が減らないよう、page=5, page=6 のように、取得する page 数を増やしたものを追加で取得してください。
 

3. Download/Upload

 
ここでは 2. tac-outputs を実行し生成された tac-outputs.tgz を client pc から download する方法、及び、apic/switch から file server へ upload する方法について紹介します。
 
3-1. Download
 
scp, sftp で download 可能です。 環境に応じた scp, sftp client を使用してください。
cli で sftp を実行した例は下記になります。
apic の tac-outputs の場合は、https://[apic_address]/files/[apic_node-id]/techsupport/tac-outputs.tgz から browser 経由でも download 可能です。
 
$ sftp admin@apic_address
Application Policy Infrastructure Controller
admin@apic_address's password:
Connected to admin@apic_address.
sftp> cd /data/techsupport
sftp> get tac-outputs.tgz
Fetching /data/techsupport/tac-outputs.tgz to tac-outputs.tgz
/data/techsupport/tac-outputs.tgz                                                           100% 5621KB 758.4KB/s   00:07
sftp> quit
$
 

3-2. Upload

 
scp, sftp で upload 可能です。
実行例は下記になります。
 
apic# cd /data/techsupport
apic# sftp user@server_address
user@server_address's password:
Connected to server_address.
sftp> put tac-outputs.tgz
Uploading tac-outputs.tgz to /home/techsupport/tac-outputs.tgz
tac-outputs.tgz                                                                             100% 5621KB 109.5MB/s   00:00
sftp> quit
 

4. 応用編

 

複数回取得することになった場合に command 実行間違えの可能性が減るため、下記のように、shell script を作成しておくことをお勧めします。
./tac-outputs.sh で script を実行すると、tac-outputs.tgz が生成されます。
 
apic# bash
admin@apic:~> cat <<EOF > tac-outputs.sh
> #!/bin/bash
>
> mkdir /tmp/tac-outputs
> cd /tmp/tac-outputs
> icurl 'http://localhost:7777/api/class/firmwareARunning.xml' > /tmp/tac-outputs/firmwareARunning.xml
> icurl 'http://localhost:7777/api/class/fabricNode.xml' > /tmp/tac-outputs/fabricNode.xml
> icurl 'http://localhost:7777/api/class/faultInfo.xml' > /tmp/tac-outputs/faultInfo.xml
> icurl 'http://localhost:7777/api/class/aaaModLR.xml?order-by=aaaModLR.created|desc&page-size=100000' > /tmp/tac-outputs/aaaModLR.xml
> icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000' > /tmp/tac-outputs/faultRecord.xml
> icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=1' > /tmp/tac-outputs/faultRecord-1.xml
> icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=2' > /tmp/tac-outputs/faultRecord-2.xml
> icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=3' > /tmp/tac-outputs/faultRecord-3.xml
> icurl 'http://localhost:7777/api/class/faultRecord.xml?order-by=faultRecord.created|desc&page-size=100000&page=4' > /tmp/tac-outputs/faultRecord-4.xml
> icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000' > /tmp/tac-outputs/eventRecord.xml
> icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=1' > /tmp/tac-outputs/eventRecord1.xml
> icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=2' > /tmp/tac-outputs/eventRecord2.xml
> icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=3' > /tmp/tac-outputs/eventRecord3.xml
> icurl 'http://localhost:7777/api/class/eventRecord.xml?order-by=eventRecord.created|desc&page-size=100000&page=4' > /tmp/tac-outputs/eventRecord4.xml
>
> cd /tmp
> tar zcvf tac-outputs.tgz tac-outputs
> cp tac-outputs.tgz /data/techsupport
> rm -rf /tmp/tac-outputs
> rm tac-outputs.tgz
EOF
admin@apic:~> chmod +x tac-outputs.sh
admin@apic:~>
 

5. Collect TacOutputs Script

5.2(1g) 以降では、trigger tacoutput という command が apic に実装されました。 trigger tacoutput の使い方についてはACI: trigger tacoutput による tac-outputs の取得 もしくは Guide to collect Tech Support and TAC requested outputs for ACI確認してください。
それ以前の version を使用している場合でも、script を download することで同様の情報を取得することができます。
tac-outputs は、上記 2. - 4. の方法で取得しても、trigger tacoutput script を使用して取得しても構いません。
 
Getting Started

検索バーにキーワード、フレーズ、または質問を入力し、お探しのものを見つけましょう

シスコ コミュニティをいち早く使いこなしていただけるよう役立つリンクをまとめました。みなさんのジャーニーがより良いものとなるようお手伝いします