- Community Home
- >
- Networking
- >
- Legacy
- >
- Switches, Hubs, Modems
- >
- Re: Plink and HP Switches
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
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
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
05-02-2013 06:05 AM
05-02-2013 06:05 AM
Hi all,
I try to create a Script that saves my config to a tftp server. I want to use plink, but if I write a character I get senseless character strings back:
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
←[2J←[?7l←[3;23r←[?6l←[1;1H←[?25l←[1;1HProCurve J8770A Switch 4204vl
Software revision L.11.24
Copyright (C) 1991-2010 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
←[24;1HPress any key to continue←[1;1H←[?25h←[24;27H←[2J←[?7l←[3;23r←[?6l←[24;27
H←[?25h←[24;27H←[?6l←[1;24r←[?7l←[2J←[24;27H←[1;24r←[24;27H←[2J←[?7l←[1;24r←[?6l
←[24;1H←[1;24r←[24;1H←[24;1H←[2K←[24;1H←[?25h←[24;1H←[24;1HLHG-HUB354# ←[24;1H←[
24;13H←[24;1H←[?25h←[24;13H
If I use plink to an Cisco Device everthing works fine...
And please dont tell me that PCM is able to save the configs...
Can somebody help me? Or do you know an alternate scriptable ssh-client.
Solved! Go to Solution.
- Tags:
- escape sequences
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-02-2013 10:20 AM
05-02-2013 10:20 AM
Re: Plink and HP Switches
Well, these are not senseless character strings but good old fashioned ANSI escape codes. CSI (Escape [) 2J is clear screen, for example. Some vendors run their console in vt100 like mode, others a dumb tty. If you're using PuTTY rather than Plink it all works fine. Adding ANSI support is however WONTFIXed in Plink http://www.chiark.greenend.org.uk/~sgtatham/putty/wishlist/plink-terminal.html
RANCID, which is a config management program for routers, uses the hpuifilter tool to strip these codes. It wouldn't be hard to knock together something similar: a few regexps in Powershell or whatever your favourite scripting tool is, should soon see them off. Do you care about the output though if you are using TFTP, rather than parsing the console about as RANCID does?
The other option would be to poke about in the private MIBs rather than script a session. That would be more elegant but probably more work, and less portable. I hope that's not too close to telling you to use PCM.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-06-2013 03:12 AM