Priority assignment depending on the directions [Документация VAS Experts]

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:dpi:dpi_options:opt_priority:priority_config_as [2020/02/05 17:30] – ↷ Page moved from en:dpi:dpi_options:base_functionality:opt_priority:priority_config_as to en:dpi:dpi_options:opt_priority:priority_config_as lexx26en:dpi:dpi_options:opt_priority:priority_config_as [2025/01/16 10:39] (current) – [Priority assignment depending on the directions] elena.krasnobryzh
Line 1: Line 1:
-====== Assignment of priorities vs directions ======+====== Priority assignment depending on the directions ====== 
 +{{indexmenu_n>4}} 
 +The direction is defined by a number of an autonomous system that sends or receives the traffic.  
 +:!: The direction priority specified for autonomous system (if defined) overrides the priority specified by protocol. 
 +:!: The direction priority specified for the traffic's source (if defined) overrides the priority specified for the destination.
  
 +<note important>One can change the IP list that belongs to an autonomous system and define an auxiliary autonomous system dynamically. It is described in the section [[en:dpi:dpi_options:opt_statistics:statistics_asn|Configuring autonomous systems]]</note>
 +
 +The direction dependent priorities assigned by the system's administrator, are loaded by DPI from the file **/etc/dpi/asnum.dscp.**
 +
 +<note warning>Comments in this file are not allowed!</note>
 +
 +This file is created in two steps. First, the text file with a list of autonomous systems and their assigned priorities is created. Next, this file is converted into an internal format by a dedicated utility.
 +
 +<note tip>''asnum.bin'' — a directory of public autonomous systems and subnets that can be updated from the cloud. To enable directory updates, add the parameter ''asnum_download=1'' to the configuration file ''/etc/dpi/fastdpi.conf''. By default, updates are disabled (''asnum_download=0'').</note>
 +===== File format of autonomous systems' list and their priorities: =====
 +
 +Each line of the file contains: AS_number <space> dscp_value. **For example:**
 +<code>
 +64512       cs0
 +64512       local
 +64513       drop
 +64514       pass
 +64514       peer
 +</code>
 +  * Here cs0 - is [[en:dpi:dpi_options:opt_priority:dscp_table|DSCP value]].\\ 
 +
 +Keywords meaning:
 +  * drop – means that packets have not to be transmitted: they must be dropped.
 +  * pass – the traffic of this autonomous system must go through DPI with no analysis and processing.
 +  * local – the traffic of this system is treated as a local operator's one, see [[en:dpi:bras_bng:general_setup#fastdpi_l3_bras_setup|BRAS L3]]
 +  * peer – the operator is in peering state with this system; used only for [[en:dpi:dpi_options:opt_cache|Cache option]]
 +  * term – termination is allowed for this AS; see [[en:dpi:bras_bng:bras_l2_vlan_term:bras_l2_vlan_term_as|BRAS: AS termination]]
 +  * mark1 – Prioritize SNI detection in custom signatures for autonomous systems.\\ Control from the cloud. 
 +  * mark2 – QUIC traffic without SNI from this AS will be marked as QUIC_UNKNOWN_MARKED\\ Example:\\  
 +    * in asnum.dscp ASN 15169 mark as mark2 
 +    * in protocols.dscp mark QUIC_UNKNOWN_MARKED drop
 +  * mark3 — reserved
 +
 +<note important>local, term and peer do not effect the traffic's priority and are used for services. They are described there.</note>
 +
 +===== File convertation =====
 +
 +To convert this file into the internal format and to place it into the working directory for DPI usage:
 +<code>cat my_as_dscp.txt|as2dscp /etc/dpi/asnum.dscp
 +service fastdpi reload
 +</code>
 +<note important>This configuration is loaded on the run, with no need to restart the servic</note>
 +<note>**[SSG v13+]** it is now possible to add comments (#) and empty lines in input files of as2dscp utility.</note>
 +
 +===== Configuration for local traffic =====
 +To allow the transit of local operator traffic through the DPI without analysing and processing:
 +<code>local_passthrough=1</code>
 +
 +To place the local operator traffic in a separate class:
 +<code>local_dscp=0x38</code> 
 +dscp is set in a numerical form, the [[en:dpi:dpi_options:opt_priority:dscp_table|reference table]] provides correspondence between the numeric and letter symbols.\\ 
 +
 +<note important>local_dscp setting takes precedence over the local_passthrough (if both are specified, the local_dscp is active)</note>
 +
 +Autonomous system traffic within its class [[en:dpi:dpi_options:opt_bandwidth_mgmt:bandwidth_conf|can be limited]] regardless of the basic service plan limitation.