CN106953771A - The Counterchange roles and management method of a kind of master-slave equipment - Google Patents

The Counterchange roles and management method of a kind of master-slave equipment Download PDF

Info

Publication number
CN106953771A
CN106953771A CN201710336154.1A CN201710336154A CN106953771A CN 106953771 A CN106953771 A CN 106953771A CN 201710336154 A CN201710336154 A CN 201710336154A CN 106953771 A CN106953771 A CN 106953771A
Authority
CN
China
Prior art keywords
equipment
master
slave
main equipment
message
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.)
Granted
Application number
CN201710336154.1A
Other languages
Chinese (zh)
Other versions
CN106953771B (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.)
Shenzhen Universal Public Alliance Network Technology Co Ltd
Original Assignee
Shenzhen Universal Public Alliance Network 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 Shenzhen Universal Public Alliance Network Technology Co Ltd filed Critical Shenzhen Universal Public Alliance Network Technology Co Ltd
Priority to CN201710336154.1A priority Critical patent/CN106953771B/en
Publication of CN106953771A publication Critical patent/CN106953771A/en
Application granted granted Critical
Publication of CN106953771B publication Critical patent/CN106953771B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/02Standardisation; Integration
    • H04L41/0246Exchanging or transporting network management information using the Internet; Embedding network management web servers in network elements; Web-services-based protocols
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/04Network management architectures or arrangements
    • H04L41/044Network management architectures or arrangements comprising hierarchical management structures
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/16Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/06Management of faults, events, alarms or notifications
    • H04L41/0654Management of faults, events, alarms or notifications using network fault recovery
    • H04L41/0663Performing the actions predefined by failover planning, e.g. switching to standby network elements

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Small-Scale Networks (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The invention discloses a kind of Counterchange roles of master-slave equipment and management method, the changing role of the master-slave equipment determines principal and subordinate role by sending procotol message, reach that main equipment manages the purpose of slave unit, the procotol message includes the procotol field and releasing master slave relation for being used to establish principal and subordinate role, the master-slave equipment is received after the procotol message, is performed corresponding be locally configured and is determined and conversion master slave relation.The present invention provides the Counterchange roles and management method of a kind of master-slave equipment, consult to complete using three layer protocol TCP, UDP automations by the changing role of master-slave equipment, slave unit is managed concentratedly and controlled in the case of correctly connection network topology, greatly improve the efficiency of management, reduce repeated workload, facilitate location equipment, reduction safeguards the difficulty of debugging, farthest realizes the centralized management between equipment.

Description

The Counterchange roles and management method of a kind of master-slave equipment
Technical field
The present invention relates to the Counterchange roles and management method of communication technical field, more particularly to a kind of master-slave equipment.
Background technology
At present, the administration page progress direct to the machine that the management to equipment logs on the network equipment generally by webpage Management, it is impossible to other network equipments in controlling network.Equipment in network assume responsibility for comparing the role of separate single one a bit, make Into the operation of repeatability, modification difficulty is big, and some equipment need to provide more fully function, if now can be single to role Equipment carries out centralized management management, rationally determines master-slave equipment, can more easily use the network equipment.
The content of the invention
The purpose of the present invention is that to solve the above problems and provide Counterchange roles and the management of a kind of master-slave equipment Method.
The present invention is achieved through the following technical solutions above-mentioned purpose:
The present invention comprises the following steps:
Step one, TCP connections are initialized;
Step 2, is periodically reported, and finds main equipment;
Step 3, if find cascade main equipment, be, goes to step four, otherwise goes to step six;
Step 4, is periodically reported to cascade main equipment;
Step 5, if report success to main equipment, is to go to step four, otherwise goes to step two;
Step 6, initializes UDP connections;
Whether step 7, the machine is to force bypass main equipment, is to go to step nine, otherwise goes to step eight;
Step 8, sends udp broadcast bag and finds bypass main equipment;
Step 9, sends udp broadcast bag and attempts to turn into bypass main equipment;
UDP message negotiations are carried out between step 10, equipment, if negotiate bypass main equipment, be, go to step 11, it is no Then go to step two;
Step 11, is periodically reported to bypass main equipment;
Step 12, if report success to main equipment, is to go to step 11, otherwise goes to step two.
Preferably, according to step one, the initialization TCP connections comprise the following steps the present invention:
Step a, initializes TCP connections;
Step b, receives TCP requests;
Data in step c, parsing TCP message determine that reporting equipment is the equipment for meeting master-slave communication, then go to step d, Otherwise this message is not handled, goes to step b;
The sub- equipment of data preservation in step d, parsing TCP message is reported to call time to determine equipment in information, and preservation Presence;
Step e, construction needs the message for returning to sub- device configuration to be sent to sub- equipment, goes to step b.
Preferably, according to step 6, the initialization UDP connections comprise the following steps the present invention:
Step 1:Initialize UDP interfaces;
Step 2:Judge whether WAN mouthfuls of equipment connects, if having IP information, otherwise go to step 3, be, go to step 5;
Step 3:Whether be connection be converted to be not connected to, be to go to step 4, otherwise go to step 11 if judging WAN mouthfuls of equipment;
Step 4:All flag bits for being used to identify master-slave equipment are removed, 11 are gone to step;
Step 5:Whether be first connection, be to go to step 6, otherwise go to step 7 if judging WAN mouthfuls of equipment;
Step 6:Reserved enough time is waited to judge whether to cascade main equipment;
Step 7:Receive and handle UDP messages;
Step 8:Judge whether to cascade main equipment, otherwise go to step 9, be, go to step 11;
Step 9:Whether be force bypass main equipment, be to go to step 10, otherwise go to step 11 if judging the machine;
Step 10:According to the UDP type of messages received, send corresponding UDP and reply message;
Step 11:1s is waited, 2 are gone to step.
Preferably, according to step 11, described periodically reported to bypass main equipment comprises the following steps the present invention:
Step I:Whether WAN mouthfuls of periodic test equipment connects, and is to go to step II, and the cycle of otherwise waiting for continues to go to step Rapid 1;
Step II:Initialization reports the machine reported data;
Step III:Judge whether to bypass main equipment, be to go to step IV, otherwise go to step V;
Step IV:It is bypass main equipment address that setting, which reports address,;
Step V:It is WAN gateway address that setting, which reports address,;
Step VI:Address is reported by what the reported data of preparation composition TCP message was sent to setting;
Step VII:Parse TCP and reply message, the machine is configured according to message content and come into force, I is gone to step.
Preferably, according to step 2, the changing role of the master-slave equipment is true by sending procotol message by the present invention Determine principal and subordinate role, the procotol message includes the procotol field and releasing master slave relation for being used to establish principal and subordinate role, The master-slave equipment is received after the procotol message, and determination is locally configured accordingly in conversion master slave relation and execution.
Preferably, the main equipment is divided into cascade main equipment and bypass main equipment to the present invention, and slave unit can report useful letter Cease and receive the management of main equipment.
Preferably, the master-slave equipment is determined the present invention according to the network topology of master-slave equipment and defined protocol.
The beneficial effects of the present invention are:
The present invention provides the Counterchange roles and management method of a kind of master-slave equipment, is used by the changing role of master-slave equipment Three layer protocol TCP, UDP automations are consulted to complete, and slave unit is managed concentratedly in the case of correctly connection network topology And control, the efficiency of management is greatly improved, repeated workload is reduced, facilitates location equipment, the difficulty of debugging is safeguarded in reduction, most The centralized management realized between equipment of big degree.
Brief description of the drawings
Fig. 1 is discovery and administrative mechanism flow chart of the cascade main equipment of the present invention to slave unit;
Fig. 2 is the negotiation discovery mechanism flow chart of bypass master-slave equipment of the present invention;
Fig. 3 is that facility information of the present invention reports and replied Message processing flow chart.
Embodiment
The invention will be further described below in conjunction with the accompanying drawings:
:The present invention comprises the following steps:
Step one, TCP connections are initialized;
Step 2, is periodically reported, and finds main equipment;
Step 3, if find cascade main equipment, be, goes to step four, otherwise goes to step six;
Step 4, is periodically reported to cascade main equipment;
Step 5, if report success to main equipment, is to go to step four, otherwise goes to step two;
Step 6, initializes UDP connections;
Whether step 7, the machine is to force bypass main equipment, is to go to step nine, otherwise goes to step eight;
Step 8, sends udp broadcast bag and finds bypass main equipment;
Step 9, sends udp broadcast bag and attempts to turn into bypass main equipment;
UDP message negotiations are carried out between step 10, equipment, if negotiate bypass main equipment, be, go to step 11, it is no Then go to step two;
Step 11, is periodically reported to bypass main equipment;
Step 12, if report success to main equipment, is to go to step 11, otherwise goes to step two.
As shown in figure 1, the initialization TCP connections comprise the following steps:
Step a, initializes TCP connections;
Step b, receives TCP requests;
Data in step c, parsing TCP message determine that reporting equipment is the equipment for meeting master-slave communication, then go to step d, Otherwise this message is not handled, goes to step b;
The sub- equipment of data preservation in step d, parsing TCP message is reported to call time to determine equipment in information, and preservation Presence;
Step e, construction needs the message for returning to sub- device configuration to be sent to sub- equipment, goes to step b.
As shown in Fig. 2 the initialization UDP connections comprise the following steps:
Step 1:Initialize UDP interfaces;
Step 2:Judge whether WAN mouthfuls of equipment connects, if having IP information, otherwise go to step 3, be, go to step 5;
Step 3:Whether be connection be converted to be not connected to, be to go to step 4, otherwise go to step 11 if judging WAN mouthfuls of equipment;
Step 4:All flag bits for being used to identify master-slave equipment are removed, 11 are gone to step;
Step 5:Whether be first connection, be to go to step 6, otherwise go to step 7 if judging WAN mouthfuls of equipment;
Step 6:Reserved enough time is waited to judge whether to cascade main equipment;
Step 7:Receive and handle UDP messages;
Step 8:Judge whether to cascade main equipment, otherwise go to step 9, be, go to step 11;
Step 9:Whether be force bypass main equipment, be to go to step 10, otherwise go to step 11 if judging the machine;
Step 10:According to the UDP type of messages received, send corresponding UDP and reply message;
Step 11:1s is waited, 2 are gone to step.
As shown in figure 3, described periodically reported to bypass main equipment comprises the following steps:
Step I:Whether WAN mouthfuls of periodic test equipment connects, and is to go to step II, and the cycle of otherwise waiting for continues to go to step Rapid 1;
Step II:Initialization reports the machine reported data;
Step III:Judge whether to bypass main equipment, be to go to step IV, otherwise go to step V;
Step IV:It is bypass main equipment address that setting, which reports address,;
Step V:It is WAN gateway address that setting, which reports address,;
Step VI:Address is reported by what the reported data of preparation composition TCP message was sent to setting;
Step VII:Parse TCP and reply message, the machine is configured according to message content and come into force, I is gone to step.
The changing role of the master-slave equipment determines principal and subordinate role, the procotol report by sending procotol message Text includes the procotol field and releasing master slave relation for being used to establish principal and subordinate role, and the master-slave equipment receives the network association Discuss after message, determination is locally configured in conversion master slave relation and execution accordingly, and the main equipment is divided into cascade main equipment and bypass Main equipment, slave unit can report useful information and receive the management of main equipment, and the master-slave equipment is according to the network of master-slave equipment Protocol as defined in topological sum is determined.
In summary, the present invention provides the Counterchange roles and management method of a kind of master-slave equipment, passes through the angle of master-slave equipment Color change is consulted to complete using three layer protocol TCP, UDP automations, and slave unit is entered in the case of correctly connection network topology Row centralized management and control, greatly improve the efficiency of management, reduce repeated workload, facilitate location equipment, and reduction, which is safeguarded, adjusts The difficulty of examination, farthest realizes the centralized management between equipment.
Those skilled in the art do not depart from the essence and spirit of the present invention, can have various deformation scheme to realize the present invention, Preferable feasible embodiment of the invention is the foregoing is only, not thereby limits to the interest field of the present invention, it is all with this Within the equivalence changes that description of the invention content is made, the interest field for being both contained in the present invention.

Claims (7)

1. the Counterchange roles and management method of a kind of master-slave equipment, it is characterised in that comprise the following steps:
Step one, TCP connections are initialized;
Step 2, is periodically reported, and finds main equipment;
Step 3, if find cascade main equipment, be, goes to step four, otherwise goes to step six;
Step 4, is periodically reported to cascade main equipment;
Step 5, if report success to main equipment, is to go to step four, otherwise goes to step two;
Step 6, initializes UDP connections;
Whether step 7, the machine is to force bypass main equipment, is to go to step nine, otherwise goes to step eight;
Step 8, sends udp broadcast bag and finds bypass main equipment;
Step 9, sends udp broadcast bag and attempts to turn into bypass main equipment;
UDP message negotiations are carried out between step 10, equipment, if negotiate bypass main equipment, be, go to step 11, otherwise turn Step 2;
Step 11, is periodically reported to bypass main equipment;
Step 12, if report success to main equipment, is to go to step 11, otherwise goes to step two.
2. the Counterchange roles and management method of master-slave equipment according to claim 1, it is characterised in that according to step one, The initialization TCP connections comprise the following steps:
Step a, initializes TCP connections;
Step b, receives TCP requests;
Data in step c, parsing TCP message determine that reporting equipment is the equipment for meeting master-slave communication, then go to step d, otherwise This message is not handled, goes to step b;
Data in step d, parsing TCP message preserve sub- equipment and report information, and preserve call time with determine equipment Wire state;
Step e, construction needs the message for returning to sub- device configuration to be sent to sub- equipment, goes to step b.
3. the Counterchange roles and management method of master-slave equipment according to claim 1, it is characterised in that according to step 6, The initialization UDP connections comprise the following steps:
Step 1:Initialize UDP interfaces;
Step 2:Judge whether WAN mouthfuls of equipment connects, if having IP information, otherwise go to step 3, be, go to step 5;
Step 3:Whether be connection be converted to be not connected to, be to go to step 4, otherwise go to step 11 if judging WAN mouthfuls of equipment;
Step 4:All flag bits for being used to identify master-slave equipment are removed, 11 are gone to step;
Step 5:Whether be first connection, be to go to step 6, otherwise go to step 7 if judging WAN mouthfuls of equipment;
Step 6:Reserved enough time is waited to judge whether to cascade main equipment;
Step 7:Receive and handle UDP messages;
Step 8:Judge whether to cascade main equipment, otherwise go to step 9, be, go to step 11;
Step 9:Whether be force bypass main equipment, be to go to step 10, otherwise go to step 11 if judging the machine;
Step 10:According to the UDP type of messages received, send corresponding UDP and reply message;
Step 11:1s is waited, 2 are gone to step.
4. the Counterchange roles and management method of master-slave equipment according to claim 1, it is characterised in that according to step 10 One, described periodically reported to bypass main equipment comprises the following steps:
Step I:Whether WAN mouthfuls of periodic test equipment connects, and is to go to step II, the cycle of otherwise waiting for continues to go to step 1;
Step II:Initialization reports the machine reported data;
Step III:Judge whether to bypass main equipment, be to go to step IV, otherwise go to step V;
Step IV:It is bypass main equipment address that setting, which reports address,;
Step V:It is WAN gateway address that setting, which reports address,;
Step VI:Address is reported by what the reported data of preparation composition TCP message was sent to setting;
Step VII:Parse TCP and reply message, the machine is configured according to message content and come into force, I is gone to step.
5. the Counterchange roles and management method of master-slave equipment according to claim 1, it is characterised in that according to step 2, The changing role of the master-slave equipment determines principal and subordinate role by sending procotol message, and the procotol message includes using In the procotol field and releasing master slave relation of establishing principal and subordinate role, the master-slave equipment receives the procotol message Afterwards, determination is locally configured accordingly in conversion master slave relation and execution.
6. the Counterchange roles and management method of master-slave equipment according to claim 5, it is characterised in that the main equipment point For cascade main equipment and bypass main equipment, slave unit can report useful information and receive the management of main equipment.
7. the Counterchange roles and management method of master-slave equipment according to claim 6, it is characterised in that the master-slave equipment Determined according to the network topology of master-slave equipment and defined protocol.
CN201710336154.1A 2017-05-12 2017-05-12 Role transformation and management method for master and slave equipment Active CN106953771B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710336154.1A CN106953771B (en) 2017-05-12 2017-05-12 Role transformation and management method for master and slave equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710336154.1A CN106953771B (en) 2017-05-12 2017-05-12 Role transformation and management method for master and slave equipment

Publications (2)

Publication Number Publication Date
CN106953771A true CN106953771A (en) 2017-07-14
CN106953771B CN106953771B (en) 2020-04-21

Family

ID=59479140

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710336154.1A Active CN106953771B (en) 2017-05-12 2017-05-12 Role transformation and management method for master and slave equipment

Country Status (1)

Country Link
CN (1) CN106953771B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111555903A (en) * 2020-03-26 2020-08-18 浙江口碑网络技术有限公司 Data communication method and device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020049608A1 (en) * 2000-03-03 2002-04-25 Hartsell Neal D. Systems and methods for providing differentiated business services in information management environments
EP1176774A3 (en) * 2000-07-26 2004-04-14 Rad Data Communications Ltd. TDM over IP (IP circuit emulation service)
CN102946327A (en) * 2012-11-30 2013-02-27 深圳市磊科实业有限公司 Topology generation method of switchboard management system
WO2016036077A1 (en) * 2014-09-02 2016-03-10 엘지전자 주식회사 Broadcast receiving apparatus, method for operating broadcast receiving apparatus, interlocking apparatus interlocking with broadcast receiving apparatus, and method for operating interlocking apparatus
WO2016049353A1 (en) * 2014-09-25 2016-03-31 Behzad Mohebbi Methods and apparatus for hybrid access to a core network based on proxied authentication
CN105704019A (en) * 2014-12-16 2016-06-22 思科技术公司 Node protection for segment routing adjacency segments

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020049608A1 (en) * 2000-03-03 2002-04-25 Hartsell Neal D. Systems and methods for providing differentiated business services in information management environments
EP1176774A3 (en) * 2000-07-26 2004-04-14 Rad Data Communications Ltd. TDM over IP (IP circuit emulation service)
CN102946327A (en) * 2012-11-30 2013-02-27 深圳市磊科实业有限公司 Topology generation method of switchboard management system
WO2016036077A1 (en) * 2014-09-02 2016-03-10 엘지전자 주식회사 Broadcast receiving apparatus, method for operating broadcast receiving apparatus, interlocking apparatus interlocking with broadcast receiving apparatus, and method for operating interlocking apparatus
WO2016049353A1 (en) * 2014-09-25 2016-03-31 Behzad Mohebbi Methods and apparatus for hybrid access to a core network based on proxied authentication
CN105704019A (en) * 2014-12-16 2016-06-22 思科技术公司 Node protection for segment routing adjacency segments

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111555903A (en) * 2020-03-26 2020-08-18 浙江口碑网络技术有限公司 Data communication method and device

Also Published As

Publication number Publication date
CN106953771B (en) 2020-04-21

Similar Documents

Publication Publication Date Title
EP1892929B1 (en) A method, an apparatus and a system for message transmission
CN100454905C (en) Method for passing through network address switching
CN104270355A (en) Cross-safety-zone data transmission method based on network bus
CN111866110B (en) Industrial equipment communication method and 5G gateway
CN106201375B (en) A method of the network share print control based on WebSocket
CN102045409B (en) Network penetrating method and network communication system
CN103312528A (en) Heartbeat message sending method and user terminal
Klauck et al. Chatty things-Making the Internet of Things readily usable for the masses with XMPP
CN106302536B (en) The method and apparatus communicated between all-in-one machine multisystem based on interchanger
CN101072167A (en) Method and system for transmitting information through communication system
CN110460483B (en) Profinet and Modbus equipment heterogeneous networking method based on SDN
CN104243281A (en) Voice communication method based on mobile Internet
CN102916833B (en) Remote debugging method, remote debugging system and debugging target equipment
CN110166353A (en) LoRaWan gateway system and LoRaWan gateway
CN104463670A (en) Websocket-based bank preposition transaction system construction method
CN113810271A (en) Southbound equipment interface agent device of Internet of things gateway and implementation method
CN102438017A (en) Routing function-based conversion apparatus of Modbus protocol and BACnet Ethernet protocol and conversion method thereof
CN106953771A (en) The Counterchange roles and management method of a kind of master-slave equipment
CN103841148A (en) Master-slave communication method and system adopting reliable and unreliable networks in monitoring program
CN104333872B (en) A kind of method and system for establishing session based on two-way converting detection technique
CN104102607A (en) CAN (controlled area network) bus driving method and system based on VxWorks operating system environment
CN106533934A (en) Border gateway applicable to all interconnected manufacturing networks
CN112039746B (en) Industrial control network system
CN104320322B (en) A kind of message control method and equipment
Kodali An implementation of MQTT using CC3200

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant