参考文档: 3gpp ts 23.203-be0 条款6.3
策略与计费控制规则(PCC Rule),即一系列相关信息与一系列相关操作的集合,通常包含3大类信息:
其中:服务数据流指,利用PCC规则中的业务数据流模板进行检测的分组数据;
PCC规则可以分为两类:
动态PCC规则通过PCRF的Gx下发给PCEF执行,PCRF可以建立、修改、删除这类规则;预定义PCC规则由PCEF预配,PCRF只能引用这类规则;
PCC规则如下表所示:
注意: 同一个P-CAN会话中PCC规则ID标识符是唯一的;如果动态PCC规则与预定义PCC规则相同,则后者将被前者覆盖(替换);
PCC业务数据流模板(PCC Service Data Flow Template)可能包含任何数目的业务数据流过滤器(Service Data Flow Filter);
PCC优先顺序(PCC Precedence)定义了在PCEF中进行服务数据流检测时,同一个IP-CAN会话中已激活的PCC规则的执行先后顺序;
特别声明: 其余指标说明请参考相关文档[SR_68-2010_策略和计费控制(PCC)系统技术研究]
PCC规则运行主要指:
激活
激活的PCC规则
注意:
<?xml version='1.0' encoding='UTF-8' ?>
<PolicyDef xmlns='http://www.yota.ru/shemes/rules' version='1'>
<Policy Name="online_charging">
<Default>
<AddToCCA>
<Online Value="ENABLE_ONLINE" />
<Offline Value="DISABLE_OFFLINE" />
</AddToCCA>
<AddToRAR>
<Online Value="ENABLE_ONLINE" />
<Offline Value="DISABLE_OFFLINE" />
</AddToRAR>
</Default>
</Policy>
<Policy Name="failover">
<Default>
<AddToCCA_I>
<CC-Session-Failover Value="FAILOVER_SUPPORTED" />
</AddToCCA_I>
</Default>
</Policy>
<!-- this is policy for users w/o any policy " -->
<Policy Name="Default">
<CiscoSCE PackageInstall="0" Real_Time_Monitor="1"/>
<Default>
<QoSes>
<QoS-Information>
<APN-Aggregate-Max-Bitrate-DL Value="2048000"/>
<APN-Aggregate-Max-Bitrate-UL Value="2048000"/>
</QoS-Information>
<Default-EPS-Bearer-QoS>
<QoS-Class-Identifier Value="QCI_6"/>
<Allocation-Retention-Priority>
<Priority-Level Value="1"/>
<Pre-emption-Capability Value="PRE_EMPTION_CAPABILITY_ENABLED"/>
<Pre-emption-Vulnerability Value="PRE_EMPTION_VULNERABILITY_DISABLED"/>
</Allocation-Retention-Priority>
</Default-EPS-Bearer-QoS>
</QoSes>
</Default>
</Policy>
<Policy Name="Limited">
<CiscoSCE PackageInstall="1" Real_Time_Monitor="1"/>
<Default>
<QoSes>
<QoS-Information>
<APN-Aggregate-Max-Bitrate-DL Value="64000"/>
<APN-Aggregate-Max-Bitrate-UL Value="64000"/>
</QoS-Information>
<Default-EPS-Bearer-QoS>
<QoS-Class-Identifier Value="QCI_6"/>
<Allocation-Retention-Priority>
<Priority-Level Value="1"/>
<Pre-emption-Capability Value="PRE_EMPTION_CAPABILITY_ENABLED"/>
<Pre-emption-Vulnerability Value="PRE_EMPTION_VULNERABILITY_DISABLED"/>
</Allocation-Retention-Priority>
</Default-EPS-Bearer-QoS>
</QoSes>
</Default>
</Policy>
<Policy Name="Turbo">
<CiscoSCE PackageInstall="2" Real_Time_Monitor="1"/>
<Default>
<QoSes>
<QoS-Information>
<APN-Aggregate-Max-Bitrate-UL Value="10240000"/>
<APN-Aggregate-Max-Bitrate-DL Value="10240000"/>
</QoS-Information>
<Default-EPS-Bearer-QoS>
<QoS-Class-Identifier Value="QCI_6"/>
<Allocation-Retention-Priority>
<Priority-Level Value="1"/>
<Pre-emption-Capability Value="PRE_EMPTION_CAPABILITY_ENABLED"/>
<Pre-emption-Vulnerability Value="PRE_EMPTION_VULNERABILITY_DISABLED"/>
</Allocation-Retention-Priority>
</Default-EPS-Bearer-QoS>
</QoSes>
<Rules>
<Charging-Rule-Base-Name Value="Turbo"/>
<Charging-Rule-Name Value="Turbo_1"/>
<Charging-Rule-Name Value="Turbo_2"/>
</Rules>
</Default>
</Policy>
<Policy Name="VideoTurbo">
<Default>
<Rules>
<Charging-Rule-Definition>
<Charging-Rule-Name Value="video_turbo"/>
<Service-Identifier Value="5"/>
<Rating-Group Value="8"/>
<Flow-Description Value="permit in ip from any to 10.2.44.215"/>
<Flow-Description Value="permit out ip from 10.2.44.215 to any"/>
<Flow-Status Value="ENABLED"/>
<QoS-Information>
<QoS-Class-Identifier Value="QCI_7"/>
<Max-Requested-Bandwidth-UL Value="8192000"/>
<Max-Requested-Bandwidth-DL Value="8192000"/>
<Guaranteed-Bitrate-UL Value="8192000"/>
<Guaranteed-Bitrate-DL Value="8192000"/>
<Allocation-Retention-Priority>
<Priority-Level Value="1"/>
<Pre-emption-Capability Value="PRE_EMPTION_CAPABILITY_DISABLED"/>
<Pre-emption-Vulnerability Value="PRE_EMPTION_VULNERABILITY_ENABLED"/>
</Allocation-Retention-Priority>
</QoS-Information>
<Precedence Value="1"/>
</Charging-Rule-Definition>
</Rules>
</Default>
</Policy>
<Policy Name="Default_IOT">
<CiscoSCE PackageInstall="3" Real_Time_Monitor="1"/>
<Default>
<QoSes>
<QoS-Information>
<APN-Aggregate-Max-Bitrate-UL Value="2048000"/>
<APN-Aggregate-Max-Bitrate-DL Value="2048000"/>
</QoS-Information>
<Default-EPS-Bearer-QoS>
<QoS-Class-Identifier Value="QCI_6"/>
<Allocation-Retention-Priority>
<Priority-Level Value="1"/>
<Pre-emption-Capability Value="PRE_EMPTION_CAPABILITY_ENABLED"/>
<Pre-emption-Vulnerability Value="PRE_EMPTION_VULNERABILITY_DISABLED"/>
</Allocation-Retention-Priority>
</Default-EPS-Bearer-QoS>
</QoSes>
<Rules>
<Charging-Rule-Definition>
<Charging-Rule-Name Value="iot"/>
<Service-Identifier Value="211"/>
<Rating-Group Value="211"/>
<Flow-Description Value="permit in ip from any to any"/>
<Flow-Description Value="permit out ip from any to any"/>
<Reporting-Level Value="SERVICE_IDENTIFIER_LEVEL"/>
<Metering-Method Value="VOLUME"/>
<Online Value="ENABLE_ONLINE"/>
<Offline Value="DISABLE_OFFLINE"/>
<Flow-Status Value="ENABLED"/>
<QoS-Information>
<QoS-Class-Identifier Value="QCI_6"/>
<Max-Requested-Bandwidth-UL Value="2048000"/>
<Max-Requested-Bandwidth-DL Value="2048000"/>
<Guaranteed-Bitrate-UL Value="2048000"/>
<Guaranteed-Bitrate-DL Value="2048000"/>
<Allocation-Retention-Priority>
<Priority-Level Value="6"/>
<Pre-emption-Capability Value="PRE_EMPTION_CAPABILITY_DISABLED"/>
<Pre-emption-Vulnerability Value="PRE_EMPTION_VULNERABILITY_DISABLED"/>
</Allocation-Retention-Priority>
</QoS-Information>
<Precedence Value="0"/>
</Charging-Rule-Definition>
</Rules>
</Default>
</Policy>
<HuaweiAccums>
<!-- This is special accum used only for per location usage monitoring -->
<Accum Name="CONGESTION">
<Monitoring-Key Name="congestion" Direction="Downlink" Delta="1000000" Monitor-Level="SESSION" />
</Accum>
</HuaweiAccums>
<DefaultAccums>
<!-- please don't delete this accum. It used for perfomance tests -->
<Accum Name="perf_accum_test">
<Monitoring-Key Name="test_mkey" Direction="Downlink" Delta="1000000"/>
</Accum>
<Accum Name="perf_accum_D">
<Monitoring-Key Name="test_mkey" Direction="Uplink" Delta="500000"/>
</Accum>
<Accum Name="perf_accum_M">
<Monitoring-Key Name="test_mkey2" Direction="Both" Delta="100000"/>
</Accum>
<Accum Name="general">
<Monitoring-Key Name="up_mkey" Direction="Uplink" Delta="1000000"/>
<Monitoring-Key Name="down_mkey" Direction="Downlink" Delta="1000000"/>
</Accum>
<Accum Name="general_up">
<Monitoring-Key Name="general_mkey" Direction="Uplink" Delta="1000000"/>
</Accum>
<!-- please don't delete this accum. It used in FreePCRF image -->
<Accum Name="general_down">
<Monitoring-Key Name="general_mkey" Direction="Downlink" Delta="1000000"/>
</Accum>
</DefaultAccums>
<ProceraAccums>
<Accum Name="perf_accum_test">
<Monitoring-Key Name="test_mkey" Direction="Downlink" Delta="1000000"/>
</Accum>
</ProceraAccums>
</PolicyDef>
注: 规则模板的说明请参考freePCRF手册文档:《Telexir PCRF 3.5.2 Policy Library.pdf》