[rancid] Re: RANCID with HP Procurve 4100g

Mr. James W. Laferriere babydr at baby-dragons.com
Thu May 15 22:52:52 UTC 2008


 	Hello Dan ,

On Wed, 14 May 2008, Mr. James W. Laferriere wrote:
> On Wed, 14 May 2008, Dan Pritts wrote:
>> going through old mail here but it looks like you never got an
>> answer.
>>
>> You have to turn on "autoenable" in your cloginrc file if you are ssh'ing
>> to the switch as an admin user.
> 	With the sessions for switches set to autoenable ,  The 'press any key'
> still haunts getting access to the system .  See below .
> 	Anything I can provide please ask .
> 		Tia ,  JimL
>
> HP J4813A ProCurve Switch 2524
> Software revision F.05.59
>
> Copyright (C) 1991-2007 Hewlett-Packard Co.  All Rights Reserved.
>
>                            RESTRICTED RIGHTS LEGEND
>
>  Use, duplication, or disclosure by the Government is subject to restrictions
>  as set forth in subdivision (b) (3) (ii) of the Rights in Technical Data and
>  Computer Software clause at 52.227-7013.
>
>          HEWLETT-PACKARD COMPANY, 3000 Hanover St., Palo Alto, CA 94303
>
> Press any key to continue
>
> Error: TIMEOUT reached


 	Below is a patch & the patch is also attached ,  NOTE: this is for 
accessing the ProCurve Switch 2524's as the manager account ONLY ,  I will be 
trying to update this as time permits to do the operator -> manager via enable .

 	Mind you the real difficulty is that on 'exit' these devices still 
require you to exit to operator mode & then when you exit that it askes; "Do you 
want to log out [y/n]?" ,  An interesting challenge ,  tho the time out will 
exit the session I'd still like to exit cleanly .

 	Now HOPEFULLy someone knows howto get the ProCurse's <yes curse> to 
return to default mode of the CLI ?  That would make this patch be moot .

 	My Presen problem is ,  Trying to use the '-c "show interfaces 1"' , 
The command is not even get presented to the device command line .  The time out 
happens & session is returned to the user .
 	Anyone have any ideas where this might be going wrong ?
 		Tia ,  JimL

# diff -u flogin.orig-v1.47_20061208 flogin
--- flogin.orig-v1.47_20061208    2008-05-13 14:40:59.000000000 -0800
+++ flogin        2008-05-15 14:19:40.000000000 -0800
@@ -436,6 +436,15 @@
                                   }
                                   exp_continue
                                 }
+	-re "Press any key to continue" {
+						send "\r"
+
+		expect "To select menu item"	{
+							sleep 1
+							send "5"
+						}
+						exp_continue
+					}
         "$prompt"               { break; }
         "Login invalid"         {
                                   send_user "\nError: Invalid login: $router\n";
@@ -444,6 +453,7 @@
       }
      }

+
      set in_proc 0
      return 0
  }
@@ -483,7 +493,7 @@
      global in_proc
      set in_proc 1

-    send "skip-page-display\r"
+    # send "skip-page-display\r"
      expect $prompt {}

      # Is this a multi-command?

-- 
+------------------------------------------------------------------+
| James   W.   Laferriere | System    Techniques | Give me VMS     |
| Network&System Engineer | 2133    McCullam Ave |  Give me Linux  |
| babydr at baby-dragons.com | Fairbanks, AK. 99701 |   only  on  AXP |
+------------------------------------------------------------------+
-------------- next part --------------
--- flogin.orig-v1.47_20061208	2008-05-13 14:40:59.000000000 -0800
+++ flogin	2008-05-15 14:19:40.000000000 -0800
@@ -436,6 +436,15 @@
 				  }
 				  exp_continue
 				}
+	-re "Press any key to continue"	{
+					  send "\r"
+
+		expect "To select menu item"	{
+						sleep 1
+						send "5"
+					}
+					  exp_continue
+					}
 	"$prompt"		{ break; }
 	"Login invalid"		{
 				  send_user "\nError: Invalid login: $router\n";
@@ -444,6 +453,7 @@
      }
     }
 
+
     set in_proc 0
     return 0
 }
@@ -483,7 +493,7 @@
     global in_proc
     set in_proc 1
 
-    send "skip-page-display\r"
+    # send "skip-page-display\r"
     expect $prompt {}
 
     # Is this a multi-command?


More information about the Rancid-discuss mailing list