CN110138892A - Determine the method and device of equipment regional information - Google Patents

Determine the method and device of equipment regional information Download PDF

Info

Publication number
CN110138892A
CN110138892A CN201910467141.7A CN201910467141A CN110138892A CN 110138892 A CN110138892 A CN 110138892A CN 201910467141 A CN201910467141 A CN 201910467141A CN 110138892 A CN110138892 A CN 110138892A
Authority
CN
China
Prior art keywords
target device
address
mac address
regional information
information
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
CN201910467141.7A
Other languages
Chinese (zh)
Other versions
CN110138892B (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.)
Miaozhen Information Technology Co Ltd
Miaozhen Systems Information Technology Co Ltd
Original Assignee
Miaozhen Systems Information 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 Miaozhen Systems Information Technology Co Ltd filed Critical Miaozhen Systems Information Technology Co Ltd
Priority to CN201910467141.7A priority Critical patent/CN110138892B/en
Publication of CN110138892A publication Critical patent/CN110138892A/en
Application granted granted Critical
Publication of CN110138892B publication Critical patent/CN110138892B/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
    • H04L2101/00Indexing scheme associated with group H04L61/00
    • H04L2101/60Types of network addresses
    • H04L2101/618Details of network addresses
    • H04L2101/622Layer-2 addresses, e.g. medium access control [MAC] addresses
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L2101/00Indexing scheme associated with group H04L61/00
    • H04L2101/60Types of network addresses
    • H04L2101/69Types of network addresses using geographic information, e.g. room number

Landscapes

  • Telephonic Communication Services (AREA)

Abstract

This application provides a kind of method and devices of determining equipment regional information, when determining regional information by the method that the application proposes locking equipment regional information really, since the IP address configuration of Network Provider can change since routing policy changes, when so that the IP address for distributing to smart machine changing, the application can obtain at least one IP address in predetermined period, it include the IP address to change at least one IP address, target ip address is determined according at least one IP address, obtain current zone information, the regional information of target device is determined by the historical relation table of comparisons and current zone information, improve the accuracy of the regional information of acquisition.And the regional information of target device will not be changed immediately in the application when IP address changes, the regional information of target device will not frequently be changed, it is the regional information that the method proposed by the application determines target device, reduces the maintenance cost of the regional information of target device.

Description

