- Community Home
- >
- Networking
- >
- Switching and Routing
- >
- Web and Unmanaged
- >
- Disable ports from CLI interface on 24 port 1920G ...
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
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
04-07-2016 07:25 AM
04-07-2016 07:25 AM
Disable ports from CLI interface on 24 port 1920G Switch
Hi everyone from Italy !
I'm trying to disable the port state of some of my 24 ports 1920G switch, but I don't find the commands that can do it from CLI interface. Obviously I see how to do it from web interface, but I have to do this function from CLI interface because I'd like to enable, for example, port 1 from a batch file that will be executed prior a backup job on a NAS connected to that port and then, when backup is ended correctly, execute another batch file to disable the same port 1, to automate the connection/disconnection of the NAS and prevent in this way any issue and danger from virus like cryptolocker & C.
I see there is a "_cmdline-mode on" mode for enabling many others command from CLI interface, but I still haven't found what I'm looking for (thank you U2)
Can anyone help me ?
Thank you in advance for the attention !
Robymos
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-05-2016 04:23 AM - edited 07-05-2016 04:26 AM
07-05-2016 04:23 AM - edited 07-05-2016 04:26 AM
Re: Disable ports from CLI interface on 24 port 1920G Switch
Hi Robymos,
Here's how to enable/disable ports using the 1920 CLI...
******************************************************************************
* Copyright (c) 2010-2015 Hewlett-Packard Development Company, L.P. *
* Without the owner's prior written consent, *
* no decompiling or reverse-engineering shall be allowed. *
******************************************************************************
Login authentication
Username:admin
Password:
<SWITCH-00>_cmdline-mode on
All commands can be displayed and executed. Continue? [Y/N]y
Please input password:********************** (password is Jinhua1920unauthorized)
Warning: Now you enter an all-command mode for developer's testing, some command s may affect operation by wrong use, please carefully use it with our engineer's direction.
<SWITCH-00>sys (This enables the configuration commnands, but like 'enable' on cisco)
System View: return to User View with Ctrl+Z.
[SWITCH-00]int g1/0/2
[SWITCH-00-GigabitEthernet1/0/2]shutdown
[SWITCH-00-GigabitEthernet1/0/2]save
The current configuration will be written to the device. Are you sure? [Y/N]:y
Please input the file name(*.cfg)[flash:/startup.cfg]
(To leave the existing filename unchanged, press the enter key):
flash:/startup.cfg exists, overwrite? [Y/N]:y
Validating file. Please wait............
The configuration file flash:/startup.cfg will be automatically backed up as flash:/_startup_bak.cfg for a future version downgrading.
Active main board:...
Backup done.
All backups completed.....
The current configuration is saved to the active main board successfully.
Configuration is saved to device successfully.
To 'enable' a port, the command is 'undo shutdown' ('undo' is the equivalent of prefixing a command with 'no' on cisco)
Hope that helps,
Steve