Discussion:
[rancid] Issue with rancid and Juniper devices
Agustin Roca
2013-01-14 14:36:00 UTC
Permalink
Getting Timeout after login.

rancid]$ jlogin -d -c 'get system version' ar-device


expect: does "Telmex:AR-BADC-FS140-01(M)-> " (spawn_id exp6) match regular
expression "(\r\n|\n)"? no
"^[^ ]+>"? yes
expect: set expect_out(0,string) "Telmex:AR-BADC-FS140-01(M)->"
expect: set expect_out(spawn_id) "exp6"
expect: set expect_out(buffer) "Telmex:AR-BADC-FS140-01(M)->"
send: sending "set cli complete-on-space off\r" to { exp6 }

expect: does " " (spawn_id exp6) match regular expression
"Telmex:AR-BADC-FS140-01(M)-[#>]"? no
set cli complete-on-space off
^------unknown keyword cli
Telmex:AR-BADC-FS140-01(M)->
expect: does " set cli complete-on-space
off\r\n ^------unknown keyword
cli\r\nTelmex:AR-BADC-FS140-01(M)-> " (spawn_id exp6) match regular
expression "Telmex:AR-BADC-FS140-01(M)-[#>]"? no
expect: timed out

Error: TIMEOUT reached
write() failed to write anything - will sleep(1) and retry...


My cloginrc for that device is:
add user ar-* rancid
add password ar-* {passwd}
add method * ssh
add autoenable ar-* 1

Any hint will be aprreciated.

[image: Loading Image...]<http://www.globant.com/>

*Agustin Roca*
GIST Information Security Analyst
CEHv7

AR: +54 11 4109 1700 ext. 8098
Mobile: +15 5022 3042
***@globant.com

[image: Loading Image...]
*Having the right people is more important than having the right tools.
“Having the right people” requires hiring the right people, investing in
them, and retaining them – three processes we often get wrong.*
Kieran Murphy
2013-01-15 10:13:25 UTC
Permalink
Judging by that device prompt, it looks like you're trying to login to a
Netscreen device.

So you'll need to use device type netscreen, which uses nrancid and nlogin
Post by Agustin Roca
Getting Timeout after login.
rancid]$ jlogin -d -c 'get system version' ar-device
expect: does "Telmex:AR-BADC-FS140-01(M)-> " (spawn_id exp6) match regular
expression "(\r\n|\n)"? no
"^[^ ]+>"? yes
expect: set expect_out(0,string) "Telmex:AR-BADC-FS140-01(M)->"
expect: set expect_out(spawn_id) "exp6"
expect: set expect_out(buffer) "Telmex:AR-BADC-FS140-01(M)->"
send: sending "set cli complete-on-space off\r" to { exp6 }
expect: does " " (spawn_id exp6) match regular expression
"Telmex:AR-BADC-FS140-01(M)-[#>]"? no
set cli complete-on-space off
^------unknown keyword cli
Telmex:AR-BADC-FS140-01(M)->
expect: does " set cli complete-on-space
off\r\n ^------unknown keyword
cli\r\nTelmex:AR-BADC-FS140-01(M)-> " (spawn_id exp6) match regular
expression "Telmex:AR-BADC-FS140-01(M)-[#>]"? no
expect: timed out
Error: TIMEOUT reached
write() failed to write anything - will sleep(1) and retry...
add user ar-* rancid
add password ar-* {passwd}
add method * ssh
add autoenable ar-* 1
Any hint will be aprreciated.
[image: http://www.globant.com/images/globant_130x25.gif]<http://www.globant.com/>
*Agustin Roca*
GIST Information Security Analyst
CEHv7
AR: +54 11 4109 1700 ext. 8098
Mobile: +15 5022 3042
[image: http://www.globant.com/images/pxtransp.gif]
*Having the right people is more important than having the right tools.
“Having the right people” requires hiring the right people, investing in
them, and retaining them – three processes we often get wrong.*
_______________________________________________
Rancid-discuss mailing list
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
Agustin Roca
2013-01-15 12:28:09 UTC
Permalink
Yes! i did that yesterday while and it worked. I tried to answer my own
mail but didnt get it.

Thanks for the reply!

[image: http://www.globant.com/images/globant_130x25.gif]<http://www.globant.com/>

*Agustin Roca*
GIST Information Security Analyst
CEHv7

AR: +54 11 4109 1700 ext. 8098
Mobile: +15 5022 3042
***@globant.com

[image: http://www.globant.com/images/pxtransp.gif]
*Having the right people is more important than having the right tools.
“Having the right people” requires hiring the right people, investing in
them, and retaining them – three processes we often get wrong.*
Post by Kieran Murphy
Judging by that device prompt, it looks like you're trying to login to a
Netscreen device.
So you'll need to use device type netscreen, which uses nrancid and nlogin
Post by Agustin Roca
Getting Timeout after login.
rancid]$ jlogin -d -c 'get system version' ar-device
expect: does "Telmex:AR-BADC-FS140-01(M)-> " (spawn_id exp6) match
regular expression "(\r\n|\n)"? no
"^[^ ]+>"? yes
expect: set expect_out(0,string) "Telmex:AR-BADC-FS140-01(M)->"
expect: set expect_out(spawn_id) "exp6"
expect: set expect_out(buffer) "Telmex:AR-BADC-FS140-01(M)->"
send: sending "set cli complete-on-space off\r" to { exp6 }
expect: does " " (spawn_id exp6) match regular expression
"Telmex:AR-BADC-FS140-01(M)-[#>]"? no
set cli complete-on-space off
^------unknown keyword cli
Telmex:AR-BADC-FS140-01(M)->
expect: does " set cli complete-on-space
off\r\n ^------unknown keyword
cli\r\nTelmex:AR-BADC-FS140-01(M)-> " (spawn_id exp6) match regular
expression "Telmex:AR-BADC-FS140-01(M)-[#>]"? no
expect: timed out
Error: TIMEOUT reached
write() failed to write anything - will sleep(1) and retry...
add user ar-* rancid
add password ar-* {passwd}
add method * ssh
add autoenable ar-* 1
Any hint will be aprreciated.
[image: http://www.globant.com/images/globant_130x25.gif]<http://www.globant.com/>
*Agustin Roca*
GIST Information Security Analyst
CEHv7
AR: +54 11 4109 1700 ext. 8098
Mobile: +15 5022 3042
[image: http://www.globant.com/images/pxtransp.gif]
*Having the right people is more important than having the right tools.
“Having the right people” requires hiring the right people, investing in
them, and retaining them – three processes we often get wrong.*
_______________________________________________
Rancid-discuss mailing list
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
Loading...