SSH Wrapper Script

SSH Wrapper Script

Ok — this is my first script that I’m posting here. Its a VERY simple ssh wrapper script that you can place in your path, preferably in ~/bin

bash
#!/bin/bash
SSH="/usr/bin/ssh"
case "$*" in
 *'@'*)     $SSH $* ;;
 *' -l'*)     $SSH $* ;;
 *)         $SSH -l root $* ;;
 esac

What this allows us to do is ssh as root to another box w/o specifying a user. Very handy if you spend your life in a terminal as I do. This could also be easily modifed for use with SCP or anything you wish…

comments powered by Disqus

Related Posts

Networking Field Day 2

Networking Field Day 2

Have you heard the news? You’re least favorite blogger is making the trip to San Jose California for Tech Field Day: Network Field Day 2 — I really want to add a dramatic movie …

The OpenFlow Symposium

The OpenFlow Symposium

Well, here is the update that I promised you. I’ve spent the last few days with some of the top minds in Networking industry. One of the most exciting technologies being presented …

Cisco ISR 4000 – Now with more licensing!

Cisco ISR 4000 – Now with more licensing!

This week at Interop NYC, Cisco launched it’s ISR 4000 Series. This is a new approach for them focused on delivering services to your branch offices. Cisco has dubbed this new …