Send netdisco-users mailing list submissions to
        [email protected]

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.sourceforge.net/lists/listinfo/netdisco-users
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 netdisco-users digest..."
Today's Topics:

   1. Netdisco 2 Plugin System (Daniel Tuecks)
   2. Re: Netdisco 2 Questions (Nikolaos Milas)
   3. Re: Netdisco 2 Questions (Oliver Gorwits)
   4. Re: Netdisco 2 Questions (Nikolaos Milas)
   5. ND2 Check_userlog settings (Nikolaos Milas)
   6. Re: ND2 Check_userlog settings (Oliver Gorwits)
   7. [OT] vacancy in my team (Oliver Gorwits)
   8. Issue with Network Map (Daniel Tuecks)
--- Begin Message ---
Hello Netdisco Developers,

In the last few days, I've played around with the Netdisco 2 plugin system.
First of all I have to say that it's just nice to see how little is
necessary to get a plugin up and running - great work! Nevertheless I have
two questions:

- How will Netdisco 2 (or Dancer) every use a custom template path?

I don't get this. I tried to write a small plugin that uses its own
templates located in /opt/netdisco/dt, so I registered a custom template
path. In order to do this, I set my template path like this:

----

package App::Netdisco::Web::Plugin::DT;

use Dancer ':syntax';
use Dancer::Plugin::DBIC;
use Dancer::Plugin::Auth::Extensible;
use App::Netdisco::Web::Plugin;
use File::ShareDir 'dist_dir';

#register_template_path( dist_dir( 'dt' ));
register_template_path( '/opt/netdisco/dt' );

----

If my custom path is set to register_template_path( '/opt/netdisco/dt' ), I
can see that my path is added to the include path array
(Dancer::Template->engine->config->{INCLUDE_PATH}) (in
Dancer/Template/Abstract.pm, 'template'). But in the subroutine 'view'
(returns the actual view path), $views_dir is fetched from
Dancer::App->current->setting('views').
Dancer::App->current->setting('views') is a string and not a list that
contains '/opt/netdisco/perl5/lib/perl5/auto/share/dist/App-Netdisco/views'
only. So my template will never be found... Did I do something wrong?

- Does Netdisco or Dancer provide any way to 'auto-login' with a pre-shared
key?

I've written a very simple REST Webservice plugin that basically is a
'netdisco-do-webservice'. Now I wonder how to get authentication running.
The problem is that a potential rest client will not be able to login to
the website first. I worked around this problem by enabling X-REMOTE_USER
and setting the http header to 'X-REMOTE_USER: admin'. Is there maybe a
better way to do authentication in netdisco/dancer without patching the
Netdisco source code? It would be nice to have something like a
'shared-key' based auth ...

Another thing that came to my mind are custom-roles. Right now netdisco
only has a few pre-defined roles. Maybe it would be helpful if a plugin
could use its own roles. For example my webservice user could get a
'webservice' role, so the webservice would not be available to all the GUI
admins/users. But I fear this would most likely require a db-schema
extension, so this will not be possible any time soon, right?


Regards,
Daniel

--- End Message ---
--- Begin Message ---
On 2/12/2013 7:20 μμ, Nikolaos Milas wrote:

I have recently started using/testing Netdisco 2 and I would like to ask:

1. Is there a way to get IP Address reports, similar to those available
in Netdisco 1.x ("Report IP Inventory")? This functionality is important
to us.

This is now my only remaining question (see below), so please let me know whether such a report is or will be available in ND2.

When I issue commands (like "Discover All") from the web GUI, the jobs
seem to be queued forever (in the Job Queue page). Things work fine when
commands are issued from the CLI.

2. Why jobs are not run when issued from the web page, but stay queued?
How can we force the execution of these jobs?

