Mailing List Archive

Nortel/bay routers and rancid
Has anybody been able to use rancid with Nortel routers? I have a BCN and I
have tweaked the configs in all possible ways, but blogin won't go beyond the
login (first level) ... i.e. never kicking in bcc. And - besides that - when
doing blogin, vs. a regular telnet, I cannot log out - I have to CTRL/C the
process.

TIA,
Stef
Nortel/bay routers and rancid [ In reply to ]
Thank you for your answer.

To clarify a little bit: bcc is [a sort of] enable. After one gets the
"regular" prompt, certain things can be carried out from there on, but this
level of CLI is very limited, so additional steps have to be pursued for full
access to configuration, i.e. moving into bcc. Here is how it usually works:

telnet <bay-router>
Login: <username>
Password: <passwd>
<bay>$ bcc <CR>
bcc# --> this is (in my opinion) the equivalent of Cisco's enable ... but I
may be wrong. I was hoping someone has a Bay/Nortel router (really, really
nobody out there?!?), and can confirm my supposition in regards to how far
blogin or do-diff should get into.

I guess the only alternative I have is to look into rancid's code, to see if
the "bcc" assumption is correct, or what else I can do.

Thx again,
Stef

On Thursday 05 June 2003 10:38 pm, you wrote:
> Thu, Jun 05, 2003 at 03:48:53PM -0500, stefmit:
> > Has anybody been able to use rancid with Nortel routers? I have a BCN and
> > I have tweaked the configs in all possible ways, but blogin won't go
> > beyond the login (first level) ... i.e. never kicking in bcc. And -
> > besides that - when doing blogin, vs. a regular telnet, I cannot log out
> > - I have to CTRL/C the process.
>
> i do not have one myself and i dont know what "bcc" is. but, if you get
> logged-in, followed by a prompt and then can not do anything, i would
> suspect that your .cloginrc is misconfigured if the bcn has a concept
> of "enable" (or entering privledged mode).
>
> see the autoenable .cloginrc knob.
Nortel/bay routers and rancid [ In reply to ]
Fri, Jun 06, 2003 at 06:43:17AM -0500, stefmit:
> Thank you for your answer.
>
> To clarify a little bit: bcc is [a sort of] enable. After one gets the
> "regular" prompt, certain things can be carried out from there on, but this
> level of CLI is very limited, so additional steps have to be pursued for full
> access to configuration, i.e. moving into bcc. Here is how it usually works:
>
> telnet <bay-router>
> Login: <username>
> Password: <passwd>
> <bay>$ bcc <CR>
> bcc> configure
> bcc# --> this is (in my opinion) the equivalent of Cisco's enable ... but I
> may be wrong. I was hoping someone has a Bay/Nortel router (really, really
> nobody out there?!?), and can confirm my supposition in regards to how far
> blogin or do-diff should get into.
>
> I guess the only alternative I have is to look into rancid's code, to see if
> the "bcc" assumption is correct, or what else I can do.

a quick look at the code; blogin doesn't use anything.

# blogin - Bay Networks(Nortel) login
#
# Unlike the Cisco's, there is no enable function on the Bay's.
# Instead there are seperate User and Manager accounts. A 'system' command
# exists, which i am told does nothing.

(i didnt write blogin). but it does call the enable() function which
uses 'enable' to get elevated privs and expects the prompt to change
from > to #.

so, this seems kind of buggered. i dont have a bay/nortel (thankfully);
someone who does will have to contribute.

> Thx again,
> Stef
>
> On Thursday 05 June 2003 10:38 pm, you wrote:
> > Thu, Jun 05, 2003 at 03:48:53PM -0500, stefmit:
> > > Has anybody been able to use rancid with Nortel routers? I have a BCN and
> > > I have tweaked the configs in all possible ways, but blogin won't go
> > > beyond the login (first level) ... i.e. never kicking in bcc. And -
> > > besides that - when doing blogin, vs. a regular telnet, I cannot log out
> > > - I have to CTRL/C the process.
> >
> > i do not have one myself and i dont know what "bcc" is. but, if you get
> > logged-in, followed by a prompt and then can not do anything, i would
> > suspect that your .cloginrc is misconfigured if the bcn has a concept
> > of "enable" (or entering privledged mode).
> >
> > see the autoenable .cloginrc knob.
Nortel/bay routers and rancid [ In reply to ]
Here is what I have:

