Send Netdot-devel mailing list submissions to
        [email protected]

To subscribe or unsubscribe via the World Wide Web, visit
        https://osl.uoregon.edu/mailman/listinfo/netdot-devel
or, via email, send a message with subject or body 'help' to
        [email protected]

You can reach the person managing the list at
        [email protected]

When replying, please edit your Subject line so it is more specific
than "Re: Contents of Netdot-devel digest..."


Today's Topics:

   1. [Netdot - Feature #1774] (Resolved) Add strategy  config for
      SUBNET_AUTO_RESERVE => SUBNET_AUTO_RESERVE_STRATEGY
      ([email protected])
   2. [SCM] Netdot branch netdot-1.0 updated.
      netdot-1.0.4-101-g42b2bdb ([email protected])
   3. [SCM] Netdot branch master updated.       netdot-1.0.4-101-g42b2bdb
      ([email protected])
   4. [Netdot - Feature #1747] (Resolved) config option to      disable
      'discovered' ipblocks on IPv6 subnets ([email protected])
   5. [Netdot - Feature #1753] (Resolved) Add DNS lookup        to search
      ([email protected])


----------------------------------------------------------------------

Message: 1
Date: Thu, 3 Oct 2013 10:05:56 -0700
From: [email protected]
Subject: [Netdot-devel] [Netdot - Feature #1774] (Resolved) Add
        strategy        config for SUBNET_AUTO_RESERVE =>
        SUBNET_AUTO_RESERVE_STRATEGY
To: [email protected], [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8


Issue #1774 has been updated by Carlos Vicente.

Category set to IPManagement
Status changed from New to Resolved
Assignee set to Carlos Vicente
Target version set to 1.0.5
Resolution set to fixed


----------------------------------------
Feature #1774: Add strategy config for SUBNET_AUTO_RESERVE => 
SUBNET_AUTO_RESERVE_STRATEGY
https://osl.uoregon.edu/redmine/issues/1774#change-3127

Author: Wim Vandersmissen
Status: Resolved
Priority: Normal
Assignee: Carlos Vicente
Category: IPManagement
Target version: 1.0.5
Resolution: fixed


Add a config option SUBNET_AUTO_RESERVE_STRATEGY
This allows to set the strategy for reservations in the subnet.
Eg, our routers are on the last addresses of the subnet, but we give out 
addresses starting in the beginning of the range.

So we now set in Site.conf:

IP_ALLOCATION_STRATEGY => 'first',
SUBNET_AUTO_RESERVE_STRATEGY => 'last',

simple patch in attach


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://osl.uoregon.edu/redmine/my/account


------------------------------

Message: 2
Date: Thu, 3 Oct 2013 10:36:01 -0700
From: [email protected]
Subject: [Netdot-devel] [SCM] Netdot branch netdot-1.0 updated.
        netdot-1.0.4-101-g42b2bdb
To: [email protected]
Message-ID: <[email protected]>

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Netdot".

The branch, netdot-1.0 has been updated
       via  42b2bdb98fdf53e3249324ea07bc53bc8260eb51 (commit)
       via  eda37f7c5ff583f1f65610eaede1cd693c3e7b99 (commit)
       via  575fd9e5aee11a7e072455877445c7515d1fca52 (commit)
       via  24db307604919b588f56be3b1d2e06a9dc9a0dc2 (commit)
      from  7f79fe1a93de5c3ff2ed2fb7f7589532a64dc186 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 42b2bdb98fdf53e3249324ea07bc53bc8260eb51
Author: Carlos Vicente <[email protected]>
Date:   Thu Oct 3 13:35:50 2013 -0400

    Feature #1747 (config option to disable 'discovered' ipblocks on IPv6 
subnets)

diff --git a/etc/Default.conf b/etc/Default.conf
index 88e3c3b..652f478 100644
--- a/etc/Default.conf
+++ b/etc/Default.conf
@@ -64,6 +64,9 @@ ROOT_BLOCK_SHOW_MAX => 50,
 #
 SHOW_COUNT_THRESHOLD => 65536,
 
+# Show "discovered" IPv6 addresses as children on ip.html
+IPV6_HIDE_DISCOVERED => 1,
+
 # Web-based whois server URL for AS number lookups from Netdot's device pages
 # Only available substitution is <ASNUMBER>
 BGP_AS_WHOIS_URL => 
"http://www.radb.net/query/?keywords=AS<ASNUMBER>&submit=Query",
diff --git a/lib/Netdot/Model/Ipblock.pm b/lib/Netdot/Model/Ipblock.pm
index 40b0f1d..a54dc38 100644
--- a/lib/Netdot/Model/Ipblock.pm
+++ b/lib/Netdot/Model/Ipblock.pm
@@ -2883,8 +2883,11 @@ sub get_addresses_by {
     LEFT JOIN (rraddr CROSS JOIN rr) ON (rraddr.ipblock=ipblock.id AND 
rraddr.rr=rr.id)
     LEFT JOIN entity ON (ipblock.used_by=entity.id)
     WHERE     ipblock.parent=$id
-      AND     ipblock.status=ipblockstatus.id
-    GROUP BY  ipblock.id
+      AND     ipblock.status=ipblockstatus.id ";
+    if ( ($self->version == 6) && ($self->config->get('IPV6_HIDE_DISCOVERED')) 
) {
+       $query.=" AND     ipblockstatus.name != \"Discovered\" ";
+    }
+    $query .= "GROUP BY ipblock.id 
     ORDER BY  $sort2field{$sort}";
 
     my $dbh  = $self->db_Main();

commit eda37f7c5ff583f1f65610eaede1cd693c3e7b99
Author: Carlos Vicente <[email protected]>
Date:   Thu Oct 3 13:04:13 2013 -0400

    Feature #1774 (Add strategy config for SUBNET_AUTO_RESERVE => 
SUBNET_AUTO_RESERVE_STRATEGY)

diff --git a/etc/Default.conf b/etc/Default.conf
index fbb6b65..88e3c3b 100644
--- a/etc/Default.conf
+++ b/etc/Default.conf
@@ -557,6 +557,10 @@ IP_ALLOCATION_STRATEGY => 'first',
 # be the first or last N addresses
 SUBNET_AUTO_RESERVE => 0,
 
+# When using SUBNET_AUTO_RESERVE, start with either the first or
+# last address in the given subnet
+SUBNET_AUTO_RESERVE_STRATEGY => 'first',
+
 # Subnet Usage Monitoring
 # The minimum threshold of remaining space before a notification is
 # sent.  That is, when the available free space reaches this percentage,
diff --git a/lib/Netdot/Model/Ipblock.pm b/lib/Netdot/Model/Ipblock.pm
index 442632a..40b0f1d 100644
--- a/lib/Netdot/Model/Ipblock.pm
+++ b/lib/Netdot/Model/Ipblock.pm
@@ -763,7 +763,8 @@ sub reserve_first_n {
     my $num = $class->config->get('SUBNET_AUTO_RESERVE');
     if ( $num && $num < $self->num_addr ){
        for ( 1..$num ){
-           my $addr = $self->get_next_free();
+           my $strategy = $class->config->get('SUBNET_AUTO_RESERVE_STRATEGY');
+           my $addr = $self->get_next_free(strategy=>$strategy);
            eval {
                $class->insert({address=>$addr, status=>'Reserved', 
                                parent=>$self->id, no_update_tree=>1,

commit 575fd9e5aee11a7e072455877445c7515d1fca52
Author: Carlos Vicente <[email protected]>
Date:   Thu Oct 3 12:55:49 2013 -0400

    Fix for bug #1772 (4th hextet isn't visible in add_host.html when all 
zeroes)

diff --git a/htdocs/user_management/add_host.html 
b/htdocs/user_management/add_host.html
index 072f2cb..4d8da56 100644
--- a/htdocs/user_management/add_host.html
+++ b/htdocs/user_management/add_host.html
@@ -112,6 +112,10 @@ if ( $submit ){
                }
                my $addr = $block->address;
                $addr =~ s/:$//;
+               my $number =()= $addr =~ /\:/gi;
+               if ( $number == 3 ) {
+                   $addr.="0:";
+               }
                $addr .= join(':', map { $parts{$_} } sort { $a <=> $b } keys 
%parts);
                $args{address} = $addr;
            }
@@ -262,6 +266,10 @@ function showIPv6Input(selectObj, Layer){
 %                       }
 %                        my $txt = join ':', @txt;
 %                       $blockaddr =~ s/:$//;
+%                        my $number =()= $blockaddr =~ /\:/gi;
+%                        if ( $number == 3 ) {
+%                            $blockaddr.="0:";
+%                        }
 %                        print $blockaddr . $txt;
 %                     }else{
                           <input type="text" name="address" class="longtxt" 
value=""> 

commit 24db307604919b588f56be3b1d2e06a9dc9a0dc2
Author: Carlos Vicente <[email protected]>
Date:   Thu Oct 3 12:49:36 2013 -0400

    Fix for Bug #1773 (no failover support for shared-networks in DHCP)

diff --git a/lib/Netdot/Model/DhcpScope.pm b/lib/Netdot/Model/DhcpScope.pm
index 1177cc1..066ec29 100644
--- a/lib/Netdot/Model/DhcpScope.pm
+++ b/lib/Netdot/Model/DhcpScope.pm
@@ -113,10 +113,19 @@ sub insert {
        }
     }elsif ( $scope->type->name eq 'shared-network' ){
        # Shared subnets need to point to the new shared-network scope 
+       my $failoverstatus = 0;
        foreach my $s ( @shared_subnets ){
            my $subnet_scope = $s->dhcp_scopes->first;
            $subnet_scope->update({container=>$scope, 
                                   ipblock=>$s});
+           if ( $subnet_scope->enable_failover == 1 ) {
+               $failoverstatus = 1;
+           }
+       }
+       if ( $failoverstatus ){
+           my $failover_peer = $scope->container->failover_peer || 'dhcp-peer';
+           $scope->SUPER::update({enable_failover => 1, 
+                                  failover_peer   => $failover_peer});
        }
     }
     $scope->_update_attributes($attributes) if $attributes;

-----------------------------------------------------------------------

Summary of changes:
 etc/Default.conf                     |    7 +++++++
 htdocs/user_management/add_host.html |    8 ++++++++
 lib/Netdot/Model/DhcpScope.pm        |    9 +++++++++
 lib/Netdot/Model/Ipblock.pm          |   10 +++++++---
 4 files changed, 31 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
Netdot


------------------------------

Message: 3
Date: Thu, 3 Oct 2013 10:36:33 -0700
From: [email protected]
Subject: [Netdot-devel] [SCM] Netdot branch master updated.
        netdot-1.0.4-101-g42b2bdb
To: [email protected]
Message-ID: <[email protected]>

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Netdot".

The branch, master has been updated
       via  42b2bdb98fdf53e3249324ea07bc53bc8260eb51 (commit)
       via  eda37f7c5ff583f1f65610eaede1cd693c3e7b99 (commit)
       via  575fd9e5aee11a7e072455877445c7515d1fca52 (commit)
       via  24db307604919b588f56be3b1d2e06a9dc9a0dc2 (commit)
       via  7f79fe1a93de5c3ff2ed2fb7f7589532a64dc186 (commit)
      from  b41c636d7adaccd7a10769104fdcee85ab5648f4 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 etc/Default.conf                     |   11 +++++++++++
 htdocs/management/subnet.mhtml       |   14 ++++++++++++++
 htdocs/user_management/add_host.html |    8 ++++++++
 lib/Netdot/Model/DhcpScope.pm        |    9 +++++++++
 lib/Netdot/Model/Ipblock.pm          |   10 +++++++---
 lib/Netdot/Model/RR.pm               |    8 +++++++-
 6 files changed, 56 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
Netdot


------------------------------

Message: 4
Date: Thu, 3 Oct 2013 10:37:10 -0700
From: [email protected]
Subject: [Netdot-devel] [Netdot - Feature #1747] (Resolved) config
        option to       disable 'discovered' ipblocks on IPv6 subnets
To: [email protected], [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8


Issue #1747 has been updated by Carlos Vicente.

Category set to UserInterface
Status changed from New to Resolved
Assignee set to Carlos Vicente
Target version set to 1.0.5
Resolution set to fixed


----------------------------------------
Feature #1747: config option to disable 'discovered' ipblocks on IPv6 subnets
https://osl.uoregon.edu/redmine/issues/1747#change-3128

Author: Wim Vandersmissen
Status: Resolved
Priority: Normal
Assignee: Carlos Vicente
Category: UserInterface
Target version: 1.0.5
Resolution: fixed


IPv6 subnets can contain lots of hosts, especially if you're using SLAAC.
Getting a listing of those discovered addresses can be painfully slow (and I 
think useless ?) 
You still need to find those hosts ofcourse.

proposed patch:
Add this variable to the Default.conf / Site.conf
<pre>
# show discovered ipv6 addresses as children on ip.html
IPV6_HIDE_DISCOVERED => 1
</pre>

<pre>
--- lib.devel/Netdot/Model/Ipblock.pm   2013-03-28 20:25:33.000000000 +0100
+++ lib/Netdot/Model/Ipblock.pm 2012-12-05 17:35:01.000000000 +0100
@@ -2877,11 +2877,8 @@
     LEFT JOIN (rraddr CROSS JOIN rr) ON (rraddr.ipblock=ipblock.id AND 
rraddr.rr=rr.id)
     LEFT JOIN entity ON (ipblock.used_by=entity.id)
     WHERE     ipblock.parent=$id
-      AND     ipblock.status=ipblockstatus.id ";
-    if ( ($self->config->get('IPV6_HIDE_DISCOVERED') && ($self->version == 6)) 
) {
-       $query.=" AND     ipblockstatus.name != \"Discovered\" ";
-    }
-    $query.="GROUP BY  ipblock.id
+      AND     ipblock.status=ipblockstatus.id
+    GROUP BY  ipblock.id
     ORDER BY  $sort2field{$sort}";

     my $dbh  = $self->db_Main();
</pre>





-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://osl.uoregon.edu/redmine/my/account


------------------------------

Message: 5
Date: Thu, 3 Oct 2013 10:41:01 -0700
From: [email protected]
Subject: [Netdot-devel] [Netdot - Feature #1753] (Resolved) Add DNS
        lookup  to search
To: [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8


Issue #1753 has been updated by Carlos Vicente.

Status changed from New to Resolved
Resolution set to fixed


----------------------------------------
Feature #1753: Add DNS lookup to  search
https://osl.uoregon.edu/redmine/issues/1753#change-3129

Author: Carlos Vicente
Status: Resolved
Priority: Normal
Assignee: Carlos Vicente
Category: DeviceManagement
Target version: 1.0.5
Resolution: fixed


When looking up a host by name in the Device search box, if the name is not in 
Netdot's database (because Netdot is not managing DNS), the search fails.
Add a line to do a DNS lookup and then look up the IP in Netdot.


-- 
You have received this notification because you have either subscribed to it, 
or are involved in it.
To change your notification preferences, please click here: 
http://osl.uoregon.edu/redmine/my/account


------------------------------

_______________________________________________
Netdot-devel mailing list
[email protected]
https://osl.uoregon.edu/mailman/listinfo/netdot-devel


End of Netdot-devel Digest, Vol 79, Issue 5
*******************************************

Reply via email to