3. Is there a way to perform full network auto discovery starting from
routers, i.e. can we provide the discovery starting points (routers) and
let ND2 to discover/macsuck all connected devices automatically? (If I
remember right -it's been long since I last did it-, this works in ND 1.)

I found that netdisco-daemon was not running, so these problems were expected. Once I started it, everything worked fine.

Thanks for the great app.

Best regards,
Nick



--- End Message ---
--- Begin Message ---
Hi Nick,

On 2013-12-04 08:18, Nikolaos Milas wrote:
On 2/12/2013 7:20 μμ, Nikolaos Milas wrote:

I have recently started using/testing Netdisco 2 and I would like to ask:

1. Is there a way to get IP Address reports, similar to those available in Netdisco 1.x ("Report IP Inventory")? This functionality is important
to us.

This is now my only remaining question (see below), so please let me
know whether such a report is or will be available in ND2.

There's an open tracker item to implement this, which effectively means it's on the TODO list:

   http://sourceforge.net/p/netdisco/netdisco2/50/

Other than that, I'll add that it's our intention to implement all existing reports in Netdisco 2 :-)

On this topic Eric has done fantastic work so far, but there's still a lot to do... see the word "report" featuring in our commit log:

http://sourceforge.net/p/netdisco/netdisco-ng/ci/6bb2e3819f3196798e56554e1a8f6ea224833cdf/log/?path=

Patches welcome!

regards,
oliver.


When I issue commands (like "Discover All") from the web GUI, the jobs seem to be queued forever (in the Job Queue page). Things work fine when
commands are issued from the CLI.

2. Why jobs are not run when issued from the web page, but stay queued?
How can we force the execution of these jobs?

3. Is there a way to perform full network auto discovery starting from routers, i.e. can we provide the discovery starting points (routers) and let ND2 to discover/macsuck all connected devices automatically? (If I remember right -it's been long since I last did it-, this works in ND 1.)

I found that netdisco-daemon was not running, so these problems were
expected. Once I started it, everything worked fine.

Thanks for the great app.

Best regards,
Nick


------------------------------------------------------------------------------
Sponsored by Intel(R) XDK
Develop, test and display web and hybrid apps with a single code base.
Download it for free now!

http://pubads.g.doubleclick.net/gampad/clk?id=111408631&iu=/4140/ostg.clktrk
_______________________________________________
Netdisco mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/netdisco-users




--- End Message ---
--- Begin Message ---
On 4/12/2013 4:19 μμ, Oliver Gorwits wrote:

Other than that, I'll add that it's our intention to implement all
existing reports in Netdisco 2:-)

On this topic Eric has done fantastic work so far, but there's still a
lot to do...

Thank you for the update.

We do hope you can move this forward!

Nick



--- End Message ---
--- Begin Message --- I was wondering how we can adjust the refresh time for the Job Queue page (on the ND2 Web GUI).

The problem is that it refreshes so often, that I can hardly even read something on the page!

I have tried to find a setting to adjust the refresh time interval but I haven't been able to locate an appropriate setting. "check_userlog" should simply disable the refresh.

Please let me know how I can adjust it.

Thanks,
Nick



--- End Message ---
--- Begin Message ---
On 2013-12-04 22:20, Nikolaos Milas wrote:
I was wondering how we can adjust the refresh time for the Job Queue
page (on the ND2 Web GUI).

The problem is that it refreshes so often, that I can hardly even read
something on the page!

There's no user setting for this - the timer value is hard-coded. I'd welcome a tracker item for this as a feature request! There's definitely room for improvement on this page.

   http://sourceforge.net/p/netdisco/netdisco2/?source=navbar

There's a small "pause" button in the top right of the display, in case you didn't notice it.

regards,
oliver.



--- End Message ---
--- Begin Message ---
Hi folks,

I figure that interest in LAN, WAN, data centre, a bit of Linux, and coming from somewhere in Europe, might have some crossover with people on this list. Please take a look at our vacancy and drop me a line if you have any questions:

   http://www.jobs.ac.uk/job/AHS124/network-analyst/

p.s. and yes, we do run Netdisco 2 in production :-)

