Ho Siew Fah | 2 Jul 2007 05:21

[rancid] Rancid End Of Run Problem

Hi,

 

I have problem getting the backup configuration for the following router. The below message keeps appearing after I have run the “rancid –d gbon” command. This is a cisco router. This router name is in the router.db file. This problem appears after I have manually removed the gbon router configuration file from the configs directory.

 

gbon: End of run not found

 

Any clues to solve this problem.

 

Thank you.

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
David Luyer | 2 Jul 2007 18:24

[rancid] Re: Rancid End Of Run Problem

> Hi,
>
> I have problem getting the backup configuration for the following
> router. The below message keeps appearing after I have run the "rancid
> -d gbon" command. This is a cisco router. This router name is in the
> router.db file. This problem appears after I have manually removed the
> gbon router configuration file from the configs directory.
>
> gbon: End of run not found
>
> Any clues to solve this problem.

You need to post more of the error.

If that's the only error message, then it's probably getting a 'command
authorization failed' for 'write term' (causes that message without any
skipped command messages), and the patch I sent here recently will stop
the error.

But more likely, you're getting more error messages (such as a list of
skipped commands).  If you look at the first line of the output of the
'rancid -d gbon', it will be a 'clogin ....' line, if you run that, you
will probably be able to spot what is going wrong.

David.

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

Ho Siew Fah | 3 Jul 2007 03:43
Picon

[rancid] Rancid Hung

 
Hi,
 
I encountered rancid hung after running the following command. I need to kill the rancid process in order to exit from this process.
When I put this switch in router.db, I received many rancid hung emails from rancid. Upon checking, I found that the process of this switch hanged which caused my rancid could not be processed properly. I have to remove a lock file from /tmp folder and also this switch from router.db in order not to cause any processing problem for other routers. 
 
I am using expect-5.43.0_3 and rancid-2.3.1_2.
 
Can anybody advise how to stop this process for being hung? I think this process should abort if there is any problem instead of hanging there.
 
Thank you.

[rancid <at> rcd ~]$ /usr/local/libexec/rancid/xrancid -d sngc3-as2.com
executing clogin -t 90 -c "show version;show memory;show diag;show switch;show slot;show configuration detail;show configuration" sngc3-as2.com

sngc3-as2.com clogin error: Error: TIMEOUT reached
sngc3-as2.com clogin error: Error: TIMEOUT reached
can not find channel named "exp4"
    while executing
"close"
    ("foreach" body line 117)
    invoked from within
"foreach router [lrange $argv $i end] {
    set router [string tolower $router]
    send_user "$router\n"

    # Figure out prompt.
    # Since autoena..."
    (file "/usr/sbin/clogin" line 616)

^Csngc3-as2.com: missed cmd(s): show configuration detail,show slot,show configuration,show version,show diag,show memory,show switch
sngc3-as2.com : missed cmd(s): show configuration detail,show slot,show configuration,show version,show diag,show memory,show switch
sngc3-as2.com: End of run not found
sngc3-as2.com: End of run not found

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
Austin Schutz | 3 Jul 2007 09:42

[rancid] Re: Rancid Hung

On Tue, Jul 03, 2007 at 09:43:21AM +0800, Ho Siew Fah wrote:
> Hi,
> 
> I encountered rancid hung after running the following command. I need to
> kill the rancid process in order to exit from this process.
> When I put this switch in router.db, I received many rancid hung emails from
> rancid. Upon checking, I found that the process of this switch hanged which
> caused my rancid could not be processed properly. I have to remove a lock
> file from /tmp folder and also this switch from router.db in order not to
> cause any processing problem for other routers.
> 
> I am using expect-5.43.0_3 and rancid-2.3.1_2.
> 
> Can anybody advise how to stop this process for being hung? I think this
> process should abort if there is any problem instead of hanging there.
> 
> Thank you.
> 

	You are running into the expect bug, and need to patch expect:

http://www.shrubbery.net/rancid/#osystems

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

Ole Hansen - Netic A/S | 3 Jul 2007 10:09
Picon

[rancid] Suppress changes in VLAN-membership

Hi,

We are using MAC-based VLANS (vmps) and switch ports often change vlan
membership. This is discovered by rancid, and I am sent a diff..

Is there any way to suppress this VLAN-information? It means that I get
a lot of config diffs every day - and not only the ones that I would
actually want to see..

Thanks in advance,
Ole Hansen
_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss

Michael Stefaniuc | 3 Jul 2007 11:45
Picon
Favicon

[rancid] Re: Suppress changes in VLAN-membership

Ole Hansen - Netic A/S wrote:
> We are using MAC-based VLANS (vmps) and switch ports often change vlan
> membership. This is discovered by rancid, and I am sent a diff..
> 
> Is there any way to suppress this VLAN-information? It means that I get
> a lot of config diffs every day - and not only the ones that I would
> actually want to see..
Search the archives for "diff". Somebody posted a patch that uses gnu 
diff's "--ignore-matching-lines" option.