Determine the method and device of equipment regional information
Technical field
This application involves Internet technical fields, more particularly, to a kind of method and device of determining equipment regional information.
Background technique
With the development of information science technology, the quantity of smart machine is in rapid growth, so that client needs to set intelligence Standby to be managed, smart machine includes smart television, intellectual water meter etc..Wherein, it when being managed smart machine, needs to know The regional information of smart machine, it is right according to the regional information of smart machine, to call the regional information to correspond to the resource in region Smart machine performs corresponding processing.It is illustrated taking a smart TV as an example, smart television manufacturer needs to obtain smart machine Regional information, the technical attendant resource in region is corresponded to according to the regional information, smart television is safeguarded, or Person, smart television advertiser can judge to launch to intelligent according to regional information to set after the regional information for obtaining smart machine The specific region of standby upper advertisement exposure, to determine that effect is launched in the region of advertisement.
In the prior art, the address Internet protocol (Internet Protocol, IP) connected by smart machine, root Region table, which is divided, according to the IP section of unification of the motherland judges the corresponding regional information of smart machine.But this method, due to Network Provider IP address configuration can due to routing policy change and change, even if the routing policy change probability it is smaller, change Time is shorter, also can make the IP address for distributing to smart machine that can change, to determine according to IP sections of division region tables The corresponding regional information of smart machine may also change accordingly, and the smart machine is usually to be fixedly mounted, and regional information is Fixed, thus, the accuracy of the smart machine corresponding regional information determining according to this method is lower, and error is larger, in turn, According to the accuracy lower ground domain information carry out smart machine maintenance, cause maintenance cost higher.
Summary of the invention
In view of this, a kind of method and device for being designed to provide determining equipment regional information of the application, to improve The accuracy of the equipment regional information of acquisition reduces error, and reduces the maintenance cost of the regional information of equipment.
In a first aspect, the embodiment of the present application provides a kind of method of determining equipment regional information, which comprises
The historical data of target device is obtained, the historical data includes target device media access control (Media Access Control, MAC) at least one internet for being communicated in preset period of time of address and the target device Protocol IP address;
From at least one IP address, the corresponding target ip address of target device MAC Address is determined;
The regional information for determining the target ip address obtains the corresponding current zone letter of the target device MAC Address Breath;
Based on the target device MAC Address, the corresponding current zone information of the target device MAC Address and in advance The MAC Address of storage and the historical relation table of comparisons of regional information, obtain the regional information of the target device.
It is described to be based on the target device MAC Address, the target device MAC Address in some embodiments of the present application The historical relation table of comparisons of corresponding current zone information and pre-stored MAC Address and regional information, obtains the mesh The regional information of marking device, comprising:
In the historical relation table of comparisons, the target device MAC Address is searched;
If finding, in the historical relation table of comparisons, the corresponding history region of the target device MAC Address is searched Information;
It detects the current zone information and whether the history regional information is identical;
If they are the same, using the current zone information as the regional information of the target device;
If it is different, then rule is determined according to the information of setting, from the current zone information and the history regional information In, determine the regional information of the target device.
In some embodiments of the present application, the method also includes:
If not finding the target device MAC Address in the historical relation table of comparisons, by the target device MAC Regional information of the corresponding current zone information in address as the target device.
It is described from least one IP address in some embodiments of the present application, determine that target device MAC Address is corresponding Target ip address, comprising:
For each IP address at least one IP address, the number communicated using the IP address is counted;
The most IP address of the number communicated is chosen, as the corresponding Target IP of the target device MAC Address Location.
In some embodiments of the present application, in the regional information for determining the target ip address, the target device is obtained After the corresponding current zone information of MAC Address, the method also includes:
According to the detected rule of setting, to the standard of the historical relation table of comparisons of pre-stored MAC Address and regional information True property is detected.
In some embodiments of the present application, the detected rule according to setting, to pre-stored MAC Address and region The accuracy of the historical relation table of comparisons of information is detected, comprising:
The MAC Address of preset quantity is selected from the historical relation table of comparisons;
The accuracy for detecting the corresponding regional information of each MAC Address in the MAC Address of preset quantity obtains described default The accuracy rate of the MAC Address of quantity;
If detecting the accuracy rate threshold value that the obtained accuracy rate is greater than setting, it is determined that the historical relation table of comparisons inspection Survey passes through.
Second aspect, the embodiment of the present application also provide a kind of device of determining equipment regional information, and described device includes:
Module is obtained, for obtaining the historical data of target device, the historical data includes target device media interviews At least one internet protocol address that control MAC Address and the target device communicate in preset period of time;
IP address determining module, for determining the corresponding Target IP of target device MAC Address from least one IP address Address;
Information determination module obtains the target device MAC Address for determining the regional information of the target ip address Corresponding current zone information;
Regional information obtains module, for corresponding based on the target device MAC Address, the target device MAC Address Current zone information and pre-stored MAC Address and regional information the historical relation table of comparisons, obtain the target and set Standby regional information.
In some embodiments of the present application, the regional information obtains module, is specifically used for:
In the historical relation table of comparisons, the target device MAC Address is searched;
If finding, in the historical relation table of comparisons, the corresponding history region of the target device MAC Address is searched Information;
It detects the current zone information and whether the history regional information is identical;
If they are the same, using the current zone information as the regional information of the target device;
If it is different, then rule is determined according to the information of setting, from the current zone information and the history regional information In, determine the regional information of the target device.
The third aspect, the embodiment of the present application also provide a kind of electronic equipment, comprising: processor, memory and bus, it is described Memory is stored with the executable machine readable instructions of the processor, when electronic equipment operation, the processor with it is described By bus communication between memory, the machine readable instructions executed when being executed by the processor it is above-mentioned in a first aspect, or Described in any possible embodiment of first aspect really the method for locking equipment regional information the step of.
Fourth aspect, the embodiment of the present application also provide a kind of computer readable storage medium, the computer-readable storage medium Computer program is stored in matter, which executes above-mentioned in a first aspect, or first aspect when being run by processor Described in any possible embodiment really the method for locking equipment regional information the step of.
The embodiment of the present application provides a kind of method and device of determining equipment regional information, wherein determines equipment region The method of information, obtains the historical data of target device first, and historical data includes target device media access control MAC At least one internet protocol address that location and target device communicate in preset period of time;Secondly from least one In IP address, the corresponding target ip address of target device MAC Address is determined;Then the regional information for determining target ip address, obtains To the corresponding current zone information of target device MAC Address;Finally it is based on target device MAC Address, target device MAC Address pair The historical relation table of comparisons of the current zone information and pre-stored MAC Address and regional information answered, obtains target device Regional information.When determining regional information by the method that the application proposes locking equipment regional information really, if since network supplies Answering the IP address of quotient to configure can change since routing policy changes, so that distributing to the IP address of smart machine can occur When variation, the application can obtain at least one IP address in predetermined period, include changing at least one IP address IP address, determine target ip address according at least one IP address, obtain current zone information, and pass through historical relation and compare Table and current zone information determine the regional information of target device, improve the accuracy of the regional information of acquisition.And this Shen Please in will not change immediately the regional information of target device when IP address changes, will not frequently change target device Regional information, but the regional information of target device is determined by the method that the application proposes, reduce the maintenance cost of equipment.
To enable the above objects, features, and advantages of the application to be clearer and more comprehensible, preferred embodiment is cited below particularly, and cooperate Appended attached drawing, is described in detail below.
Detailed description of the invention
Technical solution in ord to more clearly illustrate embodiments of the present application, below will be to needed in the embodiment attached Figure is briefly described, it should be understood that the following drawings illustrates only some embodiments of the application, therefore is not construed as pair The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this A little attached drawings obtain other relevant attached drawings.
Fig. 1 shows a kind of flow chart of the method for determining equipment regional information provided by the embodiment of the present application;
Fig. 2 shows one kind provided by the embodiment of the present application to be based on target device MAC Address, target device MAC Address The historical relation table of comparisons of corresponding current zone information and pre-stored MAC Address and regional information, obtains target and sets The flow chart of standby regional information;
Fig. 3 shows a kind of structural schematic diagram of the device of determining equipment regional information provided by the embodiment of the present application;
Fig. 4 shows the structural schematic diagram of a kind of electronic equipment provided by the embodiment of the present application.
Icon: 301- obtains module;302-IP address determination module;303- information determination module;304- regional information obtains Obtain module;400- electronic equipment;401- processor;402- memory;403- bus;4021- memory;4022- external memory.
Specific embodiment
To keep the purposes, technical schemes and advantages of the embodiment of the present application clearer, below in conjunction with the embodiment of the present application Middle attached drawing, the technical scheme in the embodiment of the application is clearly and completely described, it is clear that described embodiment is only It is some embodiments of the present application, instead of all the embodiments.The application being usually described and illustrated herein in the accompanying drawings is real The component for applying example can be arranged and be designed with a variety of different configurations.Therefore, below to the application's provided in the accompanying drawings The detailed description of embodiment is not intended to limit claimed scope of the present application, but is merely representative of the selected reality of the application Apply example.Based on embodiments herein, those skilled in the art institute obtained without making creative work There are other embodiments, shall fall in the protection scope of this application.
In view of in the prior art, the IP address connected by smart machine divides region according to the IP of unification of the motherland section Table judges the corresponding regional information of smart machine.But this method, since the IP address configuration of Network Provider can be due to routing plan It slightly changes and changes, even if the probability that the routing policy changes is smaller, the time of variation is shorter, can also to distribute to intelligence The IP address of energy equipment can change, to divide the corresponding regional information of smart machine that region tables determine according to IP sections Can corresponding change, and the smart machine be usually be fixedly mounted, regional information be it is fixed, thus, according to this method determine The corresponding regional information of smart machine accuracy it is lower, error is larger, in turn, according to the accuracy lower ground domain information The maintenance for carrying out smart machine, causes maintenance cost higher.Based on this, the embodiment of the present application provides a kind of determining equipment region The accuracy of the equipment regional information of acquisition can be improved in the method and device of information, reduces error, and reduce equipment Maintenance cost is described below by embodiment.
To be believed a kind of determining equipment region disclosed in the embodiment of the present application first convenient for understanding the present embodiment The method of breath describes in detail.
Embodiment one
The embodiment of the present application proposes a kind of method of determining equipment regional information, and shown in Figure 1 is a kind of determination The flow chart of the method for equipment regional information, the method comprising the steps of S101-S104;It is specific:
S101, obtains the historical data of target device, historical data include target device MAC address, And at least one internet protocol address that target device communicates in preset period of time.
It, can be in the historical data of monthly set time acquisition target device, for example, can be every in the embodiment of the present application The moon 1, obtain the historical data of target device.Historical data includes target device MAC Address and target device when default Between at least one IP address for communicating in the period.Exemplary illustration, preset period of time can be gone through to obtain 6 months before the date History data, for example, if obtaining target device from 2018 1 when obtaining the historical data of target device on July 1st, 2018 At least one IP address communicated on June 30th, No. 11 moon.Wherein, preset period of time can be according to the actual situation It is configured, the application is to this without specifically limiting.
When specific implementation, the MAC Address of each equipment in available multiple equipment to be managed, by multiple equipment MAC Address is stored in address list.Wherein, target device is any appliance in multiple equipment to be managed.
S102 determines the corresponding target ip address of target device MAC Address from least one IP address.
When specific implementation, the corresponding target ip address of target device MAC Address is determined by following methods:
Firstly, counting the number communicated using the IP address for each IP address at least one IP address.
In the embodiment of the present application, in preset period of time, for each IP address at least one IP address, statistics should The number that IP address is communicated obtains the number that each IP address is communicated at least one IP address.
Secondly, choosing the most IP address of the number communicated, as the corresponding Target IP of target device MAC Address Location.
When specific implementation, according to the number that each IP address is communicated at least one obtained IP address, choose into The most IP address of the number of row communication, as the corresponding target ip address of target device MAC Address.In this way, working as network provisioning The IP address configuration of quotient changes since the routing policy of short time changes, so that distributing to the IP address hair of target device After changing, by counting in preset period of time to the IP address of smart machine distribution communication, selection is led to The most IP address of the number of letter, as the corresponding target ip address of target device MAC Address, thus according to IP sections of division regions Table can determine the corresponding regional information of target ip address, it is possible to prevente effectively from IP address fluctuation of the distribution for communication causes The influence that changes of regional information, the accuracy of the corresponding regional information of determining smart machine is improved, in turn, according to compared with Gao Zhun The regional information of true property carries out the maintenance of smart machine, and maintenance cost can be effectively reduced.
S103 determines the regional information of target ip address, obtains the corresponding current zone information of target device MAC Address.
In the embodiment of the present application, the corresponding regional information of the IP address, region letter can be obtained according to target ip address Breath is the corresponding current zone information of target device MAC Address.Wherein, regional information is address information.For example, IP address pair The regional information answered can be Beijing.
S104 is deposited based on target device MAC Address, the corresponding current zone information of target device MAC Address and in advance The MAC Address of storage and the historical relation table of comparisons of regional information, obtain the regional information of target device.
Shown in Figure 2 when specific implementation, the embodiment of the present application proposes a kind of based on target device MAC Address, target The historical relation table of comparisons of the corresponding current zone information of device mac address and pre-stored MAC Address and regional information, Obtain the concrete mode of the regional information of target device, including step S201-S204.
S201 searches target device MAC Address in the historical relation table of comparisons.
S202 in the historical relation table of comparisons, searches the corresponding history region letter of target device MAC Address if finding Breath.
When specific implementation, if not finding target device MAC Address in the historical relation table of comparisons, by target device MAC Regional information of the corresponding current zone information in address as target device.If finding target in the historical relation table of comparisons Device mac address then obtains the corresponding history regional information of target device MAC Address.
S203, detects current zone information and whether history regional information is identical.
S204, if they are the same, using current zone information as the regional information of target device;If it is different, then according to setting Information determines rule, from current zone information and history regional information, determines the regional information of target device.
Exemplary illustration, if the corresponding current zone information of target device MAC Address is Beijing, corresponding history region Information is Beijing, then the Beijing is the corresponding regional information of target device MAC Address.If target device MAC Address pair The current zone information answered is Beijing, and corresponding history regional information is Tianjin, then needs true according to the information of setting Set pattern then, from current zone information and history regional information, determines the regional information of target device.
Specifically, information determines that rule includes the one or more of following rule: rule one, change preset period of time, The historical data of target device is reacquired, which includes target device MAC Address and target device after change Preset period of time in communicate at least one IP address.Wherein, change the time cycle when, can change the time cycle when Between length.The example accepted in S101 continues to explain, if the preset period of time before change is 1 day to 2018 6 January in 2018 The moon 30, the time cycle after change can be on June 30,1 day to 2018 July in 2017, by the time of preset period of time Length was changed to 12 months from 6 months.Repeat the above steps S102-S104, obtains the regional information of target device.Rule two, The regional information of target device is determined by way of artificially investigating.
In the embodiment of the present application, the building process of the historical relation table of comparisons are as follows:
Firstly, obtaining the historical data of the equipment, historical data packet for each equipment in multiple equipment to be managed It includes: at least one IP address that the device mac address of the equipment and the equipment communicate in historical time section.
When specific implementation, the historical time section corresponding time cycle is different from preset period of time.Accept showing in S101 Example continues to explain, if preset period of time is on June 30,1 day to 2018 January in 2018, historical time section can be 2017 On May 30, on December 1, to 2018.Specifically, historical time section can be determined according to actual needs.
Secondly, the corresponding target ip address of the device mac address is determined, according to the target from least one IP address The regional information of IP address obtains the corresponding regional information of the device mac address.Wherein, it from least one IP address, determines The method of the corresponding target ip address of device mac address is identical as in S102, and details are not described herein.
Finally, repeating the above process, obtain in multiple equipment to be managed, the device mac address of each equipment, and every The corresponding regional information of a device mac address.In multiple equipment to be managed, the device mac address of each equipment, and it is each The corresponding regional information of device mac address, constitutes the historical relation table of comparisons.
It is corresponding to obtain target device MAC Address in the regional information for determining target ip address as an alternative embodiment After current zone information, this method further include:
According to the detected rule of setting, to the standard of the historical relation table of comparisons of pre-stored MAC Address and regional information True property is detected.
In the embodiment of the present application, the accuracy of the historical relation table of comparisons is detected, if subject to the historical relation table of comparisons True, then the regional information of target device is determined using the historical relation table of comparisons.
When specific implementation, according to the detected rule of setting, to the historical relation of pre-stored MAC Address and regional information The concrete mode that the accuracy of the table of comparisons is detected, comprising:
Firstly, selecting the MAC Address of preset quantity from the historical relation table of comparisons.
Illustratively, preset quantity, example can be determined according to the total quantity of the MAC Address stored in the historical relation table of comparisons Such as, the 80% of total quantity is selected as preset quantity, if the total quantity of the MAC Address of storage is 100, the MAC Address selected Quantity be 80, wherein preset quantity can be determined according to actual needs.It further, can be from historical relation pair It, can also be pre- according to the sequential selection of storage from the historical relation table of comparisons according to the MAC Address for randomly choosing preset quantity in table If the MAC Address of quantity, wherein the mode of selection can be determined according to the actual situation.
Secondly, in the MAC Address of detection preset quantity the corresponding regional information of each MAC Address accuracy, obtain pre- If the accuracy rate of the MAC Address of quantity.
Illustratively, available list of device addresses detects preset quantity by the list of device addresses of acquisition The accuracy of the corresponding regional information of each MAC Address, obtains the accuracy rate of the MAC Address of preset quantity, example in MAC Address Such as, if preset quantity is, to have the corresponding regional information of 8 MAC Address in 80,80 MAC Address be accurately then preset quantity MAC Address accuracy rate be 10%.Wherein, list of device addresses includes that device mac address and device mac address are corresponding Address is dispensed, list of device addresses is the device mac address and equipment MAC recorded when the manufacturer of equipment dispenses according to equipment The corresponding dispatching address in address generates.Alternatively, can also be detected by artificial mode each in the MAC Address of preset quantity The accuracy of the corresponding regional information of MAC Address.
Finally, if the accuracy rate that detection obtains is greater than the accuracy rate threshold value of setting, it is determined that the detection of the historical relation table of comparisons Pass through.
Exemplary illustration, accuracy rate threshold value can be configured according to the actual needs, for example, if accuracy rate threshold value is 80%, the accuracy rate detected is 90%, then historical relation table of comparisons detection passes through.It is if detecting obtained accuracy rate 70%, then it detects and does not pass through, the historical relation table of comparisons is inaccurate.
If the historical relation table of comparisons be it is inaccurate, extract device mac address inaccurate in the historical relation table of comparisons And corresponding regional information, according to the device mac address and corresponding regional information of the inaccuracy of extraction, analysis inaccuracy At least one corresponding IP address of device mac address real conditions.Meanwhile it changing in historical relation table of comparisons building process Historical time section, and according to the historical time section after change, according to the building process structure again of the above-mentioned historical relation table of comparisons Build the historical relation table of comparisons.Alternatively, being not to the corresponding regional information of the MAC Address detected by way of artificially changing Accurate MAC Address is modified, with the corresponding regional information change historical relation control of the MAC Address in list of device addresses The corresponding regional information of the MAC Address in table, or gone through with the corresponding regional information change of the obtained MAC Address is artificially investigated The corresponding regional information of the MAC Address in history relationship table, so that the accuracy rate of the historical relation table of comparisons is greater than the standard of setting True rate threshold value.
The embodiment of the present application proposes a kind of method of determining equipment regional information, proposes locking equipment really by the application When the method for regional information determines regional information, if due to Network Provider IP address configuration can due to routing policy change and It changes, when so that distributing to the IP address of smart machine and can change, the application can be obtained in predetermined period at least One IP address includes the IP address to change at least one IP address, determines target according at least one IP address IP address obtains current zone information, and the ground of target device is determined by the historical relation table of comparisons and current zone information Domain information improves the accuracy of the regional information of acquisition.And it will not change immediately when IP address changes in the application The regional information of target device will not frequently change the regional information of target device, but pass through the method for the application proposition The regional information for determining target device reduces the maintenance cost of equipment.
Based on the same inventive concept, it is additionally provided in the embodiment of the present application corresponding with the method for equipment regional information is determined The device for determining equipment regional information, in the principle and the embodiment of the present application solved the problems, such as due to the device in the embodiment of the present application The method for stating determining equipment regional information is similar, therefore the implementation of device may refer to the implementation of method, and it is no longer superfluous to repeat place It states.
Embodiment two
The embodiment of the present application proposes a kind of device of determining equipment regional information, and as shown in Fig. 3 a kind of determination is set The structural schematic diagram of the device of standby regional information, described device include:
Module 301 is obtained, for obtaining the historical data of target device, historical data includes target device media interviews control At least one internet protocol address that MAC Address and target device processed communicate in preset period of time;
IP address determining module 302, for determining the corresponding mesh of target device MAC Address from least one IP address Mark IP address;
It is corresponding to obtain target device MAC Address for determining the regional information of target ip address for information determination module 303 Current zone information;
Regional information obtains module 304, for corresponding current based on target device MAC Address, target device MAC Address The historical relation table of comparisons of regional information and pre-stored MAC Address and regional information obtains the region letter of target device Breath.
As an alternative embodiment, regional information obtains module, is specifically used for:
In the historical relation table of comparisons, target device MAC Address is searched;
If finding, in the historical relation table of comparisons, the corresponding history regional information of target device MAC Address is searched;
It detects current zone information and whether history regional information is identical;
If they are the same, using current zone information as the regional information of target device;
If it is different, then determining rule according to the information of setting, from current zone information and history regional information, mesh is determined The regional information of marking device.
As an alternative embodiment, regional information obtains module, also particularly useful for:
If not finding target device MAC Address in the historical relation table of comparisons, work as target device MAC Address is corresponding Regional information of the preceding regional information as target device.
As an alternative embodiment, IP address determining module is specifically used for:
For each IP address at least one IP address, the number communicated using the IP address is counted;
The most IP address of the number communicated is chosen, as the corresponding target ip address of target device MAC Address.
As an alternative embodiment, described device further include: accuracy detection module;
Accuracy detection module, for the detected rule according to setting, to pre-stored MAC Address and regional information The accuracy of the historical relation table of comparisons is detected.
As an alternative embodiment, accuracy detection module is specifically used for:
The MAC Address of preset quantity is selected from the historical relation table of comparisons;
The accuracy for detecting the corresponding regional information of each MAC Address in the MAC Address of preset quantity, obtains preset quantity MAC Address accuracy rate;
If detecting the accuracy rate threshold value that obtained accuracy rate is greater than setting, it is determined that the detection of the historical relation table of comparisons passes through.
The device of determining equipment regional information provided by the embodiments of the present application provides locking equipment really with above-described embodiment one The method of regional information technical characteristic having the same reaches identical technology effect so also can solve identical technical problem Fruit.
Embodiment three
Based on same technical concept, the embodiment of the present application also provides a kind of electronic equipment.It is this Shen referring to shown in Fig. 4 Please the structural schematic diagram of electronic equipment 400 that provides of embodiment, including processor 401, memory 402 and bus 403.Wherein, Memory 402 is executed instruction for storing, including memory 4021 and external memory 4022;Here memory 4021 is also referred to as memory Reservoir, for temporarily storing the operational data in processor 401, and the data exchanged with external memories 4022 such as hard disks, Processor 401 carries out data exchange by memory 4021 and external memory 4022, when electronic equipment 400 is run, processor It is communicated between 401 and memory 402 by bus 403, so that processor 401 is being executed to give an order:
Obtain target device historical data, the historical data include target device MAC address, with And at least one internet protocol address that the target device communicates in preset period of time;
From at least one IP address, the corresponding target ip address of target device MAC Address is determined;
The regional information for determining the target ip address obtains the corresponding current zone letter of the target device MAC Address Breath;
Based on the target device MAC Address, the corresponding current zone information of the target device MAC Address and in advance The MAC Address of storage and the historical relation table of comparisons of regional information, obtain the regional information of the target device.
In a kind of possible design, in the instruction that processor 401 may execute, further includes:
In the historical relation table of comparisons, the target device MAC Address is searched;
If finding, in the historical relation table of comparisons, the corresponding history region of the target device MAC Address is searched Information;
It detects the current zone information and whether the history regional information is identical;
If they are the same, using the current zone information as the regional information of the target device;
If it is different, then rule is determined according to the information of setting, from the current zone information and the history regional information In, determine the regional information of the target device.
In a kind of possible design, in the instruction that processor 401 may execute, further includes:
If not finding the target device MAC Address in the historical relation table of comparisons, by the target device MAC Regional information of the corresponding current zone information in address as the target device.
In a kind of possible design, in the instruction that processor 401 may execute, further includes:
For each IP address at least one IP address, the number communicated using the IP address is counted;
The most IP address of the number communicated is chosen, as the corresponding Target IP of the target device MAC Address Location.
In a kind of possible design, in the instruction that processor 401 may execute, further includes:
According to the detected rule of setting, to the standard of the historical relation table of comparisons of pre-stored MAC Address and regional information True property is detected.
In a kind of possible design, in the instruction that processor 401 may execute, further includes:
The MAC Address of preset quantity is selected from the historical relation table of comparisons;
The accuracy for detecting the corresponding regional information of each MAC Address in the MAC Address of preset quantity obtains described default The accuracy rate of the MAC Address of quantity;
If detecting the accuracy rate threshold value that the obtained accuracy rate is greater than setting, it is determined that the historical relation table of comparisons inspection Survey passes through.
Example IV
The embodiment of the present application also provides a kind of computer readable storage medium, is stored on the computer readable storage medium Computer program, the computer program execute any of the above-described determining equipment region letter as described in the examples when being run by processor The step of method of breath.
Specifically, which can be general storage medium, such as mobile disk, hard disk, on the storage medium Computer program when being run, the step of being able to carry out the method for above-mentioned determining equipment regional information, to improve acquisition The accuracy of equipment regional information reduces error, and reduces the maintenance cost of the regional information of equipment.
It is determined the computer program product of the method for equipment regional information provided by the embodiment of the present application, including deposits The computer readable storage medium of the executable non-volatile program code of processor, the instruction that said program code includes are stored up It can be used for executing previous methods method as described in the examples, specific implementation can be found in embodiment of the method, and details are not described herein.
It is apparent to those skilled in the art that for convenience and simplicity of description, the system of foregoing description, The specific work process of device and unit, can refer to corresponding processes in the foregoing method embodiment, and details are not described herein.
In several embodiments provided herein, it should be understood that disclosed systems, devices and methods, it can be with It realizes by another way.The apparatus embodiments described above are merely exemplary, for example, the division of the unit, Only a kind of logical function partition, there may be another division manner in actual implementation, in another example, multiple units or components can To combine or be desirably integrated into another system, or some features can be ignored or not executed.Another point, it is shown or beg for The mutual coupling, direct-coupling or communication connection of opinion can be through some communication interfaces, device or unit it is indirect Coupling or communication connection can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme 's.
It, can also be in addition, each functional unit in each embodiment of the application can integrate in one processing unit It is that each unit physically exists alone, can also be integrated in one unit with two or more units.
It, can be with if the function is realized in the form of SFU software functional unit and when sold or used as an independent product It is stored in the executable non-volatile computer-readable storage medium of a processor.Based on this understanding, the application Technical solution substantially the part of the part that contributes to existing technology or the technical solution can be with software in other words The form of product embodies, which is stored in a storage medium, including some instructions use so that One computer equipment (can be personal computer, server or the network equipment etc.) executes each embodiment institute of the application State all or part of the steps of method.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic or disk etc. is various to deposit Store up the medium of program code.
Finally, it should be noted that embodiment described above, the only specific embodiment of the application, to illustrate the application Technical solution, rather than its limitations, the protection scope of the application is not limited thereto, although with reference to the foregoing embodiments to this Shen It please be described in detail, those skilled in the art should understand that: anyone skilled in the art Within the technical scope of the present application, it can still modify to technical solution documented by previous embodiment or can be light It is readily conceivable that variation or equivalent replacement of some of the technical features;And these modifications, variation or replacement, do not make The essence of corresponding technical solution is detached from the spirit and scope of the embodiment of the present application technical solution, should all cover the protection in the application Within the scope of.Therefore, the protection scope of the application shall be subject to the protection scope of the claim.

