Using TIP on Solaris
At my work, I regularly deal with Cisco switches, so I need to use console cables quite frequently. One of the first things I did was configure tip to work through a console cable. This was my first experience with tip and very simple to get working which suprised me because of all the horror stories I’ve heard about using tip. The laptop they bought for me is a Dell Latitude 810 and of course I run Solaris 10 on it (and it runs quite well on it I might add). I’m going to go over some basics of how to get tip working and some neat things I found out about it.
Tips main configuration file is /etc/remote. This file contains all the entries for where you want to connect. If you look at this file there is already pre-defined entries and settings for certain instances:
hardwire::dv=/dev/term/b:br#9600:el=^C^S^Q^U^D:ie=%S:oe=^D
hardwire = profile name
dv = the device
br = baud rate
el = EOL marks
ie = input EOF marks
oe = output EOF string
More options are all explained in the /etc/remote file at the bottom
This shows for the entry “hardware” we want to use the device /dev/term/b which is serial port B, baud rate of 9600, and EOL and EOF marks as shown. On my laptop there is no second serial port so this line is useless. Check your available serial ports in /dev/term. You then connect to this by typing:
# tip hardwire
This is all very simple stuff. So to connect through a console cable to my Cisco switches I used something like:
cisco::dv=/dev/ttya:br#9600:el=^C^S^Q^U^D:ie=%$:oe=^D:
This tells to use the first serial port (COM1) with a baud rate of 9600. I could of also used /dev/term/a instead of /dev/ttya, they are all the same thing.
# tip cisco
connected
Catalyst 1900 Management Console
Copyright (c) Cisco Systems, Inc. 1993-1998
All rights reserved.
Enterprise Edition Software
Ethernet Address: 00-10-14-07-37-80
Model Number: WS-C1924C-A
-------------------------------------------------
1 user(s) now active on Management Console.
User Interface Menu
[M] Menus
[K] Command Line
[I] IP Configuration
If you enter ~? it will tell you the list of available commands you can do through the term.
Enter Selection: ~?
~! shell
~< receive file from remote host
~> send file to remote host
~t take file from remote UNIX
~p put file to remote UNIX
~| pipe remote file
~C connect program to remote host
~c change directory
~. exit from tip
~^D exit from tip
~$ pipe local command to remote host
~^Y suspend tip (local only)
~^Z suspend tip (local+remote)
~s set variable
~? get this summary
~# send break
~
[EOT]
Some of these are mainly for when connecting to other UNIX machines but for switches, one that is really cool is ~! which allows you to exit from the tip, and drops you to the shell, then when you exit the shell it puts you back to tip. Another one I like is the ~> which allows me to put a list of switch commands in a file and then send that file to the terminal which then will execute those commands one by one.