1300 11 77 16 [email protected]

OS-X Serial connection to Cisco Console

Update: You may also want to read this after this article…

Ever needed to use a USB to Serial adapter to telnet in to your Cisco Console on a Mac OSX and gone…   Ummm…  I might use a PC instead.  Well fortunately it is way easier than you may think.  It just isn’t quite as intuitive as it should be.

We will assume that you have a USB to Serial adapter that shows up in your /dev after you install it.  You may need to download a driver, and for some chipsets I have not been able to get them running on Intel OS-X (Phillips/MCT chipset in particular.  The Belkin F5U409 is one of these).  I found the UC-232A type which use the Prolific PL2303 chipset, plugged straight in and worked with very little effort and a straight driver download.

Suffice to say if you ls /dev and see a entry like tty.PL2303.xxxxx  all is well.  It is worth copying this to the clip board as you will need it in a moment.

Next comes the wonderful screen command.  Man screen will give you a little more info, albeit, fairly sterile and confusing, but information none the less.  Goolge it to give you a better insight.

Hook your console cable to the USB – Serial adapter and the router and then from a terminal window simply type

screen /dev/<Insert device name here> 9600

(obviously this bit is whatever your device is called) and hey presto,  you are consoled in to your router.

Now it does have some gotchas.  I am used to using <Ctrl>+A to move to the start of the line for when I forget to use “do” or general typos, but <Ctrl>+A is screen‘s primary command.  You issue it prior to all other screen commands.  So for example if you go <Ctrl>+A and start typing do in a screen session, you will only get as far as the d and your screen session will disconnect, as <Ctrl>+A+D is the screen command to disconnect the session.  You will then need to type screen -r to reconnect to the session.

So, it is not a Telnet or even ssh Session.  But it is very useful…

Update:  Grrrr…  I updated my SL MacBook Air to Lion and the Serial Console Cable would no longer work.  See my new article on what I had to do to fix it.

A Lion coughed my Bootcamp partition back up.

Recently I wrote how the Lion upgrade to my beloved iMac 27″ trashed my Boot Camp partition and the ability for VMware to use it.
Well fortunately the fix was fairly straight forward. It seems my pet Lion hadn’t done any such thing. Even though the Boot Camp Assistant reported that there was no Boot Camp partition, and the VMWare Fusion VM said there was no partition, and I could no longer boot into windows @ boot time (don’t ask), good ol’ fsck disagreed with them all.
All I did to remedy the problems was…

  1. In VMWare Fusion 3.1.x I deleted the virtual machine referencing my Boot Camp Partition
  2. In Fusion, open the Virtual Machine Library (??L)
  3. After you have deleted the original VM, click on the Home button to display the setup options
  4. Create a new VM off your Boot Camp Partition (which is still there but hiding after the Lion ate it)
  5. It will now tell you that it is setting up the partition so that VMWare can access it properly.  This seems to be the crucial step!
  6. Hey presto, it is all back and running properly.  You can even boot into the Boot Camp partition again at boot time.

I am not sure what Lion breaks (eats) or why this fixes it exactly as I don’t have time to research it enough, but suffice to say it is working and I am happy again.

A Lion ate my Windows Partition

Apple in all their wisdom sent me a free upgrade to Lion if I purchased a qualifying product after a certain date.

I had so i did.

Buuuzzz!!! Wrong answer.

After the Lion upgrade (which I hate) from Snow Leopard (which I loved), my bootcamp partition is trashed. My VMWare doesn’t work and I am faced with a big recovery job. Fools rush in where angels fear to tread.
Hold off upgrading unless you don’t actually do anything with your Mac.

Update:  Please see this for the solution.

Exchange 2007 EMS- Updating Lists

Frequently I need to update a list in the EMS and invariably I forget how to go about it precisely.

A classic example is needing to update the BypassedSenders in the ContentFilterConfig settings.  So for example say that

Get-ContentFilterConfig reveals that we have 3 email addresses in the BypassedSenders.  [email protected], [email protected], [email protected]  We can either write these down, copy from the screen to notepad or some other clumsy form of recording this info, and then paste it back into our list for the Set-ContentFilterConfig -BypassedSenders [email protected], [email protected], [email protected], [email protected]

But you have to admit.  That sucks a a way to do this fairly common task.  What if you had 30 in there and want ed to add another 4.  Ugly!

The neatest way is probably to use GSEXDEV’s excellent Whitelist GUI script.  This is a great yet simple but of code (script) that for those of you that don’t like playing with a shell, is brilliant.  But I am an old fashioned kind of guy and I like doing this kind of thing  myself (long hand) as it keeps my hand in using the powershell (EMS) and it’s fun, so…

  • Open the EMS (Exchange Management Shell)
  • and assign the entire ContentFilterConfig to a variable
  • check that it has done as expected and look at what is in your BypassedSenders already
  • Typing $BPS.BypassedSenders should show you all email addresses their already.
  • you can now use the .add method to add additional addresses
  • Type $BPS.BypassedSenders again will confirm the added address.
  • Now simply use Set-ContentFilterConfig to write your configuration and you are done.
[PS] C:Ramtech> $BPS = Get-ContentFilterConfig
[PS] C:Ramtech> $BPS.BypassedSenders.Add("[email protected]")
[PS] C:Ramtech> $BPS.BypassedSenderDomains.Add("NewDomain.com")
[PS] C:Ramtech> Set-ContentFilterConfig -BypassedSenders $BPS.BypassedSenders
[PS] C:Ramtech> Set-ContentFilterConfig -BypassedSenderDomains $BPS.BypassedSenderDomains

This will work for any list of course and saves an awful lot of typing.  Particularly if you are using <Tab> completion.  So for example if you type $get-con and hit tab a couple of times you will get the Get-ContentFilterConfig command up with no typos:)  It works with the variables and methods too if you forget the exact syntax.

You can also use the


, as Microsoft suggests, to just store the list you are dealing with but this is a lot more typing as there is no <Tab> word completion due to the necessity to enclose the cmdlet in brackets.  So for geese like me who type at the speed of a thousand startled snails, this is tedious.  The other benefit of dealing with the whole config is, if you want to change other settings at the same time, say BypassedSenderDomains, it’s all there for you already with the benefit of <Tab> completion.  So you could do a

$BPS.BypassedSenders.add("<Bypassed Email Address list>")

and also

$BPS.BypassedSenderDomains.add("<Bypassed Domian list>")

and anything else you wanted updated then just use

Set-ContentFilterConfig $BPS

and update the whole lot if you wanted.

It really is easy once you get the hang of it but if you like neat, use Glen’s GUI.