Claims (10)

1. a kind of method of determining equipment regional information, which is characterized in that the described method includes:
The historical data of target device is obtained, the historical data includes target device MAC address, Yi Jisuo State at least one internet protocol address that target device communicates in preset period of time;
From at least one IP address, the corresponding target ip address of target device MAC Address is determined;
The regional information for determining the target ip address obtains the corresponding current zone information of the target device MAC Address;
Based on the target device MAC Address, the corresponding current zone information of the target device MAC Address and it is stored in advance MAC Address and regional information the historical relation table of comparisons, obtain the regional information of the target device.
2. the method according to claim 1, wherein described be based on the target device MAC Address, the target The historical relation table of comparisons of the corresponding current zone information of device mac address and pre-stored MAC Address and regional information, Obtain the regional information of the target device, comprising:
In the historical relation table of comparisons, the target device MAC Address is searched;
If finding, in the historical relation table of comparisons, the corresponding history region letter of the target device MAC Address is searched Breath;
It detects the current zone information and whether the history regional information is identical;
If they are the same, using the current zone information as the regional information of the target device;
If it is different, then determining rule according to the information of setting, from the current zone information and the history regional information, really The regional information of the fixed target device.
3. according to the method described in claim 2, it is characterized in that, the method also includes:
If not finding the target device MAC Address in the historical relation table of comparisons, by the target device MAC Address Regional information of the corresponding current zone information as the target device.
4. determining target device the method according to claim 1, wherein described from least one IP address The corresponding target ip address of MAC Address, comprising:
For each IP address at least one IP address, the number communicated using the IP address is counted;
The most IP address of the number communicated is chosen, as the corresponding target ip address of the target device MAC Address.
5. the method according to claim 1, wherein being obtained in the regional information for determining the target ip address After the corresponding current zone information of the target device MAC Address, the method also includes:
According to the detected rule of setting, to the accuracy of the historical relation table of comparisons of pre-stored MAC Address and regional information It is detected.
6. according to the method described in claim 5, it is characterized in that, the detected rule according to setting, to pre-stored The accuracy of the historical relation table of comparisons of MAC Address and regional information is detected, comprising:
The MAC Address of preset quantity is selected from the historical relation table of comparisons;
The accuracy for detecting the corresponding regional information of each MAC Address in the MAC Address of preset quantity, obtains the preset quantity MAC Address accuracy rate;
If detecting the accuracy rate threshold value that the obtained accuracy rate is greater than setting, it is determined that the historical relation table of comparisons detection is logical It crosses.
7. a kind of device of determining equipment regional information, which is characterized in that described device includes:
Module is obtained, for obtaining the historical data of target device, the historical data includes target device media access control At least one internet protocol address that MAC Address and the target device communicate in preset period of time;
IP address determining module is used for from least one IP address, with determining the corresponding Target IP of target device MAC Address Location;
It is corresponding to obtain the target device MAC Address for determining the regional information of the target ip address for information determination module Current zone information;
Regional information obtains module, for based on the target device MAC Address, the target device MAC Address is corresponding works as The historical relation table of comparisons of preceding regional information and pre-stored MAC Address and regional information, obtains the target device Regional information.
8. device according to claim 7, which is characterized in that the regional information obtains module, is specifically used for:
In the historical relation table of comparisons, the target device MAC Address is searched;
If finding, in the historical relation table of comparisons, the corresponding history region letter of the target device MAC Address is searched Breath;
It detects the current zone information and whether the history regional information is identical;
If they are the same, using the current zone information as the regional information of the target device;
If it is different, then determining rule according to the information of setting, from the current zone information and the history regional information, really The regional information of the fixed target device.
9. a kind of electronic equipment characterized by comprising processor, memory and bus, the memory are stored with the place The executable machine readable instructions of device are managed, when electronic equipment operation, pass through bus between the processor and the memory Communication, executing the locking equipment really as described in claim 1 to 6 is any when the machine readable instructions are executed by the processor The step of method of domain information.
10. a kind of computer readable storage medium, which is characterized in that be stored with computer journey on the computer readable storage medium Sequence executes the side of locking equipment regional information really as described in claim 1 to 6 is any when the computer program is run by processor The step of method.
CN201910467141.7A 2019-05-31 2019-05-31 Method and device for determining equipment regional information Active CN110138892B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910467141.7A CN110138892B (en) 2019-05-31 2019-05-31 Method and device for determining equipment regional information

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910467141.7A CN110138892B (en) 2019-05-31 2019-05-31 Method and device for determining equipment regional information

