[go: up one dir, main page]

CN104022897B - Limit the method that interchanger order executes speed - Google Patents

Limit the method that interchanger order executes speed Download PDF

Info

Publication number
CN104022897B
CN104022897B CN201410225085.3A CN201410225085A CN104022897B CN 104022897 B CN104022897 B CN 104022897B CN 201410225085 A CN201410225085 A CN 201410225085A CN 104022897 B CN104022897 B CN 104022897B
Authority
CN
China
Prior art keywords
speed
switch
interchanger
command
critical value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201410225085.3A
Other languages
Chinese (zh)
Other versions
CN104022897A (en
Inventor
王伟
车任秋
黄小飞
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai Mingyao Supply Chain Technology Co ltd
Original Assignee
Shanghai Feixun Data Communication Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai Feixun Data Communication Technology Co Ltd filed Critical Shanghai Feixun Data Communication Technology Co Ltd
Priority to CN201410225085.3A priority Critical patent/CN104022897B/en
Publication of CN104022897A publication Critical patent/CN104022897A/en
Application granted granted Critical
Publication of CN104022897B publication Critical patent/CN104022897B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Computer And Data Communications (AREA)

Abstract

本发明提出了一种限制交换机命令执行速度的方法,包括设置交换机执行命令速度的临界值;计算出交换机执行命令的当前速度;判断当前速度是否超过所述临界值,如果是,则交换机系统管理模块停止向业务模块发送命令,如果否,交换机系统管理模块继续向业务模块发送命令。本发明设置交换机执行命令速度的临界值,即交换机系统执行命令的速度的上限。如果管理模块接收到的命令的速度超过临界值,则停止发送命令给业务模块处理,以缓解系统的压力,避免出现交换机系统遭受破坏、卡机、程序错误跳转、死机等严重情况。

The present invention proposes a method for limiting the command execution speed of the switch, including setting the critical value of the command execution speed of the switch; calculating the current speed of the command execution of the switch; judging whether the current speed exceeds the critical value, and if so, the switch system management The module stops sending commands to the service module, if not, the switch system management module continues to send commands to the service module. The invention sets the critical value of the command execution speed of the switch, that is, the upper limit of the command execution speed of the switch system. If the command speed received by the management module exceeds the critical value, it will stop sending commands to the business module for processing, so as to relieve the pressure on the system and avoid serious situations such as damage to the switch system, machine jams, program error jumps, and crashes.

Description

限制交换机命令执行速度的方法How to limit the execution speed of switch commands

技术领域technical field

本发明涉及一种限制交换机命令执行速度的方法。The invention relates to a method for limiting the command execution speed of a switch.

背景技术Background technique

交换机系统的管理模块是负责处理用户输入的命令,然后进行解析。在获取到命令的信息之后,如果命令正确,将发往命令对应的业务模块,再由业务模块进行业务处理。业务模块处理完成之后,根据处理的结果会对管理模块进行应答。正确执行的命令管理模块会收到正确应答。The management module of the switch system is responsible for processing the commands input by the user and then analyzing them. After obtaining the command information, if the command is correct, it will be sent to the business module corresponding to the command, and then the business module will perform business processing. After the business module is processed, it will respond to the management module according to the processing result. Correctly executed commands will receive correct responses from the management module.

如图1所示,命令的执行需要两次发送,两次等待接收应答的过程。即:1、用户输入命令,再等待管理模块的应答;2、管理模块接收命令处理后发送给业务模块,再等待业务模块执行并接收应答;3、业务模块收到命令处理后并应答管理模块,最后管理模块再应答给用户。As shown in Figure 1, the execution of the command needs to be sent twice, and the process of waiting for the response to be received twice. That is: 1. The user enters a command, and then waits for the response from the management module; 2. The management module receives the command and processes it and sends it to the business module, and then waits for the business module to execute and receive the response; 3. The business module responds to the management module after receiving the command and processing it , and finally the management module responds to the user.

现在,常存在的一个问题就是用户高频率地输入命令,还没有等到业务模块返回应答就很快地发出第二条及后面大量的命令,这使得管理模块和业务模块间的通信产生严重的阻塞以及业务模块超负荷运行,最终会影响到其他业务程序的运行,严重地会导致交换机系统程序错乱、甚至出现死机的问题。Now, a common problem is that users input commands frequently, and before the business module returns a response, they quickly issue the second and a large number of subsequent commands, which causes serious congestion in the communication between the management module and the business module. And the overloaded operation of the business module will eventually affect the operation of other business programs, which will seriously cause the program of the switch system to be disordered or even crash.

发明内容Contents of the invention

本发明需解决的技术问题是提供一种缓解交换机系统的压力的限制交换机命令执行速度的方法。The technical problem to be solved by the present invention is to provide a method for alleviating the pressure of the switch system and limiting the execution speed of switch commands.

为解决上述的技术问题,本发明设计了一种限制交换机命令执行速度的方法,包括以下步骤:设置交换机执行命令速度的临界值;计算出交换机执行命令的当前速度;判断当前速度是否超过所述临界值,如果是,则交换机系统管理模块停止向业务模块发送命令,如果否,交换机系统管理模块继续向业务模块发送命令。In order to solve the above-mentioned technical problems, the present invention designs a method for limiting the command execution speed of the switch, comprising the following steps: setting the critical value of the command execution speed of the switch; calculating the current speed of the command execution of the switch; judging whether the current speed exceeds the Critical value, if yes, the switch system management module stops sending commands to the service module, if not, the switch system management module continues to send commands to the service module.

作为本发明进一步改进,所述限制交换机命令执行速度的方法还包括将当前速度超过所述临界值的情况反馈给用户的步骤。As a further improvement of the present invention, the method for limiting the execution speed of the switch command further includes a step of feeding back to the user that the current speed exceeds the critical value.

作为本发明进一步改进,如果当前速度超过所述临界值,交换机系统管理模块还做出返回处理操作。As a further improvement of the present invention, if the current speed exceeds the critical value, the switch system management module also makes a return processing operation.

作为本发明进一步改进,所述计算出交换机执行命令的当前速度的步骤包括以下步骤:利用计数器计数管理模块接收到命令,得到接收命令的数值;获取到交换机系统的系统时钟;重复以上两个步骤,用新的系统时钟减去旧的系统时钟,折算出耗时,用新的接收命令的数值减去旧的接收命令的数值,折算出耗时过程中接收到的命令的数值之差,然后利用耗时过程中接收到的命令的数值之差和耗时计算出交换机执行命令的当前速度。As a further improvement of the present invention, the step of calculating the current speed of the switch to execute the command includes the following steps: use the counter to count the management module to receive the command, and obtain the value of the received command; obtain the system clock of the switch system; repeat the above two steps , Subtract the old system clock from the new system clock to calculate the time-consuming, subtract the value of the old received command from the value of the new received command, calculate the difference between the values of the commands received during the time-consuming process, and then The current speed at which the switch executes the command is calculated by using the difference between the numerical values of the commands received during the time-consuming process and the time-consuming process.

作为本发明进一步改进,在交换机的用户配置界面命令行设置临界值。As a further improvement of the present invention, the critical value is set on the command line of the user configuration interface of the switch.

本发明设置交换机执行命令速度的临界值,即交换机系统执行命令的速度的上限。如果管理模块接收到的命令的速度超过临界值,则停止发送命令给业务模块处理,以缓解系统的压力,避免出现交换机系统遭受破坏、卡机、程序错误跳转、死机等严重情况。The invention sets the critical value of the command execution speed of the switch, that is, the upper limit of the command execution speed of the switch system. If the command speed received by the management module exceeds the critical value, it will stop sending commands to the business module for processing, so as to relieve the pressure on the system and avoid serious situations such as damage to the switch system, machine jams, program error jumps, and crashes.

附图说明Description of drawings

图1是现有技术命令执行流程示意图;FIG. 1 is a schematic diagram of a prior art command execution flow;

图2为本发明限制交换机命令执行速度的方法的流程示意图。Fig. 2 is a schematic flowchart of a method for limiting the execution speed of a switch command in the present invention.

具体实施方式Detailed ways

为了使本领域相关技术人员更好地理解本发明的技术方案,下面将结合本发明实施方式的附图,对本发明实施方式中的技术方案进行清楚、完整地描述,显然,所描述的实施方式仅仅是本发明一部分实施方式,而不是全部的实施方式。In order to enable those skilled in the art to better understand the technical solutions of the present invention, the following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments It is only a part of the embodiments of the present invention, but not all of them.

本发明提供了一种限制交换机命令执行速度的方法,用于限制交换机系统的业务模块出现超负荷处理命令的情况。最大程度保护交换机的系统,免遭受到破坏,避免出现卡机、程序错误跳转、死机等严重问题,确保交换机安全运行。The invention provides a method for limiting the command execution speed of the switch, which is used to limit the situation that the business modules of the switch system are overloaded to process commands. Protect the system of the switch to the greatest extent from being damaged, avoid serious problems such as machine jams, program error jumps, and crashes, and ensure the safe operation of the switch.

如图2所示,本实施例限制交换机命令执行速度的方法,包括以下几个步骤:As shown in Figure 2, the method for limiting the command execution speed of the switch in this embodiment includes the following steps:

步骤1:设置交换机执行命令速度的临界值的步骤,设置临界值是在交换机的用户配置界面的命令行中执行,从而为用户提供命令接口,所述临界值可根据交换机不同的处理能力而设置成不同的值。Step 1: The step of setting the critical value of the command execution speed of the switch. Setting the critical value is performed in the command line of the user configuration interface of the switch, so as to provide the user with a command interface. The critical value can be set according to the different processing capabilities of the switch into different values.

步骤2:计算出交换机执行命令的当前速度。在本实施例中,计算交换机执行命令的当前速度的方法包括:先利用计数器计数管理模块接收到命令,得到接收命令的数值;再获取到交换机系统的系统时钟(tich数);重复以上两个步骤,即得到两组数据,旧的接收命令的数值和新的接收命令的数值、旧的系统时钟和新的系统时钟,用新的系统时钟减去旧的系统时钟,折算出耗时,用新的接收命令的数值减去旧的接收命令的数值,折算出耗时过程中接收到的命令的数值之差,然后利用耗时过程中接收到的命令的数值之差和耗时计算出交换机执行命令的当前速度。本发明计数器计数得到接收命令的数值以及获取到交换机系统的系统时钟(tich数)一直在重复循环,上述新旧两组数据也在实时更新,因而,计算得到的交换机执行命令的当前速度也在不停地更新。Step 2: Calculate the current speed at which the switch executes the command. In this embodiment, the method for calculating the current speed at which the switch executes the command includes: first using the counter to count the management module to receive the command, and obtain the numerical value of the received command; then obtain the system clock (tich number) of the switch system; repeat the above two steps The step is to obtain two sets of data, the value of the old command received and the value of the new command received, the old system clock and the new system clock, subtract the old system clock from the new system clock, convert the time consumption, and use Subtract the value of the new received command from the value of the old received command to convert the value difference of the command received during the time-consuming process, and then use the value difference of the command received during the time-consuming process and the time-consuming to calculate the switch The current speed at which the command is executed. The counter of the present invention obtains the value of the command received and the system clock (tich number) obtained by the switch system has been repeating the cycle, and the above-mentioned two groups of old and new data are also updated in real time. Therefore, the calculated current speed of the switch to execute the command is also constant. Keep updating.

步骤3:当得到交换机执行命令的当前速度之后,即可判断当前速度是否超过所述临界值,如果是,则交换机系统管理模块停止向业务模块发送命令,并执行返回操作,从而可为业务模块减轻负担;如果否,交换机系统管理模块继续向业务模块发送命令,即,交换机执行命令的当前速度未超过所述临界值,证明业务模块还处于能承受处理命令的能力范围之内,因而,按照正常程序,交换机系统管理模块会将命令发送给业务模块,由业务模块执行处理。Step 3: After obtaining the current speed at which the switch executes the command, it can be judged whether the current speed exceeds the critical value, if so, the switch system management module stops sending commands to the service module, and performs a return operation, so that the service module can Reduce the burden; if not, the switch system management module continues to send commands to the service module, that is, the current speed at which the switch executes the command does not exceed the critical value, which proves that the service module is still within the capacity of being able to handle the command. Therefore, according to In a normal procedure, the switch system management module will send the command to the service module, and the service module will execute the processing.

在本实施例中,当交换机执行命令的当前速度超过所述临界值时,管理模块还会将这种情况反馈给用户,起到预警作用,用户获悉后,即可暂停输入或延缓输入命令。In this embodiment, when the current speed at which the switch executes commands exceeds the critical value, the management module will also feed back this situation to the user to serve as an early warning. After the user is informed, the input of the command can be suspended or delayed.

使用本发明限制交换机命令执行速度的方法,命令的执行过程是:首先,用户在交换机上输入命令,由管理模块接收命令,如果当前速度超过临界值,则管理模块返回、停止向业务模块发送命令,从而缓解业务模块的压力,同时,管理模块还会将此情况应答给用户,让用户知悉情况。如果当前速度未超过临界值,管理模块按照正常程序,向业务模块发送命令,业务模块接收到命令执行处理,然后根据处理的结果应答给管理模块,管理模块再应答给用户。Using the method of the present invention to limit the command execution speed of the switch, the execution process of the command is: first, the user inputs the command on the switch, the command is received by the management module, if the current speed exceeds the critical value, the management module returns and stops sending commands to the service module , so as to relieve the pressure on the business module, and at the same time, the management module will also respond to this situation to the user to let the user know the situation. If the current speed does not exceed the critical value, the management module sends a command to the business module according to the normal procedure, the business module receives the command and performs processing, and then responds to the management module according to the processing result, and the management module then responds to the user.

以上仅表达了本发明的一种实施方式,其描述较为具体和详细,但并不能因此而理解为对本发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本发明构思的前提下,还可以做出若干变形和改进,这些都属于本发明的保护范围。因此,本发明专利的保护范围应以所附权利要求为准。The above only expresses one embodiment of the present invention, and its description is relatively specific and detailed, but it should not be construed as limiting the patent scope of the present invention. It should be pointed out that those skilled in the art can make several modifications and improvements without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent for the present invention should be based on the appended claims.

Claims (4)

1. a kind of method that limitation interchanger order executes speed, which is characterized in that include the following steps:
The critical value that interchanger executes command speed is set;
Calculate the exectorial present speed of interchanger;
Judge whether present speed exceeds the critical value, if it is, switch system management module stops to business module Order is sent, is ordered if not, switch system management module continues to send to business module;
Described the step of calculating interchanger exectorial present speed, includes the following steps:
Order is received using beta ray detector reason module, obtains the numerical value for receiving order;
Get the system clock of switch system;
Two above step is repeated, old system clock is subtracted with new system clock, is converted into time-consuming, is taken orders with new Numerical value subtract the old numerical value to take orders, be converted into the difference of the numerical value of the order received in time-consuming process, then utilize The difference of the numerical value of the order received in time-consuming process calculates the exectorial present speed of interchanger with time-consuming.
2. the method that limitation interchanger order according to claim 1 executes speed, which is characterized in that the limitation exchanges The method that machine order executes speed further includes the steps that present speed is fed back to user more than the case where critical value.
3. the method that limitation interchanger order according to claim 1 executes speed, which is characterized in that if present speed More than the critical value, switch system management module also makes return processing operation.
4. the method that limitation interchanger order according to claim 1 executes speed, which is characterized in that in the use of interchanger Critical value is arranged in family configuration interface order line.
CN201410225085.3A 2014-05-26 2014-05-26 Limit the method that interchanger order executes speed Active CN104022897B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410225085.3A CN104022897B (en) 2014-05-26 2014-05-26 Limit the method that interchanger order executes speed

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410225085.3A CN104022897B (en) 2014-05-26 2014-05-26 Limit the method that interchanger order executes speed

Publications (2)

Publication Number Publication Date
CN104022897A CN104022897A (en) 2014-09-03
CN104022897B true CN104022897B (en) 2018-09-28

Family

ID=51439480

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410225085.3A Active CN104022897B (en) 2014-05-26 2014-05-26 Limit the method that interchanger order executes speed

Country Status (1)

Country Link
CN (1) CN104022897B (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101299719A (en) * 2008-06-04 2008-11-05 北京星网锐捷网络技术有限公司 Detection processing method for data flow, central processing unit and switch

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6658367B2 (en) * 2001-03-28 2003-12-02 Hewlett-Packard Development Company, L.P. System for time-bucketing of baselined data collector data
CN101600174A (en) * 2009-06-30 2009-12-09 中兴通讯股份有限公司 Flow control method and device in file processing
CN103812687B (en) * 2012-11-15 2017-12-15 华为技术有限公司 The means of defence and equipment of processor

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101299719A (en) * 2008-06-04 2008-11-05 北京星网锐捷网络技术有限公司 Detection processing method for data flow, central processing unit and switch

Also Published As

Publication number Publication date
CN104022897A (en) 2014-09-03

Similar Documents

Publication Publication Date Title
JP7237110B2 (en) FAILURE PREDICTION METHOD, DEVICE, ELECTRONIC EQUIPMENT, STORAGE MEDIUM, AND PROGRAM
US10430260B2 (en) Troubleshooting method, computer system, baseboard management controller, and system
CN102681909B (en) A kind of server method for early warning based on EMS memory error
US20180079078A1 (en) Robot simulation device
CN104426696B (en) A kind of method of troubleshooting, server and system
US9699509B2 (en) Alternate video processing on backup virtual machine due to detected abnormalities on primary virtual machine
US10452402B2 (en) Operation instruction response control method and terminal for human-machine interface
WO2020211253A1 (en) Elastic scaling method and apparatus for number of hosts in distributed system, and computer device
CN107391344A (en) A kind of event-monitoring method, platform and system
CN102591658A (en) Method and device for processing message
CN105511937A (en) Batch virtual machine blue screen monitoring method suitable for cloud platform
CN103676727A (en) Preemptible and nestable interrupt control method based on embedded chip
CN110673976A (en) Anomaly detection method and anomaly detection device for multi-core system and electronic equipment
CN111078387B (en) Interrupt aggregation device and method thereof
CN112306567A (en) Cluster management system and container management and control method
US20170091630A1 (en) Information processing device, analysis method, and program recording medium
CN104022897B (en) Limit the method that interchanger order executes speed
CN108279595B (en) Method, apparatus and equipment group for controlling the state of an equipment group
CN104486149B (en) A kind of finite state machine method for ground test
CN104899088B (en) A kind of message treatment method and device
US20140317254A1 (en) Management computer, automated operation procedure output method, and computer-readable storage medium
US9619045B1 (en) User input source identification based on delayed input
CN105376091A (en) System and method for offline server
US12022314B2 (en) Quality of service measurement method and device, and user plane function entity
CN107665163B (en) Method and system for automatic data backtracking

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
EXSB Decision made by sipo to initiate substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20201110

Address after: Room 10242, No. 260, Jiangshu Road, Xixing street, Binjiang District, Hangzhou City, Zhejiang Province

Patentee after: Hangzhou Jiji Intellectual Property Operation Co.,Ltd.

Address before: 201616 Shanghai city Songjiang District Guangfulin road 4855 Lane 20, No. 90

Patentee before: Phicomm (Shanghai) Co.,Ltd.

EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20140903

Assignee: Hangzhou xiaobuzhixue Information Technology Co.,Ltd.

Assignor: Hangzhou Jiji Intellectual Property Operation Co.,Ltd.

Contract record no.: X2021330000454

Denomination of invention: Method of limiting command execution speed of switch

Granted publication date: 20180928

License type: Common License

Record date: 20211019

EE01 Entry into force of recordation of patent licensing contract
EE01 Entry into force of recordation of patent licensing contract
EE01 Entry into force of recordation of patent licensing contract

Application publication date: 20140903

Assignee: Hangzhou national software industry base Co.,Ltd.

Assignor: Hangzhou Jiji Intellectual Property Operation Co.,Ltd.

Contract record no.: X2021330000669

Denomination of invention: Method of limiting command execution speed of switch

Granted publication date: 20180928

License type: Common License

Record date: 20211103

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20221229

Address after: 313000 room 1019, Xintiandi commercial office, Yishan street, Wuxing District, Huzhou, Zhejiang, China

Patentee after: Huzhou YingLie Intellectual Property Operation Co.,Ltd.

Address before: Room 10242, No. 260, Jiangshu Road, Xixing street, Binjiang District, Hangzhou City, Zhejiang Province

Patentee before: Hangzhou Jiji Intellectual Property Operation Co.,Ltd.

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20250617

Address after: 200120 Shanghai Pudong New Area, China (Shanghai) Pilot Free Trade Zone, 6th Floor, Room 601, No. 88 Century Avenue

Patentee after: Shanghai Yuyan Industrial Co.,Ltd.

Country or region after: China

Address before: 313000 room 1019, Xintiandi commercial office, Yishan street, Wuxing District, Huzhou, Zhejiang, China

Patentee before: Huzhou YingLie Intellectual Property Operation Co.,Ltd.

Country or region before: China

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20250830

Address after: 201900 Shanghai Baoshan District Songnan Road 479, 2nd floor

Patentee after: Shanghai Mingyao Supply Chain Technology Co.,Ltd.

Country or region after: China

Address before: 200120 Shanghai Pudong New Area, China (Shanghai) Pilot Free Trade Zone, 6th Floor, Room 601, No. 88 Century Avenue

Patentee before: Shanghai Yuyan Industrial Co.,Ltd.

Country or region before: China