bye
	michael
--

-- 
Michael Stefaniuc               Tel.: +49-711-96437-199
Sr. Network Engineer            Fax.: +49-711-96437-111
Red Hat GmbH                    Email: mstefani <at> redhat.com
Hauptstaetterstr. 58            http://www.redhat.de/
D-70178 Stuttgart
_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss

Grégory Ruby | 3 Jul 2007 10:48
Picon

[rancid] upgrade IOS

Hello!

I would like to post a message:


I would like to upgrade IOS of switch 2950 and i would like to do this with Rancid.

There is my commands:
copy tftp: flash:
10.X.X.X
c2950ik6ls......

But there is a problem " Timeout Error " in the logs.

Anybody can help me, please.

bye

_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
Erik Wenzel | 5 Jul 2007 10:11
Picon

[rancid] Re: Suppress changes in VLAN-membership

On Tue, 2007-07-03 at 11:45 +0200, Michael Stefaniuc wrote:
[...]
> > Is there any way to suppress this VLAN-information? It means that I get
> > a lot of config diffs every day - and not only the ones that I would
> > actually want to see..
> Search the archives for "diff". Somebody posted a patch that uses gnu 
> diff's "--ignore-matching-lines" option.
Yes, but that was not working as expected. We ( a buddy and me ) rewrote
that patch. I am preparing a patch for current stable version.

--

-- 
Erik Wenzel <erik <at> code.de>

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

Mark Loveley | 5 Jul 2007 10:35
Favicon

[rancid] Re: ERX bugs in Rancid?


On 17 Jun 2007, at 20:24, john heasley wrote:

Fri, Jun 15, 2007 at 04:11:13PM +0200, Neil Orley:
Hello,

I've just commmented in this line 266 in the clogin file, and now it seems
to work fine with the ERX1440 :

Could you provide more information?  What is the actually output of the
dir command?

For me the problem is in both the commands "show env all" and "dir".

I have been seeing diffs like this for a long time. The differences for "show env all" are:-

  ! power: A ok, B ok
- ! *** srp redundancy: mode is file-system-synchronization        auto-sync
+ ! srp redundancy: mode is file-system-synchronization        auto-sync
  ! enabled, switch-on-error enabled
- ! out of sync (file system)
+ ! in sync
  ! slots: ok

  ! power: A ok, B ok
  ! srp redundancy: mode is file-system-synchronization        auto-sync
  ! enabled, switch-on-error enabled
- ! in sync
+ ! sync in progress
  ! slots: ok

  ! power: A ok, B ok
  ! srp redundancy: mode is high-availability, state active
  !     auto-sync enabled, switch-on-error enabled
- !     sync in progress
+ !     in sync
  ! slots: ok
  !     online: 0 1 7 11 13


And for "dir" are:-

- !Flash: *** Active/standby file systems are not synchronized. ***
- !Flash: Active System Controller:
+ !Flash: active/standby file systems are synchronized
  !Flash:                                     unshared                          in
  !Flash:         file              size        size          date (GMT)        use
  !Flash: ---------------------   ---------   ---------   -------------------   ---
  !Flash: XXXXXXXXXXXXXXXXXXXXX      296984      296984   09/30/2005 03:55:22    !
<at> <at> -107,9 +106,8 <at> <at>
  !Flash: XXXXXXXXXXXXXXXXXXXXX   154139239   137984153   07/29/2005 03:21:34    !
  !Flash: XXXXXXXXXXXXXXXXXXXXX   154263057   138107971   09/30/2005 03:52:32    !
  !Flash: XXXXXXXXXXXXXXXXXXXXX       91388       91388   09/30/2005 03:55:50
  !Flash: Capacity = 1025482752, Bytes Free = 660847516, Reserved = 68157440
- !Flash: Standby System Controller file system is currently unavailable.


- !Flash: *** Active/standby file systems are being synchronized. ***
+ !Flash: Active/standby file systems are synchronized.
  !Flash:                                            unshared
  !Flash:             file                 size        size          date (GMT)
  !Flash: ----------------------------   ---------   ---------   -------------------

