2.9. Configuring HTTP

Overview

Function Introduction

This chapter describes how to configure the switch to start the Web management function.

Principle Description

N/A

Configuration

Preparatory

Put a valid web image to flash: directory. Please reference to FTP/TFTP/SCP guide.

Configure HTTP server

step 1 Enter the configure mode

Switch# configure terminal

step 2 Load WEB image

Switch(config)# http server load flash:/webImage.bin

step 3 Configure HTTP server address Optional

Use this step to specify the source address of WEB http server only loopback address is supported. If the source address of WEB http server is specified, it will be the only address to access the WEB. If the source address of WEB http server is not specified, user can access the WEB via the same address as telnet. The route between the device and the client is necessary.

Switch(config)# interface loopback 0
Switch(config-if)# ip address 192.168.1.100/32
Switch(config-if)# quit
Switch(config)# http server source address 192.168.1.100
This operation will cause all the online HTTP(S) users to be offline.
Continue? [yes/no]: yes
Switch(config)# ip route 0.0.0.0/0 192.168.1.1

step 4 Enable HTTP service

Switch(config)# service http enable
This operation will cause all the online HTTP(S) users to be offline.
Continue? [yes/no]: yes

step 5 Exit the configure mode

Switch(config)# exit

step 6 Login the web via the browser

Enter the IP address to login the web.

Application cases

N/A