Publications (2)

Publication Number Publication Date
CN110138892A true CN110138892A (en) 2019-08-16
CN110138892B CN110138892B (en) 2021-12-07

Family

ID=67583301

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910467141.7A Active CN110138892B (en) 2019-05-31 2019-05-31 Method and device for determining equipment regional information

Country Status (1)

Country Link
CN (1) CN110138892B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110661903A (en) * 2019-10-12 2020-01-07 苏州浪潮智能科技有限公司 Cloud platform route management method and device
CN113516503A (en) * 2021-05-19 2021-10-19 湖南快乐阳光互动娱乐传媒有限公司 Advertisement delivery region calibration method and related equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105100292A (en) * 2014-05-12 2015-11-25 阿里巴巴集团控股有限公司 Method and apparatus of determining position of terminal
CN106997544A (en) * 2016-01-25 2017-08-01 秒针信息技术有限公司 A kind of method and apparatus for monitoring outdoor advertising
CN108282508A (en) * 2017-01-06 2018-07-13 阿里巴巴集团控股有限公司 Determination method and device, information-pushing method and the device in geographical location
CN109218170A (en) * 2018-10-18 2019-01-15 杭州安恒信息技术股份有限公司 A kind of IP address-based mail abnormal login detecting method and system

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105100292A (en) * 2014-05-12 2015-11-25 阿里巴巴集团控股有限公司 Method and apparatus of determining position of terminal
US20170127228A1 (en) * 2014-05-12 2017-05-04 Alibaba Group Holding Limited Method, apparatus, and system for determining a location of a terminal
CN106997544A (en) * 2016-01-25 2017-08-01 秒针信息技术有限公司 A kind of method and apparatus for monitoring outdoor advertising
CN108282508A (en) * 2017-01-06 2018-07-13 阿里巴巴集团控股有限公司 Determination method and device, information-pushing method and the device in geographical location
CN109218170A (en) * 2018-10-18 2019-01-15 杭州安恒信息技术股份有限公司 A kind of IP address-based mail abnormal login detecting method and system

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110661903A (en) * 2019-10-12 2020-01-07 苏州浪潮智能科技有限公司 Cloud platform route management method and device
CN110661903B (en) * 2019-10-12 2022-12-06 苏州浪潮智能科技有限公司 Cloud platform route management method and device
CN113516503A (en) * 2021-05-19 2021-10-19 湖南快乐阳光互动娱乐传媒有限公司 Advertisement delivery region calibration method and related equipment
CN113516503B (en) * 2021-05-19 2022-08-16 湖南快乐阳光互动娱乐传媒有限公司 Advertisement delivery region calibration method and related equipment

