- Community Home
- >
- Networking
- >
- Legacy
- >
- Switches, Hubs, Modems
- >
- Backup Procurve-Config via SNMP?
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-19-2007 03:27 AM
тАО03-19-2007 03:27 AM
Re: Backup Procurve-Config via SNMP?
1. Set tftp SNMPv2 OID to 2
# snmpset -v 2c -c "RWCOMMUNITY" HOSTNAME 1.3.6.1.4.1.11.2.14.11.5.1.7.1.5.6.0 i 2
2. tftp running config file from switch
# tftp HOSTNAME -c get running-config LOCALFILENAME
3. Reset OID to disable tftp
# snmpset -v 2c -c "RWCOMMUNITY" HOSTNAME 1.3.6.1.4.1.11.2.14.11.5.1.7.1.5.6.0 i 1
Hope that helps,
John
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-19-2009 06:58 AM
тАО02-19-2009 06:58 AM
Re: Backup Procurve-Config via SNMP?
I set in CLI:
setmib 1.3.6.1.4.1.11.2.14.11.5.1.7.1.5.6.0 -i 2
My source 'command-file':
no ip access-list extended "199"
ip access-list extended "199"
permit ip 192.168.1.3 0.0.0.0 0.0.0.0 255.255.255.255
exit
How to put command-file to switch via tftpd?
If i put his then in logs switch:
01/02/90 00:13:11 tftp: SENT error:2, msg: Access violation
Help please.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО02-22-2009 11:42 PM
тАО02-22-2009 11:42 PM
Re: Backup Procurve-Config via SNMP?
I saw serious problems with PCM+ managing a large environment.
Thus I developed a q'n'd bash script, which uses expect and scp. This script backs up all our switch configs (currently >500).
If you like I could give it to you.
Steffen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-10-2009 12:07 AM
тАО03-10-2009 12:07 AM
Re: Backup Procurve-Config via SNMP?
i am looking for an scripted backup solution.
Can you provide us your script PabloFiasko?
We have only Linux server and usually use rsync/scp/mysqldump for our backups.
greetings
Rupertt
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-17-2009 12:03 PM
тАО03-17-2009 12:03 PM
Re: Backup Procurve-Config via SNMP?
I am looking for the exact same thing - script that will pull backup configurations on a large number of Procurves using SCP or SFTP (every 5 days?). If anyone could share the script, i would greatly appreciate.
Thank you,
Evgueni
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-13-2009 01:25 AM
тАО05-13-2009 01:25 AM
Re: Backup Procurve-Config via SNMP?
Please send the script you use for backup.
I've been looking for this.
Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-13-2009 02:02 AM
тАО05-13-2009 02:02 AM
Re: Backup Procurve-Config via SNMP?
You need: a linux box, with perl and expect installed. Maybe you need some additional perl modules.
Copy the following into a file and chmod +x:
<script>
#!/usr/bin/expect -f
#Expect Skript zum automatisierten Abziehen einer Konfig vom HP Switch
#per scp und password auth
#v 0.1 20080630 Steffen M. Steck pablofiasko@gmail.com
#
#Usage ./scpconfigsaver.exp hostname|IP
set user "manager"
set pass "managers_passwd"
set host [lindex $argv 0]
set timeout 60
set date [exec date +%Y%m%d%H%M]
set output "$host\_$date"
set dstdir /home/bkup/hpswitche
proc ssh_failed { } {
send_user "ERROR: SSH LOGIN FAILED\n"
exit
}
proc scp_ok { } {
send_user "SCP SUCCEEDED\n"
}
spawn scp $user@$host:/cfg/running-config $dstdir\/$output.cfg
#check if login is successful and import ssh key if not yet in known_hosts
expect {
"Connection refused" { ssh_failed }
"No route to host" { ssh_failed }
"Permission denied" { ssh_failed }
"bad password." { ssh_failed }
"(yes/no)?" { send "yes\r";
exp_continue }
"password:" { send "$pass\r";
exp_continue }
"Password:" { send "$pass\r";
exp_continue }
"100% " { scp_ok }
default { ssh_failed }
}
wait
expect eof
</script>
This backs up ***one*** switch. Maybe you need to play around with the last two lines "wait" and "expect eof" to get you prompt back. I have been seeing different behaviours on Suse and on Ubuntu. The above sequence works on Suse 9/10/11, it does not on Ubuntu 9.04 - you do not get your prompt back. Don't know why - comments welcome.
If you tried it successfully against a lab switch the only thing you need is all your devices' hostnames or IPs in a file, 1 per line.
Then easily use it like
steffen@T400> for i in `cat devices` ; do ./scpconfigsaver.exp $i ; done
Then have a look at what you set as dstdir, you find files named hostname_datetime.cfg.
Of course this is very basic and does not take care about how many backups are there...
Maybe someone here has time to build something around and share...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-13-2009 03:53 AM
тАО05-13-2009 03:53 AM
Re: Backup Procurve-Config via SNMP?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-13-2009 05:12 AM
тАО05-13-2009 05:12 AM
Re: Backup Procurve-Config via SNMP?
I get this from a Procurve 2626 trying manually.
scp admin@10.0.2.12:/cfg/running-config test.cfg
We'd like to keep you up to date about:
* Software feature updates
* New product announcements
* Special events
Please register your products now at: www.ProCurve.com
admin@10.0.2.12's password:
exec request failed on channel 0
Or in the script:
/root/switch.sh 10.0.2.12
spawn scp admin@10.0.2.12:/cfg/running-config /home/bkup/hpswitche/10.0.2.12_200905131508.cfg
We'd like to keep you up to date about:
* Software feature updates
* New product announcements
* Special events
Please register your products now at: www.ProCurve.com
admin@10.0.2.12's password:
exec request failed on channel 0
ERROR: SSH LOGIN FAILED
Looks like the switch doesn't allow us to get the file.
Software revision H.10.74
SSH terminal works fine.
Any ideas?
/Andreas
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-13-2009 05:53 AM
тАО05-13-2009 05:53 AM
Re: Backup Procurve-Config via SNMP?
My first idea is the switches' config - firmware should be no prob, our switches are all running 10.67 code, most of them 2650B, some 2600-8-PwR, some 2610s...
Do you have
ip ssh
ip ssh filetransfer
in your configs? I think the latter is missing ;-)