Extraction fichier
othmane19
Messages postés
96
Date d'inscription
Statut
Membre
Dernière intervention
-
othmane19 Messages postés 96 Date d'inscription Statut Membre Dernière intervention -
othmane19 Messages postés 96 Date d'inscription Statut Membre Dernière intervention -
Bonjour,
je suis bloqué dans un truc et j 'espère avoir votre aide :
en faisant le parcours des ligne d'un fichier je veux afficher le number topology change pour chaque vlan,en passant par script perl
et comme je suis débutant en perl je vois pas comment faire les extraction des chaîne de caracere
voila le fichier que je veux traiter:
VLAN0001 is executing the rstp compatible Spanning Tree Protocol
Bridge Identifier has priority of 32768, sysid 1, 0040.0BA7.34D1
Configured hello time 2, max age 20, forward delay 15
Current root has priority 32769
Topology change flag not set, detected flag set
Number of topology changes 1 last change occurred 00:00:00 ago
from FastEthernet0/1
Times: hold 1, topology change 35, notification 2
hello 2, max age 20, forward delay 15
Timers: hello 0, topology change 0, notification 0, aging 300
Port 1 (FastEthernet0/1) of VLAN0001 is designated forwarding
Port path cost 19, Port priority 128, Port Identifier 128.1
Designated bridge has priority 32769, address 0040.0BA7.34D1
Designated port id is 128.1, designated path cost 19
Timers: message age 16, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is point-to-point by default
VLAN0010 is executing the rstp compatible Spanning Tree Protocol
Bridge Identifier has priority of 16384, sysid 10, 0040.0BA7.34D1
Configured hello time 2, max age 20, forward delay 15
Current root has priority 16394
Topology change flag not set, detected flag not set
Number of topology changes 0 last change occurred 00:00:00 ago
from FastEthernet0/1
Times: hold 1, topology change 35, notification 2
hello 2, max age 20, forward delay 15
Timers: hello 0, topology change 0, notification 0, aging 300
le résultat souhaité
VLAN0010
number topology change:1
VLAN0010
number topology change:0
a part le faite de faire la boucle(pour la parcoure des lignes)je vois pas comment je peux faire les filtre nécessaire :
while (my $ligne = <DATA>){
}
Voila, si quelqu'un à une idée sur le code,c'est très volontier !
je suis vraiment bloqué,et votre aide me serait vraiment utile
merci d'avance
je suis bloqué dans un truc et j 'espère avoir votre aide :
en faisant le parcours des ligne d'un fichier je veux afficher le number topology change pour chaque vlan,en passant par script perl
et comme je suis débutant en perl je vois pas comment faire les extraction des chaîne de caracere
voila le fichier que je veux traiter:
VLAN0001 is executing the rstp compatible Spanning Tree Protocol
Bridge Identifier has priority of 32768, sysid 1, 0040.0BA7.34D1
Configured hello time 2, max age 20, forward delay 15
Current root has priority 32769
Topology change flag not set, detected flag set
Number of topology changes 1 last change occurred 00:00:00 ago
from FastEthernet0/1
Times: hold 1, topology change 35, notification 2
hello 2, max age 20, forward delay 15
Timers: hello 0, topology change 0, notification 0, aging 300
Port 1 (FastEthernet0/1) of VLAN0001 is designated forwarding
Port path cost 19, Port priority 128, Port Identifier 128.1
Designated bridge has priority 32769, address 0040.0BA7.34D1
Designated port id is 128.1, designated path cost 19
Timers: message age 16, forward delay 0, hold 0
Number of transitions to forwarding state: 1
Link type is point-to-point by default
VLAN0010 is executing the rstp compatible Spanning Tree Protocol
Bridge Identifier has priority of 16384, sysid 10, 0040.0BA7.34D1
Configured hello time 2, max age 20, forward delay 15
Current root has priority 16394
Topology change flag not set, detected flag not set
Number of topology changes 0 last change occurred 00:00:00 ago
from FastEthernet0/1
Times: hold 1, topology change 35, notification 2
hello 2, max age 20, forward delay 15
Timers: hello 0, topology change 0, notification 0, aging 300
le résultat souhaité
VLAN0010
number topology change:1
VLAN0010
number topology change:0
a part le faite de faire la boucle(pour la parcoure des lignes)je vois pas comment je peux faire les filtre nécessaire :
while (my $ligne = <DATA>){
}
Voila, si quelqu'un à une idée sur le code,c'est très volontier !
je suis vraiment bloqué,et votre aide me serait vraiment utile
merci d'avance
A voir également:
- Extraction fichier
- Fichier bin - Guide
- Fichier epub - Guide
- Fichier rar - Guide
- Comment réduire la taille d'un fichier - Guide
- Fichier .dat - Guide