[rancid] Mikrotik Router Backups

248 views
Skip to first unread message

Eric Merkel (Mail Lists)

unread,
Jun 15, 2009, 5:08:17 PM6/15/09
to rancid-...@shrubbery.net
I've patched rancid 2.3.2 to handle mikrotik router backups per the following thread http://www.gossamer-threads.com/lists/rancid/users/3826
 
The new program mtlogin seems to work ok. However when I run /usr/local/rancid/bin/mtlogin -c" system package print detail;system routerboard print;system license print;export" 10.11.9.1 it pauses after login waiting for the command prompt and spits out some special characters  ^[[?6c^[[36;3R. Once it detects the login prompt it runs the previous commands showing the configs etc as it should then at the very end says "interrupted" and quits.
 
When the rancid-run process runs I get the following errors.
 
Trying to get all of the configs.
10.11.9.1: missed cmd(s): system routerboard print
=====================================
Getting missed routers: round 1.
10.11.9.1: missed cmd(s): system routerboard print
=====================================
Getting missed routers: round 2.
10.11.9.1: missed cmd(s): system routerboard print
=====================================
Getting missed routers: round 3.
10.11.9.1: missed cmd(s): system routerboard print
=====================================
Getting missed routers: round 4.
10.11.9.1: missed cmd(s): system routerboard print
If you are not familiar with Mikrotik, it has a command line interface although some of the text is color coded. I am wondering if these special characted codes could be causing the issue. If not where do I start looking? Thanks!
 
===
Eric Merkel
ejmerke...@gmail.com

Chris Boot

unread,
Jun 16, 2009, 2:04:42 PM6/16/09
to Eric Merkel, rancid-...@shrubbery.net
Eric,

You need to make sure '+ct' is on the end of your username. This
disables colour (+c) and autodetection (+t). See http://www.mikrotik.com/download/CHANGELOG_3
for more details, under "What's new in 3.0rc14".

HTH,
Chris

> _______________________________________________
> Rancid-discuss mailing list
> Rancid-...@shrubbery.net
> http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss

--
Chris Boot
bo...@bootc.net
_______________________________________________
Rancid-discuss mailing list
Rancid-...@shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss

Eric Merkel (Mail Lists)

unread,
Jun 30, 2009, 7:57:32 PM6/30/09
to Chris Boot, rancid-...@shrubbery.net
Chris,

I've finally gotten back to looking at this and the +ct seems to have helped
expect to properly parse the login info. However, I am still having the
issue of rancid geting the error "missed cmd(s): system routerboard print",
etc when rancid runs from cron. However if I run rancid-run from the command
line it seems to work fine. Any clue what might cause that? Am I missing an
environment variable or something?

I appreciate all your help this far!

===
Eric Merkel
ejmerke...@gmail.com

Reply all
Reply to author
Forward
0 new messages