Mac OS X Utilities:Core Operating System Utilities: USB to Serial Console Connectivity with Kermit
From WWJCDOWiki
Contents |
Description of Solution
This solution covers utilizing a USB to Serial Dongle with Kermit for console connectivity to any device (in this case a Cisco Router). This solution can be duplicated for devices requiring different line speed, flow control or parity settings with 'Kerbang' scripts. It is a simple solution and has helped in many situations.
Technical Requirements of Solution
This solution example assumes:
- The following are installed (links to the applications will be provided at the end):
- Apple Mac OS X
- MacPorts compatible with your version of Mac OS X
- Kermit (installed via MacPorts)
- Open Source PL2303 USB to Serial Driver for Mac OS X
- You have an understanding of Apple Mac OS X, MacPorts (and installing packages within MacPorts) and basic navigation required for utilization of the above applications
- Open up Terminal
- Determine the Device Name of your USB to Serial Device
- Change directory to /opt/local/bin
- Utilize VI to create the following script
- You will be prompted for your Super User password
- Script within VI
- Save your script and Exit VI
- Within VI the following key sequence will Write and Quit VI without prompting
- Set Permissions
- The following command sets the permissions that allow the 'Kerbang' script to be executed from Terminal without Super User access
- Run Script
- Placing the 'Kerbang' script in the /opt/local/bin folder allows you to open up Terminal and type ciscorouter from any folder
- You can create multiple 'Kerbang' scripts for accessing different devices that may require different line speed, flow control or parity settings utilizing the above 'Kerbang' script as an example. It is quite simple and has helped in many situations.
cd /dev ls tty.*
Note: My device name is tty.PL2303-00001004 in this example
cd /opt/local/bin
Note: In this example my script name is 'ciscorouter'
sudo vi ciscorouter
#!/opt/local/bin/kermit set modem type none set line /dev/tty.PL2303-00001004 set speed 9600 set flow none set parity none set carrier-watch off connect Exit
:wq!
sudo chmod 755 ciscorouter
Note: I have not been able to figure out how to use Kermit or any other MacPort application for transferring files (such as Cisco IOS) over to devices via the XMODEM protocol. If you know how to do this please Contact Me via email as I would greatly appreciate your help on this particular subject.
