Cisco’da Kısayol OluÅŸturma
Karmaşık komutlar için cisco ios'larda yine network yöneticisi düşünülerek hazırlanmış
istenilen komutlara sadece istenilen mod'larda kullanılabilecek alias ekleme uzun süredir kullanılan bir özelliktir. Bu özellik eğlenme amaçlı olarak kullanılabileceği gibi, network yöneticilerine çok daha hızlı bir troubleshooting olanağı da sağlayabilmektedir.
Alias ekleyebilmek için, Global Configuration mod altında "alias" komutunu girince sıra ekleyeceğimiz alias'ın çalışacağı modu belirlemeye geliyor.
Bu aşamada istenilen mod seçilerek sıra istediğimiz komut için alias belirlemeye gelir.Belirlenen alias'tan sonra belirlediğimiz alias'ın çağıracağı komut belirlenerek, komut tamamlanır.
örnek:
Agciyiz(config)#alias exec eyvah show interface gigabitEthernet 0/1
Agciyiz#eyvah
GigabitEthernet0/1 is down, line protocol is down (notconnect)
Hardware is Gigabit Ethernet, address is 0011.2233.4455 (bia 0011.2233.4455)
MTU 1000 bytes, BW 10000 Kbit, DLY 1000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation ARPA, loopback not set
Keepalive set (10 sec)
Auto-duplex, 100Mb/s, media type is 10/100/1000BaseTX
input flow-control is off, output flow-control is unsupported
ARP type: ARPA, ARP Timeout 04:00:00
Last input never, output never, output hang never
Last clearing of "show interface" counters never
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: fifo
Output queue: 0/40 (size/max)
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
0 packets input, 0 bytes, 0 no buffer
Received 0 broadcasts (0 multicasts)
0 runts, 0 giants, 0 throttles
0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
0 watchdog, 0 multicast, 0 pause input
0 input packets with dribble condition detected
0 packets output, 0 bytes, 0 underruns
0 output errors, 0 collisions, 1 interface resets
0 babbles, 0 late collision, 0 deferred
0 lost carrier, 0 no carrier, 0 PAUSE output
0 output buffer failures, 0 output buffers swapped out
Eklediğiniz ve ios'larda default olarak gelen alias'ları;çalıştıkları mod'ların altında "show alias" komutuyla listeleyebilirsiniz.
Agciyiz#show aliases
Exec mode aliases:
h help
lo logout
p ping
r resume
s show
u undebug
un undebug
w where
eyvah show interface gigabitEthernet 0/1
Global configuration mode aliases:
eyvah2 do show mac address-table
Bu yazıyı beğendiniz mi?