.cloginrc:

add password router password (tried also {password}
add user router user (tried alternatively with the above, {user})
add userprompt {Login:}
# the above is the only one getting me to the $ prompt, all other options
# (e.g. {"Login:"}) leaving me at the Login: prompt!
add autoenable router 1
add userpwassword password
# lqast two lines tried without, with one at a time, with both, etc.

With all five lines above, in the form I have them now, get me as far as the $
prompt, which is one step before the bcc.

When running the suggested:

blogin -c "help" router

I still stop at the $ prompt - no "help" and no logout.

Any ideas of what could be wrong at this level?

Thx,
Stefan

On Friday 06 June 2003 07:03 am, Mark Cooper wrote:
> I did the original port to the Nortel/Bay platform, and brancid will run
> bcc to get the configs. blogin does *not* do a bcc unless told to by
> brancid or a 'blogin -c etc etc'
>
> Can you confirm that blogin can successfully login and run commands? You
> should be able to do something like:-
>
> blogin -c "help" <device>
>
> and it should login to the device, run the help command, and then exit
> without any errors. If it doesn't do this, brancid will not work either :)
>
> I don't have access to any Nortel/Bay devices anymore so i'm a bit
> limited in the support I can provide.
>
> stefmit wrote:
> > Thank you for your answer.
> >
> > To clarify a little bit: bcc is [a sort of] enable. After one gets the
> > "regular" prompt, certain things can be carried out from there on, but
> > this level of CLI is very limited, so additional steps have to be pursued
> > for full access to configuration, i.e. moving into bcc. Here is how it
> > usually works:
> >
> > telnet <bay-router>
> > Login: <username>
> > Password: <passwd>
> > <bay>$ bcc <CR>
> > bcc> configure
> > bcc# --> this is (in my opinion) the equivalent of Cisco's enable ... but
> > I may be wrong. I was hoping someone has a Bay/Nortel router (really,
> > really nobody out there?!?), and can confirm my supposition in regards to
> > how far blogin or do-diff should get into.
> >
> > I guess the only alternative I have is to look into rancid's code, to see
> > if the "bcc" assumption is correct, or what else I can do.
> >
> > Thx again,
> > Stef
> >
> > On Thursday 05 June 2003 10:38 pm, you wrote:
> >>Thu, Jun 05, 2003 at 03:48:53PM -0500, stefmit:
> >>>Has anybody been able to use rancid with Nortel routers? I have a BCN
> >>> and I have tweaked the configs in all possible ways, but blogin won't
> >>> go beyond the login (first level) ... i.e. never kicking in bcc. And -
> >>> besides that - when doing blogin, vs. a regular telnet, I cannot log
> >>> out - I have to CTRL/C the process.
> >>
> >>i do not have one myself and i dont know what "bcc" is. but, if you get
> >>logged-in, followed by a prompt and then can not do anything, i would
> >>suspect that your .cloginrc is misconfigured if the bcn has a concept
> >>of "enable" (or entering privledged mode).
> >>
> >>see the autoenable .cloginrc knob.
Nortel/bay routers and rancid [ In reply to ]
The "$" prompt ? The bay's I've come across usually have a prompt of ">"
which is probably the cause of your problem.

Try the following patch..


--- blogin.ORIG Fri Jun 6 21:12:57 2003
+++ blogin Fri Jun 6 21:13:22 2003
@@ -483,7 +483,7 @@
set prompt "#"
} else {
set autoenable 0
- set prompt ">"
+ set prompt "$"
}
}


