Skip to Content.
Sympa Menu

perfsonar-user - [perfsonar-user] Re: Lookup Service IP versus hostname

Subject: perfSONAR User Q&A and Other Discussion

List archive

[perfsonar-user] Re: Lookup Service IP versus hostname


Chronological Thread 
  • From: Ryan Hitch <>
  • To: "" <>
  • Subject: [perfsonar-user] Re: Lookup Service IP versus hostname
  • Date: Fri, 29 Apr 2016 14:36:35 +0000 (UTC)

I was able to remove the duplicate entries by going into mongodb and deleting them from the services collection in the lookup database, and then restarting the lookup-service.
I am not sure why the lookup-service was not removing some of these entries as their "expires" field was past the expiration date.

The duplicate entries were created due to a DHCP/DNS issue where some clients registered with their IP address, then were able to later register by hostname when DHCP/DNS was again working properly.  I am not sure how they determine what hostname/IP address to use using the ls_registration service, but the lookup-service seems to have some issue with removing "expired" entries when there are (2) or more registrations for the same client host.  Anyone able to shed light on this?


Best,
Ryan


On Tuesday, April 26, 2016 7:11 AM, Ryan Hitch <> wrote:


I also have one client entry that has (2) lookup-service registrations (one by IP and another by hostname):
[user@dash]/usr/lib/perfsonar/bin/lookup_hosts --input /etc/perfsonar/meshconfig-lookuphosts.conf --output /var/www/html/dynamic_host_list.json
Resulting mesh is invalid: Multiple hosts match pas05.perf.sonar at /usr/lib/perfsonar/bin/../lib/perfSONAR_PS/MeshConfig/Config/Mesh.pm line 58.

One of these entries has an expiration date several days ago, but for some reason has not been cleaned out of the look-service database:
[user@dash lib]# perl query.pl
$VAR1 = bless( {
                 'RECORD_HASH' => {
                                    'group-domains' => [
                                                         'perf.sonar'
                                                       ],
                                    'ttl' => [],
                                    'interface-capacity' => [
                                                              '1000000000'
                                                            ],
                                    'interface-mac' => [
                                                         '20:47:37:5F:5F:DC'
                                                       ],
                                    'interface-mtu' => [
                                                         '1500'
                                                       ],
                                    'client-uuid' => [
                                                       '421d374f-1045-49e1-92ef-c03904e04e45'
                                                     ],
                                    'state' => 'renewed',
                                    'uri' => 'lookup/interface/665e4963-4ded-437a-ad27-5f7e35c5d176',
                                    'interface-name' => [
                                                          'em1'
                                                        ],
                                    'type' => [
                                                'interface'
                                              ],
                                    'interface-addresses' => [
                                                               '192.168.188.5'
                                                             ],
                                    'expires' => '2016-04-20T17:59:58.806Z'
                                  }
               }, 'SimpleLookupService::Records::Network::Interface' );

How can I remove these duplicate registrations and stale entries?
Any help is greatly appreciated.

Thanks!
Ryan
On Monday, April 25, 2016 2:25 PM, Ryan Hitch <> wrote:


Hi,
 
I am setting up a dynamic mesh with a private lookup service (which is also running Maddash and CMA).
Some of my clients register with this server using their IP address versus hostname, and I occasionally get clients registered twice.
For example, I see 192.168.188.5 and its hostname (ps5.node.sonar) when I do:
curl -v -H "Content-Type: application/js" -X GET http://localhost:8090/lookup/records/?type=service
These also show up as both hostname and IP in Maddash.
 
How can I get nodes to register consistently by hostname?
How can I remove the IP entries from my private lookup server?
 
Thanks!
Ryan







Archive powered by MHonArc 2.6.16.

Top of Page