Also Published As

Publication number Publication date
CN110138892B (en) 2021-12-07

Similar Documents

Publication Publication Date Title
CN106529883B (en) Distribute the method and device of data object
CN103347259B (en) A kind of flow prompt method and system
CN109213597A (en) Resource allocation methods, device, computer equipment and computer readable storage medium
CN107404481B (en) User information recognition methods and device
Mitzenmacher Analyzing distributed join-idle-queue: A fluid limit approach
CN109840533A (en) A kind of applied topology figure recognition methods and device
CN108429701A (en) network acceleration system
US8478688B1 (en) Rapid transaction processing
CN107273290A (en) The A/B method of testings and device of a kind of Page Service
CN110110201A (en) A kind of content recommendation method and system
CN110138892A (en) Determine the method and device of equipment regional information
CN111598487A (en) Data processing and model training method and device, electronic equipment and storage medium
CN105243006B (en) The implementation method and device of the setting of flow layer and flux experiment based on flux experiment
CN110162270A (en) Date storage method, memory node and medium based on distributed memory system
CN103853500A (en) Method, device and system for distributing mass data
CN111127154A (en) Order processing method, device, server and nonvolatile storage medium
CN110413926A (en) A kind of questionnaire method and device
CN109446791A (en) New equipment recognition methods, device, server and computer readable storage medium
CN108153758A (en) A kind of data accumulation method, apparatus and electronic equipment
CN105872082B (en) Fine granularity resource response system based on container cluster load-balancing algorithm
CN106294364A (en) Realize the method and apparatus that web crawlers captures webpage
CN106296279A (en) Advertisement placement method and device
CN105847140A (en) File distribution task generation method and system
CN109324914A (en) Service calling method, service call device and central server
CN112073454B (en) Resource distribution method and device and electronic equipment

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