stefmit wrote:
> Here is what I have:
>
> .cloginrc:
>
> add password router password (tried also {password}
> add user router user (tried alternatively with the above, {user})
> add userprompt {Login:}
> # the above is the only one getting me to the $ prompt, all other options
> # (e.g. {"Login:"}) leaving me at the Login: prompt!
> add autoenable router 1
> add userpwassword password
> # lqast two lines tried without, with one at a time, with both, etc.
>
> With all five lines above, in the form I have them now, get me as far as the $
> prompt, which is one step before the bcc.
>
> When running the suggested:
>
> blogin -c "help" router
>
> I still stop at the $ prompt - no "help" and no logout.
>
> Any ideas of what could be wrong at this level?
>
> Thx,
> Stefan
>
> On Friday 06 June 2003 07:03 am, Mark Cooper wrote:
>
>>I did the original port to the Nortel/Bay platform, and brancid will run
>>bcc to get the configs. blogin does *not* do a bcc unless told to by
>>brancid or a 'blogin -c etc etc'
>>
>>Can you confirm that blogin can successfully login and run commands? You
>>should be able to do something like:-
>>
>> blogin -c "help" <device>
>>
>>and it should login to the device, run the help command, and then exit
>>without any errors. If it doesn't do this, brancid will not work either :)
>>
>>I don't have access to any Nortel/Bay devices anymore so i'm a bit
>>limited in the support I can provide.
>>
>>stefmit wrote:
>>
>>>Thank you for your answer.
>>>
>>>To clarify a little bit: bcc is [a sort of] enable. After one gets the
>>>"regular" prompt, certain things can be carried out from there on, but
>>>this level of CLI is very limited, so additional steps have to be pursued
>>>for full access to configuration, i.e. moving into bcc. Here is how it
>>>usually works:
>>>
>>>telnet <bay-router>
>>>Login: <username>
>>>Password: <passwd>
>>><bay>$ bcc <CR>
>>>bcc> configure
>>>bcc# --> this is (in my opinion) the equivalent of Cisco's enable ... but
>>>I may be wrong. I was hoping someone has a Bay/Nortel router (really,
>>>really nobody out there?!?), and can confirm my supposition in regards to
>>>how far blogin or do-diff should get into.
>>>
>>>I guess the only alternative I have is to look into rancid's code, to see
>>>if the "bcc" assumption is correct, or what else I can do.
>>>
>>>Thx again,
>>>Stef
>>>
>>>On Thursday 05 June 2003 10:38 pm, you wrote:
>>>
>>>>Thu, Jun 05, 2003 at 03:48:53PM -0500, stefmit:
>>>>
>>>>>Has anybody been able to use rancid with Nortel routers? I have a BCN
>>>>>and I have tweaked the configs in all possible ways, but blogin won't
>>>>>go beyond the login (first level) ... i.e. never kicking in bcc. And -
>>>>>besides that - when doing blogin, vs. a regular telnet, I cannot log
>>>>>out - I have to CTRL/C the process.
>>>>
>>>>i do not have one myself and i dont know what "bcc" is. but, if you get
>>>>logged-in, followed by a prompt and then can not do anything, i would
>>>>suspect that your .cloginrc is misconfigured if the bcn has a concept
>>>>of "enable" (or entering privledged mode).
>>>>
>>>>see the autoenable .cloginrc knob.
>
>

--

Mark Cooper
http://netmangler.sourceforge.net - Network Management with Attitude
http://pvrhw.goldfish.org - Open Source PVR Hardware Database
Nortel/bay routers and rancid [ In reply to ]
Thank you ... didn't work, yet, but you pointed me to the right place, and I
started to play around with it. I need to figure out where you have the "bcc"
part, to see if I can figure it out in conjunction with the "enable" and
prompt sequence.

FYI: the sequence of events (including prompt "history" during the login and
enable processing) is as I explained it in the original message, i.e.:

telnet <my_router> <CR>
prompt is Login: --> <my_username> <CR>
prompt is Password: --> <my_password> <CR>
prompt is $ --> bcc <CR>
prompt is bcc> --> config <CR>
prompt is bcc# --> this is what I could probably call "enable" mode, if I
were to compare it - somehow - with Cisco

So - after logging in succesfully, the sequence of prompts is $, >, then #.

Thanks again for all the help,
Stef

On Friday 06 June 2003 03:42 pm, Mark Cooper wrote:
> The "$" prompt ? The bay's I've come across usually have a prompt of ">"
> which is probably the cause of your problem.
>
> Try the following patch..
>
>
> --- blogin.ORIG Fri Jun 6 21:12:57 2003
> +++ blogin Fri Jun 6 21:13:22 2003
> @@ -483,7 +483,7 @@
> set prompt "#"
> } else {
> set autoenable 0
> - set prompt ">"
> + set prompt "$"
> }
> }
>
> stefmit wrote:
> > Here is what I have:
> >
> > .cloginrc:
> >
> > add password router password (tried also {password}
> > add user router user (tried alternatively with the above, {user})
> > add userprompt {Login:}
> > # the above is the only one getting me to the $ prompt, all other options
> > # (e.g. {"Login:"}) leaving me at the Login: prompt!
> > add autoenable router 1
> > add userpwassword password
> > # last two lines tried without, with one at a time, with both, etc.
> >
> > With all five lines above, in the form I have them now, get me as far as
> > the $ prompt, which is one step before the bcc.
> >
> > When running the suggested:
> >
> > blogin -c "help" router
> >
> > I still stop at the $ prompt - no "help" and no logout.
> >
> > Any ideas of what could be wrong at this level?
> >
> > Thx,
> > Stefan

<snip>
Nortel/bay routers and rancid [ In reply to ]
Minor correction, more for completeness (though irrelevant, as long as the
*prompt* is to be analyzing only the last character):

- after issuing the *config* command, under the *bcc>* prompt, the prompt
changes to *box#*, not *bcc#* ... sorry.

On Saturday 07 June 2003 05:48 am, stefmit wrote:
> Thank you ... didn't work, yet, but you pointed me to the right place, and
> I started to play around with it. I need to figure out where you have the
> "bcc" part, to see if I can figure it out in conjunction with the "enable"
> and prompt sequence.
>
> FYI: the sequence of events (including prompt "history" during the login
> and enable processing) is as I explained it in the original message, i.e.:
>
> telnet <my_router> <CR>
> prompt is Login: --> <my_username> <CR>
> prompt is Password: --> <my_password> <CR>
> prompt is $ --> bcc <CR>
> prompt is bcc> --> config <CR>
> prompt is bcc# --> this is what I could probably call "enable" mode, if I
> were to compare it - somehow - with Cisco
>
> So - after logging in succesfully, the sequence of prompts is $, >, then #.
>
> Thanks again for all the help,
> Stef
>
> On Friday 06 June 2003 03:42 pm, Mark Cooper wrote:
> > The "$" prompt ? The bay's I've come across usually have a prompt of ">"
> > which is probably the cause of your problem.
> >
> > Try the following patch..
> >
> >
> > --- blogin.ORIG Fri Jun 6 21:12:57 2003
> > +++ blogin Fri Jun 6 21:13:22 2003
> > @@ -483,7 +483,7 @@
> > set prompt "#"
> > } else {
> > set autoenable 0
> > - set prompt ">"
> > + set prompt "$"
> > }
> > }
> >
> > stefmit wrote:
> > > Here is what I have:
> > >
> > > .cloginrc:
> > >
> > > add password router password (tried also {password}
> > > add user router user (tried alternatively with the above, {user})
> > > add userprompt {Login:}
> > > # the above is the only one getting me to the $ prompt, all other
> > > options # (e.g. {"Login:"}) leaving me at the Login: prompt!
> > > add autoenable router 1
> > > add userpwassword password
> > > # last two lines tried without, with one at a time, with both, etc.
> > >
> > > With all five lines above, in the form I have them now, get me as far
> > > as the $ prompt, which is one step before the bcc.
> > >
> > > When running the suggested:
> > >
> > > blogin -c "help" router
> > >
> > > I still stop at the $ prompt - no "help" and no logout.
> > >
> > > Any ideas of what could be wrong at this level?
> > >
> > > Thx,
> > > Stefan
>
> <snip>
Nortel/bay routers and rancid [ In reply to ]
Fri, Jun 06, 2003 at 01:57:22PM -0500, stefmit:
> Here is what I have:
>
> .cloginrc:
>
> add password router password (tried also {password}
> add user router user (tried alternatively with the above, {user})
> add userprompt {Login:}
> # the above is the only one getting me to the $ prompt, all other options
> # (e.g. {"Login:"}) leaving me at the Login: prompt!
> add autoenable router 1
> add userpwassword password
> # lqast two lines tried without, with one at a time, with both, etc.
>
> With all five lines above, in the form I have them now, get me as far as the $
> prompt, which is one step before the bcc.

each of these is supposed to have a "target", routername for example.
add password router password (tried also {password}
add user router user (tried alternatively with the above, {user})
add userprompt <routername> {Login:}
# the above is the only one getting me to the $ prompt, all other options
# (e.g. {"Login:"}) leaving me at the Login: prompt!
add autoenable router 1
add userpwassword <username> password
# lqast two lines tried without, with one at a time, with both, etc.

> When running the suggested:
>
> blogin -c "help" router
>
> I still stop at the $ prompt - no "help" and no logout.
>
> Any ideas of what could be wrong at this level?

it's probably waiting to try to match the prompt, which it expects to be
'#'. It should timeout after 45 seconds. but, as the other guy mentioned,
'$' is a strange prompt and of course is not '#'.

again, I dont know much about bay routers. i'd investigate what the prompt
should be by default, according to documentation. afaik, its supposed to be
'#'.

> Thx,
> Stefan
>
> On Friday 06 June 2003 07:03 am, Mark Cooper wrote:
> > I did the original port to the Nortel/Bay platform, and brancid will run
> > bcc to get the configs. blogin does *not* do a bcc unless told to by
> > brancid or a 'blogin -c etc etc'
> >
> > Can you confirm that blogin can successfully login and run commands? You
> > should be able to do something like:-
> >
> > blogin -c "help" <device>
> >
> > and it should login to the device, run the help command, and then exit
> > without any errors. If it doesn't do this, brancid will not work either :)
> >
> > I don't have access to any Nortel/Bay devices anymore so i'm a bit
> > limited in the support I can provide.
> >
> > stefmit wrote:
> > > Thank you for your answer.
> > >
> > > To clarify a little bit: bcc is [a sort of] enable. After one gets the
> > > "regular" prompt, certain things can be carried out from there on, but
> > > this level of CLI is very limited, so additional steps have to be pursued
> > > for full access to configuration, i.e. moving into bcc. Here is how it
> > > usually works:
> > >
> > > telnet <bay-router>
> > > Login: <username>
> > > Password: <passwd>
> > > <bay>$ bcc <CR>
> > > bcc> configure
> > > bcc# --> this is (in my opinion) the equivalent of Cisco's enable ... but
> > > I may be wrong. I was hoping someone has a Bay/Nortel router (really,
> > > really nobody out there?!?), and can confirm my supposition in regards to
> > > how far blogin or do-diff should get into.
> > >
> > > I guess the only alternative I have is to look into rancid's code, to see
> > > if the "bcc" assumption is correct, or what else I can do.
> > >
> > > Thx again,
> > > Stef
> > >
> > > On Thursday 05 June 2003 10:38 pm, you wrote:
> > >>Thu, Jun 05, 2003 at 03:48:53PM -0500, stefmit:
> > >>>Has anybody been able to use rancid with Nortel routers? I have a BCN
> > >>> and I have tweaked the configs in all possible ways, but blogin won't
> > >>> go beyond the login (first level) ... i.e. never kicking in bcc. And -
> > >>> besides that - when doing blogin, vs. a regular telnet, I cannot log
> > >>> out - I have to CTRL/C the process.
> > >>
> > >>i do not have one myself and i dont know what "bcc" is. but, if you get
> > >>logged-in, followed by a prompt and then can not do anything, i would
> > >>suspect that your .cloginrc is misconfigured if the bcn has a concept
> > >>of "enable" (or entering privledged mode).
> > >>
> > >>see the autoenable .cloginrc knob.