03-User Profile命令
本章节下载: 03-User Profile命令 (118.6 KB)
display user-profile用来显示User Profile的配置信息和在线用户信息。
display user-profile [ session-group ] [ name profile-name ]
IRF模式:
display user-profile [ session-group ] [ name profile-name ] [ slot slot-number ]
session-group:显示Session Group Profile的配置信息和在线用户信息。
name profile-name:表示User Profile的名称,为1~31个字符的字符串,只能包含英文字母[a-z,A-Z]、数字、下划线和小数点,且必须以英文字母开始,区分大小写。User Profile的名称必须全局唯一。如果未指定本参数,将显示所有User Profile的配置信息和在线用户信息。
slot slot-number:显示User Profile的配置信息和指定成员设备的在线用户信息,slot-number表示设备在IRF中的成员编号。如果未指定本参数,将显示User Profile的配置信息和所有成员设备的在线用户信息。
# 显示在名称为aaa的User Profile配置信息及被授权该User Profile的在线用户信息。(独立运行模式)
<Sysname> display user-profile name aaa
User-Profile: aaa
Inbound:
CIR 33 (kbps), CBS 2062 (Bytes), EBS 0 (Bytes), PIR 888 (kbps)
Policy: p1
Outbound:
CIR 33 (kbps), CBS 2062 (Bytes), EBS 0 (Bytes), PIR 888 (kbps)
Policy: p2
Connection-limit amount: 1000
Connection-limit rate: 100
Authentication-free rule:
acl 3000
acl name flow1
acl ipv6 3000
acl ipv6 name flow2
User user_1:
Authentication type: 802.1X
Network attributes:
Interface : GigabitEthernet1/0/1
MAC address : 0000-1111-2222
Failed action list:
Inbound: Policy p1
Inbound: CIR 33 (kbps), CBS 2062 (Bytes), EBS 0 (Bytes), PIR 888 (kbps)
Connection-limit rate: 100
User user_2:
Authentication type: Portal
Network attributes:
Interface : GigabitEthernet1/0/3
IP address : 172.16.187.16
VPN : N/A
Service VLAN : 100
# 显示2号成员设备上的Session Group Profile配置信息及被授权该Session Group Profile的在线用户信息。(IRF模式)
<Sysname> display user-profile session-group slot 2
Session-Group-Profile: aaa
Outbound:
CIR 33 (kbps), CBS 2062 (Bytes), EBS 0 (Bytes), PIR 888 (kbps)
QMProfile: a
User user_1:
Authentication type: 802.1X
Network attributes:
Interface : Ethernet1/2/0/1
MAC address : 0000-1111-2222
Failed action list:
Outbound: CIR 33 (kbps), CBS 2062 (Bytes), EBS 0 (Bytes), PIR 888 (kbps)
QMProfile: a
User user_2:
Authentication type: Portal
Network attributes:
Interface : GigabitEthernet1/0/3
IP address : 172.16.187.16
VPN : N/A
Service VLAN : 100
Session-Group-Profile: bbb
Outbound:
CIR 512 (kbps), CBS 1062 (Bytes), EBS 0 (Bytes), PIR 888 (kbps)
QMProfile: a
User user_4:
Authentication type: Portal
Network attributes:
Interface : GigabitEthernet1/0/2
IP address : 172.16.187.166
VPN : N/A
Service VLAN : 100
表1-1 表1-1 display user-profile 命令显示信息描述表
Authentication-free rule |
User Profile免认证规则 |
与User Profile或Session Group Profile关联的用户信息 |
|
free-rule命令用来配置User Profile免认证规则。
undo free-rule命令用来删除User Profile免认证规则。
【命令】
free-rule acl [ ipv6 ] { acl-number | name acl-name }
undo free-rule acl [ ipv6 ] { acl-number | name acl-name }
【缺省情况】
不存在User Profile免认证规则。
【视图】
User Profile视图
【缺省用户角色】
network-admin
mdc-admin
【参数】
ipv6:指定ACL类型为IPv6 ACL。如果未指定本参数,则表示IPv4 ACL。
acl-number:指定ACL的编号,取值范围及其代表的ACL类型如下:
· 2000~2999:表示基本ACL。
· 3000~3999:表示高级ACL。
name acl-name:指定ACL的名称。acl-name表示ACL的名称,为1~63个字符的字符串,不区分大小写,必须以英文字母a~z或A~Z开头。
【使用指导】
配置User Profile免认证规则后,当用户上线认证失败或者用户欠费时,允许用户访问免认证规则中指定的目的地址。
一个User Profille下可以配置多条免认证规则。
【举例】
# 在名称为user的User Profile下配置ACL编号为3000的免认证规则。
<Sysname> system-view
[Sysname] user-profile user
[Sysname-user-profile-user] free-rule acl 3000
# 在名称为user的User Profile下配置IPv6 ACL编号为3000的免认证规则。
<Sysname> system-view
[Sysname] user-profile user
[Sysname-user-profile-user] free-rule acl ipv6 3000
# 在名称为user的User Profile下配置ACL名称为a1的免认证规则。
<Sysname> system-view
[Sysname-user-profile-user] free-rule acl name a1
【相关命令】
· acl(ACL和Qos命令参考/ACL)
qos queue命令用来在User Profile中为会话指定进入的队列。
undo qos queue命令用来取消配置。
qos queue { queue-id | queue-name }
User Profile下没有指定进入的队列。
queue { queue-id | queue-name }:让应用此user profile的会话进入指定队列,queue-id表示队列序号,queue-name表示队列名称。
若指定进入的队列对应的是四队列调度策略,则可以配置的队列序号范围是0~3,超出范围则配置失败,不会进入指定队列。
应用此命令可以为对多个会话指定不同的队列从而决定其不同优先级的调度方式。
queue-id和queue-name的对应情况如表1-2所示。
表1-2 queue-id数字和关键字对应表
queue-id数字 |
queue-id关键字 |
# 在名称为user的User Profile中,指定会话进入队列7。
[Sysname] user-profile user
[Sysname-user-profile-user] qos queue 7
qos session-group identify命令用来在接口下配置会话组识别方式。
undo qos session-group identify命令用来取消会话组识别方式的配置。
qos session-group identify { customer-vlan | service-vlan | customer-service-vlan | subscriber-id }
undo qos session-group identify
customer-vlan:按内层VLAN识别会话组,内层VLAN为用户的私网VLAN。
service-vlan:按外层VLAN识别会话组,外层VLAN为运营商分配给用户的公网VLAN。
customer-service-vlan:按内层VLAN和外层VLAN识别会话组。
subscriber-id:按subscriber id识别会话组。
若要配置Session Group Profile,则必须首先指定会话组的识别方式。
#在接口GigabitEthernet1/0/1上配置基于外层vlan的会话组识别方式。
[Sysname] interface gigabitethernet 1/0/1
[Sysname-GigabitEthernet1/0/1] qos session-group identify service-vlan
user-profile命令用来创建User Profile或Session Group Profile并进入相应的视图
undo user-profile命令用来删除指定的User Profile。
user-profile profile-name [ type session-group ]
undo user-profile profile-name
profile-name:表示User Profile的名称,为1~31个字符的字符串,只能包含英文字母[a-z,A-Z]、数字、下划线和小数点,且必须以英文字母开始,区分大小写。User Profile的名称必须全局唯一。
type session-group:指定创建的类型为Session Group Profile。
如果指定名称的User Profile或Session Group Profile已存在,则直接进入该User Profile或Session Group Profile的视图。
User Profile的名称必须全局唯一。
# 创建名称为a123的User Profile,并进入其视图。
[Sysname] user-profile a123
# 创建名称为a123的Session Group Profile,并进入其视图。
[Sysname] user-profile a123 type session-group
[Sysname-session-group-profile-a123]
不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!