regards,
oliver.




--- End Message ---
--- Begin Message ---
Hello,

I ran into a slight problem when using the 'domain_suffix' parameter:
Clicking a device in the network map results in a 'no such device' error
(That's the same error as documented in the bugtracker
http://sourceforge.net/p/netdisco/netdisco2/48/) . Attached to this mail is
a patch that should fix this issue.

regards
Daniel
diff -crB netdisco-netdisco-ng-org/Netdisco/lib/App/Netdisco/Web/Plugin/Device/Neighbors.pm netdisco-netdisco-ng-patch/Netdisco/lib/App/Netdisco/Web/Plugin/Device/Neighbors.pm
*** netdisco-netdisco-ng-org/Netdisco/lib/App/Netdisco/Web/Plugin/Device/Neighbors.pm	2013-12-05 13:59:16.380036791 +0100
--- netdisco-netdisco-ng-patch/Netdisco/lib/App/Netdisco/Web/Plugin/Device/Neighbors.pm	2013-12-05 15:43:18.701842763 +0100
***************
*** 11,24 ****
  
  ajax '/ajax/content/device/netmap' => require_login sub {
      content_type('text/html');
!     template 'ajax/device/netmap.tt', {}, { layout => undef };
  };
  
  sub _get_name {
      my $ip = shift;
-     my $domain = quotemeta( setting('domain_suffix') || '' );
  
!     (my $dns = (var('devices')->{$ip} || '')) =~ s/$domain$//;
      return ($dns || $ip);
  }
  
--- 11,25 ----
  
  ajax '/ajax/content/device/netmap' => require_login sub {
      content_type('text/html');
!     template 'ajax/device/netmap.tt', {
!         domain_suffix => setting('domain_suffix') || ''
!     }, { layout => undef };
  };
  
  sub _get_name {
      my $ip = shift;
  
!     my $dns = (var('devices')->{$ip} || '');
      return ($dns || $ip);
  }
  
diff -crB netdisco-netdisco-ng-org/Netdisco/share/views/ajax/device/netmap.tt netdisco-netdisco-ng-patch/Netdisco/share/views/ajax/device/netmap.tt
*** netdisco-netdisco-ng-org/Netdisco/share/views/ajax/device/netmap.tt	2013-12-05 13:59:16.396036791 +0100
--- netdisco-netdisco-ng-patch/Netdisco/share/views/ajax/device/netmap.tt	2013-12-05 14:02:47.301670805 +0100
***************
*** 1,5 ****
--- 1,7 ----
  <script>
  
+ var domain_suffix = "[% domain_suffix %]";
+ 
  var winHeight = window.innerHeight;
  var winWidth  = window.innerWidth;
  
***************
*** 123,129 ****
          .attr("dy", ".31em")
          .attr("text-anchor", function(d) { return d.x < 180 ? "start" : "end"; })
          .attr("transform", function(d) { return d.x < 180 ? "translate(8)" : "rotate(180)translate(-8)"; })
!         .text(function(d) { return d.name; });
  
      // reorient text on the root node
      svg.select(".node")
--- 125,131 ----
          .attr("dy", ".31em")
          .attr("text-anchor", function(d) { return d.x < 180 ? "start" : "end"; })
          .attr("transform", function(d) { return d.x < 180 ? "translate(8)" : "rotate(180)translate(-8)"; })
!         .text(function(d) { return d.name.replace(domain_suffix, ""); });
  
      // reorient text on the root node
      svg.select(".node")

--- End Message ---
------------------------------------------------------------------------------
Sponsored by Intel(R) XDK 
Develop, test and display web and hybrid apps with a single code base.
Download it for free now!
http://pubads.g.doubleclick.net/gampad/clk?id=111408631&iu=/4140/ostg.clktrk
_______________________________________________
Netdisco mailing list - Digest Mode
[email protected]
https://lists.sourceforge.net/lists/listinfo/netdisco-users

Reply via email to