L
LWG
I am trying to find a way to parse the output from an arcserver command. The
command basically dumps the tapes loaded in the 40 available slots. The
output follows: (btw this is only 5 of the 40 slots)
SLOT NAME ID SEQ. SERNO LOADED WP
1 <<Cleaning Cartridge>> 0000 0 -- --
2 BD8671L1 7f4a 1 BD8671L1 NO NO
3 BD8698L1 902a 4 BD8625L1 NO NO
4 6/19/04 5:50 PM bf50 1 BD8568L1 NO NO
5 9/24/04 6:47 PM b49d 1 BD8975L1 YES NO
the columns are sorted like:
slot name id seq. serno loaded wp
the diffuculty is when there are spaces in the name. The slot 1 has the
cleaning cartridge which has no serial number and creates another porblem.
What I want as an ouput is the slot and serno columns. So it would look
like:
1 bd8569l1
2 bd8975l1
3 bd1234l1
4 bd3338l1...
Thx for the help in advance...
L
command basically dumps the tapes loaded in the 40 available slots. The
output follows: (btw this is only 5 of the 40 slots)
SLOT NAME ID SEQ. SERNO LOADED WP
1 <<Cleaning Cartridge>> 0000 0 -- --
2 BD8671L1 7f4a 1 BD8671L1 NO NO
3 BD8698L1 902a 4 BD8625L1 NO NO
4 6/19/04 5:50 PM bf50 1 BD8568L1 NO NO
5 9/24/04 6:47 PM b49d 1 BD8975L1 YES NO
the columns are sorted like:
slot name id seq. serno loaded wp
the diffuculty is when there are spaces in the name. The slot 1 has the
cleaning cartridge which has no serial number and creates another porblem.
What I want as an ouput is the slot and serno columns. So it would look
like:
1 bd8569l1
2 bd8975l1
3 bd1234l1
4 bd3338l1...
Thx for the help in advance...
L