Scripting solution for configure a router

amb1s1amb1s1 Member Posts: 408
We have a big project, no for difficulty, but for the amount of branches that we are going to move from DSL to Cable and some ISDN to Cable as backup. These changes happen between 7:30am to 9:00am the time I'm on my way to work. My job has no problem me staying home until I finish those changes and then I can go to work, but there is a problem. My wife and I drive together to save money on gas since I have to staying home, she has to drive to work, something that I don't like.

Now, I was wonder if there is a way to have a TCL script save on the router on the previews night, so I can just use my phone to ssh to the router and do a single command on the router and the script make the changes. We have NCM the configs, but this changes have to be done when the tech finish their work, so there is no way to know at what time to do, and also this a good excuse to learn TCL. Thanks
David G.
http://gomezd.com <
My Tshoot test Blog
http://twitter.com/ipnet255

Comments

  • amb1s1amb1s1 Member Posts: 408
    I found it a way to do it. What I'm going o do is the day before the changes I create specific script that is going o be save on te router. The following code is an example.
    [code]
    proc changes {} {

    iOS_config "interface f0/1" "ip address 10.89.37.2 255.255.255.0" "description cable account#"
    }
    [\code]


    I paste that config on after I type tclsh enter on exec mode. When I want that script to run I just need to type changes and the script would run and for making those changes. I hope this help others.
    David G.
    http://gomezd.com <
    My Tshoot test Blog
    http://twitter.com/ipnet255
  • networker050184networker050184 Mod Posts: 11,962 Mod
    Is your work ok with you making changes from your phone while taking your wife to work? What if something goes wrong? I know I'd be upset if I found out someone was doing this on my network.
    An expert is a man who has made all the mistakes which can be made.
  • pitviperpitviper Member Posts: 1,376 ■■■■■■■□□□
    Is your work ok with you making changes from your phone while taking your wife to work? What if something goes wrong? I know I'd be upset if I found out someone was doing this on my network.

    Yeah, this is the first thing that came to mind while reading the OP. You can do something the same way 99 times without an issue, but if you’re not prepared for the 1 time that something goes awry, you could be up a creek!
    CCNP:Collaboration, CCNP:R&S, CCNA:S, CCNA:V, CCNA, CCENT
  • amb1s1amb1s1 Member Posts: 408
    pitviper wrote: »
    Yeah, this is the first thing that came to mind while reading the OP. You can do something the same way 99 times without an issue, but if you’re not prepared for the 1 time that something goes awry, you could be up a creek!

    All of this devices are non-critical and beside that is a simple config. One interface, two ip route, thats it.
    David G.
    http://gomezd.com <
    My Tshoot test Blog
    http://twitter.com/ipnet255
  • amb1s1amb1s1 Member Posts: 408
    Is your work ok with you making changes from your phone while taking your wife to work? What if something goes wrong? I know I'd be upset if I found out someone was doing this on my network.

    I'm not going to do this while I'm driving. I'm really confortable using ssh on my iphone.
    David G.
    http://gomezd.com <
    My Tshoot test Blog
    http://twitter.com/ipnet255
  • networker050184networker050184 Mod Posts: 11,962 Mod
    amb1s1 wrote: »
    I'm not going to do this while I'm driving. I'm really confortable using ssh on my iphone.

    Well, I'm sure you are comfortable, but is your employer? Seems something silly to get fired over to me.
    An expert is a man who has made all the mistakes which can be made.
  • amb1s1amb1s1 Member Posts: 408
    Well, I'm sure you are comfortable, but is your employer? Seems something silly to get fired over to me.

    My boss know already and like I say, if I mess up for some crazy reason, is not a big deal, I have a tech onsite that can reload the router. I'm not going to do this on a Core, distribution or server devices. I'm not in a financial or Service Provider, those branches are own by us. Those Branches are closed at the time I do the changes and they don't open until 3 hours after I do the changes. believe me I won't fire if I mess up.
    David G.
    http://gomezd.com <
    My Tshoot test Blog
    http://twitter.com/ipnet255
  • amb1s1amb1s1 Member Posts: 408
    Well, I'm sure you are comfortable, but is your employer? Seems something silly to get fired over to me.

    Also, I can't imaging how I'm going to F U that I won't be able to fix it. BTW, Today I did 6 branches with the script, but I was on my house because I want to do a test run, and it work like a charm. Before I put those script, I did a lot of test on my QA Lab. I also did an script to write the script that goes to the router, so the only thing that I can mess up is if I type the wrong ip address and If I do that the only thing that is going to happen is that the Backup would not come up and if that I happen, I should be able to fix it because I'm going to be using the primary, not backup.
    David G.
    http://gomezd.com <
    My Tshoot test Blog
    http://twitter.com/ipnet255
  • networker050184networker050184 Mod Posts: 11,962 Mod
    Hey, if you feel comfortable go ahead. I'm not the one you have to justify it too though. :D
    An expert is a man who has made all the mistakes which can be made.
  • ZartanasaurusZartanasaurus Member Posts: 2,008 ■■■■■■■■■□
    Can you script in a reload in 5, that way you can undo the mistake automatically if you lose the connection?
    Currently reading:
    IPSec VPN Design 44%
    Mastering VMWare vSphere 5​ 42.8%
Sign In or Register to comment.