Forgot password?
 Register now

Welcome to use this form to feedback your problems with Ruijie Community

The category of your feedback

Your Feedback

Your Email address (optional):

How to configure port security on CLI for Ruijie Series Switch? Reply

GTAC-Sophia

Level 5

Ruijie Staff

How to configure port security on CLI for Ruijie Series Switch?
1981 0 2023-7-11 17:36:55
Original
Requirement:
1.
PC1(IP: 192.168.1.1,MAC: 0021.CCCF.6F70)canonly connect to access switch F0/1,and configure IP+MAC binding other PC conenct to this port cannot be accessed when connected to this port;
2. F0/2port can only allow ip address 192.168.1.2 access to the internet, MAC address is not limited other ip address cannot access internet when connected to this port.
Topology:
\

Configuration tips:
On ports F0/1 and F0/2, you need to enable switchport port-security and limit MAC address binding entries to 1
Configuration Steps:
>Requirement 1:
In core switch:

Ruijie>en
Ruijie#config ter
Ruijie(config)#vlan 10
Ruijie(config)#interface vlan 10
Ruijie(config-if-VLAN 10)#ip address 192.168.1.254255.255.255.0      --->Create the IP address of the core device, that is, the gateway address of the user

Ruijie(config-if-VLAN 10)#end
Ruijie#wr    ---> save the configuration

In access switch:

Ruijie>enable   
Ruijie#configure terminal
Ruijie(config)#interface fast Ethernet 0/1                                   

Ruijie(config-if-Fast Ethernet 0/1)#switchportport-security binding 0021.CCCF.6F70 vlan10 192.168.1.1   ---->   Bind the PC whose mac address is0021.CCCF.6F70 and ip address is 192.168.1.1 to the fastEthernet 0/1 port onthe switch

Ruijie(config-if-FastEthernet 0/1)#switchportport-security  ------>enableport security function

Ruijie(config-if-FastEthernet 0/1)#exit
Ruijie#write       ---> save the configuration

>Requirement 2:
Ruijie(config)#interfac fastEthernet 0/2
Ruijie(config-if-FastEthernet 0/2)# switchportport-security binding 192.168.1.2  ------>Bindthe PC whose ip address is 192.168.1.2 to the fastEthernet 0/2 port on the switch

Ruijie(config-if-FastEthernet 0/2)#switchportport-security  ------>enableport security function

Ruijie(config-if-FastEthernet 0/2)#end
Ruijie#write    ---> save the configuration

Verification:
Ruijie#show port-security address


RG-S5300-24GT2SFP2XS-E

Configuration Switch
There are no replies.
Related Posts
Product Model

Share this topic to

Cancel

This site contains user submitted content, comments and opinions and is for informational purposes only. Ruijie may provide or recommend responses as a possible solution based on the information provided; every potential issue may involve several factors not detailed in the conversations captured in an electronic forum and Ruijie can therefore provide no guarantee as to the efficacy of any proposed solutions on the community forums. Ruijie disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Ruijie Community Terms of Use.

More ways to get help: Visit Support Videos, call us via Service Hotline, Facebook or Live Chat.

©2000-2023 Ruijie Networks Co,Ltd