- !Flash: Active/standby file systems are synchronized.
- !Flash:                                        unshared                          in
- !Flash:           file               size        size          date (GMT)        use
- !Flash: ------------------------   ---------   ---------   -------------------   ---
- !Flash: disk0:reboot.hty               10624       10624   02/16/2007 04:36:36
- !Flash: disk0:system.log                 171         171   02/16/2007 04:26:18
- !Flash: disk0:XXXXXXXXXX.rel       123538358   122344440   01/26/2007 12:45:58
- !Flash: disk0:XXXXXXXXXX.rel       117722882   116528964   02/16/2007 04:02:28    !
- !Flash: standby-disk0:reboot.hty       14144       14144   02/16/2007 04:33:00
- !Flash: standby-disk0:system.log         882         882   01/29/2007 08:18:20
- !Flash:                   Disk capacity
- !Flash:                   -------------
- !Flash:                   Capacity      Free      Reserved
- !Flash:     Device        (bytes)      (bytes)    (bytes)
- !Flash: --------------   ----------   ---------   --------
- !Flash: disk0:           1047674880   756345387   68157440
- !Flash: standby-disk0:   1047674880   756218546   68157440
+ !Flash: *** Active/standby file systems are being synchronized. ***
+ !Flash:                                    unshared                          in
+ !Flash:         file             size        size          date (GMT)        use
+ !Flash: --------------------   ---------   ---------   -------------------   ---
+ !Flash: disk0:reboot.hty           10624       10624   02/16/2007 04:36:36
+ !Flash: disk0:system.log             171         171   02/16/2007 04:26:18
+ !Flash: disk0:XXXXXXXXXX.rel   123538358   122344440   01/26/2007 12:45:58
+ !Flash: disk0:XXXXXXXXXX.rel   117722882   116528964   02/16/2007 04:02:28    !
+ !Flash:               Disk capacity
+ !Flash:               -------------
+ !Flash:           Capacity      Free      Reserved
+ !Flash: Device    (bytes)      (bytes)    (bytes)
+ !Flash: ------   ----------   ---------   --------
+ !Flash: disk0:   1047674880   756345387   68157440

I have stopped the uninteresting diffs by making chahges to jerancid as below.

In sub DirSlotN  making the following string compare case insensitive obviously helps. As at some point Juniper changed the case in the active/standby text.

        return(-1) if (/active\/standby/i && /not sync/);

In sub ShowEnv these changes have worked for me, it may not be the best way of doing this.

sub ShowEnv {
    print STDERR "    In ShowEnv: $_" if ($debug);
    my $autoSyncEna = 0;                # assume auto-sync is disabled

    while (<INPUT>) {
        tr/\015//d;
        last if (/^$prompt/);
        next if (/^(\s*|\s*$cmd\s*)$/);
        next if (/^Please wait/i);
        return(-1) if (/command authorization failed/i);

        # is autoSync enabled?
        $autoSyncEna =1 if (/enabled, switch-on-error enabled/);        # fileSync mode (text has wrapped)
        $autoSyncEna =1 if (/auto-sync enabled/);                       # HA mode

        # fail if the RP is amid the auto-sync process
        return(-1) if (($autoSyncEna == 1) && (/out of sync \(file system\)/)); # fileSync mode
        return(-1) if (($autoSyncEna == 1) && (/sync in progress/));            # HA mode
#       return(-1) if (/auto-sync enabled/ && !/in sync/);

The last line in the above output is commented as it is not valid on my ERX's as "in sync" and "auto-sync enabled" appear on multiple lines or split across multiple lines (you can see that in the above diff's).

These changes appear to have stopped the uninteresting diffs for me.

HTH
Mark
-- 

| Mark Loveley                                  Broadband Solutions for

| Network Engineer                                    home and business

| PlusNet PLC                                              <at> www.plus.net
| Registered Office: Internet House, 2 Tenter Street, Sheffield, S1 4BY

| Registered in England no: 3279013

+ ------------ PlusNet - The smarter way to broadband ----------------+


_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss
Michael Stefaniuc | 5 Jul 2007 11:07
Picon
Favicon

[rancid] Re: Suppress changes in VLAN-membership

Erik Wenzel wrote:
> On Tue, 2007-07-03 at 11:45 +0200, Michael Stefaniuc wrote:
> [...]
>>> Is there any way to suppress this VLAN-information? It means that I get
>>> a lot of config diffs every day - and not only the ones that I would
>>> actually want to see..
>> Search the archives for "diff". Somebody posted a patch that uses gnu 
>> diff's "--ignore-matching-lines" option.
> Yes, but that was not working as expected. We ( a buddy and me ) rewrote
> that patch. I am preparing a patch for current stable version.
Would you mind posting it to this email list when done? I guess there 
are a couple of people interested.

thanks
bye
	michael
--

-- 
Michael Stefaniuc               Tel.: +49-711-96437-199
Sr. Network Engineer            Fax.: +49-711-96437-111
Red Hat GmbH                    Email: mstefani <at> redhat.com
Hauptstaetterstr. 58            http://www.redhat.de/
D-70178 Stuttgart
_______________________________________________
Rancid-discuss mailing list
Rancid-discuss <at> shrubbery.net
http://www.shrubbery.net/mailman/listinfo.cgi/rancid-discuss


Gmane