Now there’s a lot of help available to you, in the Cisco Command Line Interface
or CLI, the first one to remember is context sensitive help.
Don’t forget that question mark is your friend.
When in doubt, use the question mark to help you,
it’s one of the best places to start.
Type part of the command and press ? to view the various options available to you.
It’s important that you use the ? before asking or looking
for help elsewhere because invariably it’s gonna help you
and don’t forget to read the messages on the screen.
Look at console errors that you receive, this will display for example
incomplete commands or incorrect commands.
I’ve shown a few of those already, if you don’t complete a command as an example.
The router will warn you, if you type the incorrect command
the router will warn you about that.
So in these example, I’ve got cmd prompt open on my windows machine
and I’m gonna telnet to my Cisco router.
So I’m gonna telnet to the IP address of the router.
I’m gonna log in with my password, sh ver
shows me that this is an 1841 Cisco router running advance IP services.
You can see here that it's an 1841 and if I use question mark once again
notice I can see the various options available to me.
If I type conf t notice I'm told that invalid input is detected at the current marker.
If I try and type router ? notice I'm told that this is an unrecognized command.
If I type e question mark (e ?) notice I get the options enable or exit.
en question mark (en?) I get the option enable.
en space question mark (en ?) I can run enable at different privileged levels.
15 are full privileges which will allow me to do anything on the router.
carriage return is enter, so I’m gonna do that option, in this example I’m told to enter
an enable password, so a password has been configured on this router
which requires me to enter it before going to enable or privilege mode.
So I put my password in, lets use this command clock
it's quite a nice one to show you the options.
So if I type clock enter, incomplete command, see question mark
clock is one of the options but if I type c enter, I’m told that it's an ambiguous command.
cl question mark (cl?) there are still 2 matching entries clear or clock.
clo tab, a command can now auto complete, question mark.
I’ve got 3 options here, if I hit enter incomplete command.
Up key or ctrl p to get the previous command back, question mark so I’m gonna use set
as the option, question mark again, in this example I'll set it to 20:00:00 hours
and I'll set it to the first of July 2015 question mark.
Notice at this point I can hit carriage return
if I get rid of the year and hit enter I’m told that's an incomplete command.
Notice the question mark helps me at every step of the way
it’s a good skill to learn, to use question mark and tab.
so if I type c here, tab doesn’t work, co tab doesn’t work, con tab doesn’t work
conf now I get configure, question mark
You want terminal, press tab, so t tab completes the command
Question mark tells me carriage return. Now I’m in global config mode.
Router question mark, various routing protocols are available
let's choose ospf and hit enter.
I'm told it’s not a complete command. I need to specify a process id.
Now I can hit enter or carriage return, now I’m taken to config router mode.
Question mark shows me lots of options available within OSPF.
let’s go for network
I need to put my network command in.
if I enter it as just 10, I'm told that it's incomplete, if I make a crazy
network like that, I'm told it's unrecognized command, so it needs to be valid
I need to put my wildcard mask in, OSPF uses what’s called an inverse mask.
I’m told to put my area in, if I don’t, I'm told it’s an incomplete command.
Hit enter now, incomplete command, so I have to say area and then specify
an area and hit enter, control Zed, takes me back to privilege mode.
The point is get used to using the question mark.
Remember that some commands are valid but you have to be in the right mode.
So if I type, router ospf 1 in privilege mode, that is not an accepted command.
I'm in the wrong mode.
Initially it may be confusing, you believe you're typing a correct command
but the router doesn’t accept it, make sure you're in the right mode.
So just because a command is not accepted doesn’t mean
the command is incorrect, it could simply mean that you’re in the wrong mode.
So check your mode, use question mark to help you and try again.