I’ve been using a Mac for quite a while as a systems administrator/network administrator. I don’t run into many people that use OSX for their daily machines as administrators, but I think that OS androgyny is more ubiquitous, so I think its apt to write an article on using screen to pick up the serial connection.
First, you need to get a usb/serial cable so that you can use that old Cisco Rollover Cable. I picked up one from NewEgg that fit the bill. I made sure it had the PL2303 chipset for nice cross platform compatibility.
Second, you can find an easy way out of this by using software such as SecureCRT that will do all the work for you.
So, plug in that cable to the Mac and the Switch and lets get working!
Open the ‘Terminal’ app and take a look at your USB devices by typing,
ls /dev/tty\.*
When my device was plugged in I had an additional ‘/dev/tty.usbserial’
We’ll simply
screen /dev/tty.usbserial
;
This will drop you into screen. How do you use screen?
Quick helpful commands:
help is ctrl+a ?
kill a screen session is ‘screen -ls’ then screen -X -S {session#} quit
detach a screen ctrl+a d
resume a screen
Here is a bit more about screen than you ever wanted to know.
If you want to get really fancy, here is a .screenrc file that I use:
hardstatus alwayslastline hardstatus string '%{= kG}[ %{G}%H %{g}][%= %{=kw}%?%-Lw%?%{r}(%{W}%n*%f%t%?(%u)%?%{r})%{w}%?%+Lw%?%?%= %{g}][%{B}%Y-%m-%d %{W}%c %{g}]' vbell off defscrollback 5000
To use this file, from the Terminal type
vi /Users/{username}/.screenrc
Get into INSERT mode by pressing ‘:i’
and paste normally with cmd+v
Don’t forget to have fun.