Merge branch 'master' into og-pseudo-vs-cli-arpnip

This commit is contained in:
Oliver Gorwits
2019-09-01 14:54:36 +01:00
8 changed files with 75 additions and 22 deletions

View File

@@ -1,5 +1,7 @@
<!--- <!---
Provide a general summary of the issue in the Title above
READ THIS FIRST!
----------------
STOP! If your ticket is about a device not being detected correctly, STOP! If your ticket is about a device not being detected correctly,
see SNMP::Info: https://github.com/netdisco/snmp-info/issues/new see SNMP::Info: https://github.com/netdisco/snmp-info/issues/new
@@ -10,12 +12,20 @@ see netdisco-mibs: https://github.com/netdisco/netdisco-mibs/issues/new
STOP! If you are running a netdisco docker setup, STOP! If you are running a netdisco docker setup,
see netdisco-docker: https://github.com/netdisco/netdisco-docker/issues/new see netdisco-docker: https://github.com/netdisco/netdisco-docker/issues/new
everything else about Netdisco's behaviour is good, here :-D everything else about Netdisco's behaviour is good, here :-D
the more info you can provide, the easier it is for us the help you, so please
fill out as many of the items below as possible.
Provide a general summary of the issue in the Title above
when including netdisco config snippets, whitespace matters since it's a yaml file when including netdisco config snippets, whitespace matters since it's a yaml file
for github issues it really helps if you include the relevant config parts in a codeblock (code fencing) for github issues it really helps if you include the relevant config parts in a codeblock (code fencing)
see the "code" subject on https://guides.github.com/features/mastering-markdown/ for that) see the "code" subject on https://guides.github.com/features/mastering-markdown/ for that)
this should preserve spaces in the issue tracker and make troubleshooting quicker this should preserve spaces in the issue tracker and make troubleshooting quicker
--> -->
@@ -48,6 +58,10 @@ this should preserve spaces in the issue tracker and make troubleshooting quicke
* Netdisco version used: * Netdisco version used:
* SNMP::Info version used: * SNMP::Info version used:
## Config info (deployment.yml)
<!--- if possible include all options you added to your deployment.yml file, since -->
<!--- some options can change the behaviour in drastic ways -->
## Device information ## Device information
<!--- if the issue relates to specific devices their info would be usefull --> <!--- if the issue relates to specific devices their info would be usefull -->
<!--- do note that the following command might contain sensitive info, you can --> <!--- do note that the following command might contain sensitive info, you can -->

View File

@@ -9,7 +9,7 @@ addons:
packages: packages:
- libsnmp-dev - libsnmp-dev
- phantomjs - phantomjs
- graphviz - graphviz
hosts: hosts:
- localhost - localhost
branches: branches:

View File

@@ -508,6 +508,7 @@ share/views/sidebar/search/device.tt
share/views/sidebar/search/node.tt share/views/sidebar/search/node.tt
share/views/sidebar/search/port.tt share/views/sidebar/search/port.tt
xt/00-compile.t xt/00-compile.t
xt/01-local-pod.t
xt/10-sort_port.t xt/10-sort_port.t
xt/11-portsort.t xt/11-portsort.t
xt/20-checkacl.t xt/20-checkacl.t

View File

@@ -4,7 +4,7 @@
"Oliver Gorwits <oliver@cpan.org>" "Oliver Gorwits <oliver@cpan.org>"
], ],
"dynamic_config" : 1, "dynamic_config" : 1,
"generated_by" : "Module::Build version 0.4224", "generated_by" : "Module::Build version 0.4229",
"license" : [ "license" : [
"bsd" "bsd"
], ],
@@ -39,6 +39,7 @@
"App::cpanminus" : "1.6108", "App::cpanminus" : "1.6108",
"App::local::lib::helper" : "0.07", "App::local::lib::helper" : "0.07",
"Archive::Extract" : "0", "Archive::Extract" : "0",
"Authen::Radius" : "0",
"CGI::Expand" : "2.05", "CGI::Expand" : "2.05",
"DBD::Pg" : "0", "DBD::Pg" : "0",
"DBIx::Class" : "0.082841", "DBIx::Class" : "0.082841",
@@ -143,7 +144,7 @@
}, },
"App::Netdisco::DB" : { "App::Netdisco::DB" : {
"file" : "lib/App/Netdisco/DB.pm", "file" : "lib/App/Netdisco/DB.pm",
"version" : "58" "version" : "59"
}, },
"App::Netdisco::DB::ExplicitLocking" : { "App::Netdisco::DB::ExplicitLocking" : {
"file" : "lib/App/Netdisco/DB/ExplicitLocking.pm" "file" : "lib/App/Netdisco/DB/ExplicitLocking.pm"
@@ -268,6 +269,9 @@
"App::Netdisco::DB::Result::Virtual::GenericReport" : { "App::Netdisco::DB::Result::Virtual::GenericReport" : {
"file" : "lib/App/Netdisco/DB/Result/Virtual/GenericReport.pm" "file" : "lib/App/Netdisco/DB/Result/Virtual/GenericReport.pm"
}, },
"App::Netdisco::DB::Result::Virtual::LastNode" : {
"file" : "lib/App/Netdisco/DB/Result/Virtual/LastNode.pm"
},
"App::Netdisco::DB::Result::Virtual::NodeIp4" : { "App::Netdisco::DB::Result::Virtual::NodeIp4" : {
"file" : "lib/App/Netdisco/DB/Result/Virtual/NodeIp4.pm" "file" : "lib/App/Netdisco/DB/Result/Virtual/NodeIp4.pm"
}, },
@@ -804,7 +808,7 @@
}, },
"homepage" : "http://netdisco.org/", "homepage" : "http://netdisco.org/",
"license" : [ "license" : [
"http://opensource.org/licenses/BSD-3-Clause" "http://opensource.org/licenses/bsd-license.php"
], ],
"repository" : { "repository" : {
"url" : "https://github.com/netdisco/netdisco" "url" : "https://github.com/netdisco/netdisco"
@@ -813,5 +817,5 @@
"x_MailingList" : "https://lists.sourceforge.net/lists/listinfo/netdisco-users" "x_MailingList" : "https://lists.sourceforge.net/lists/listinfo/netdisco-users"
}, },
"version" : "2.042010", "version" : "2.042010",
"x_serialization_backend" : "JSON::PP version 2.97001" "x_serialization_backend" : "JSON::PP version 4.02"
} }

View File

@@ -14,7 +14,7 @@ configure_requires:
DBIx::Class: '0.082810' DBIx::Class: '0.082810'
Module::Build: '0.42' Module::Build: '0.42'
dynamic_config: 1 dynamic_config: 1
generated_by: 'Module::Build version 0.4224, CPAN::Meta::Converter version 2.150010' generated_by: 'Module::Build version 0.4229, CPAN::Meta::Converter version 2.150010'
license: bsd license: bsd
meta-spec: meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -38,7 +38,7 @@ provides:
file: lib/App/Netdisco/Configuration.pm file: lib/App/Netdisco/Configuration.pm
App::Netdisco::DB: App::Netdisco::DB:
file: lib/App/Netdisco/DB.pm file: lib/App/Netdisco/DB.pm
version: '58' version: '59'
App::Netdisco::DB::ExplicitLocking: App::Netdisco::DB::ExplicitLocking:
file: lib/App/Netdisco/DB/ExplicitLocking.pm file: lib/App/Netdisco/DB/ExplicitLocking.pm
App::Netdisco::DB::Result::Admin: App::Netdisco::DB::Result::Admin:
@@ -121,6 +121,8 @@ provides:
file: lib/App/Netdisco/DB/Result/Virtual/DuplexMismatch.pm file: lib/App/Netdisco/DB/Result/Virtual/DuplexMismatch.pm
App::Netdisco::DB::Result::Virtual::GenericReport: App::Netdisco::DB::Result::Virtual::GenericReport:
file: lib/App/Netdisco/DB/Result/Virtual/GenericReport.pm file: lib/App/Netdisco/DB/Result/Virtual/GenericReport.pm
App::Netdisco::DB::Result::Virtual::LastNode:
file: lib/App/Netdisco/DB/Result/Virtual/LastNode.pm
App::Netdisco::DB::Result::Virtual::NodeIp4: App::Netdisco::DB::Result::Virtual::NodeIp4:
file: lib/App/Netdisco/DB/Result/Virtual/NodeIp4.pm file: lib/App/Netdisco/DB/Result/Virtual/NodeIp4.pm
App::Netdisco::DB::Result::Virtual::NodeIp6: App::Netdisco::DB::Result::Virtual::NodeIp6:
@@ -483,6 +485,7 @@ requires:
App::cpanminus: '1.6108' App::cpanminus: '1.6108'
App::local::lib::helper: '0.07' App::local::lib::helper: '0.07'
Archive::Extract: '0' Archive::Extract: '0'
Authen::Radius: '0'
CGI::Expand: '2.05' CGI::Expand: '2.05'
DBD::Pg: '0' DBD::Pg: '0'
DBIx::Class: '0.082841' DBIx::Class: '0.082841'
@@ -556,7 +559,7 @@ resources:
MailingList: https://lists.sourceforge.net/lists/listinfo/netdisco-users MailingList: https://lists.sourceforge.net/lists/listinfo/netdisco-users
bugtracker: https://github.com/netdisco/netdisco/issues bugtracker: https://github.com/netdisco/netdisco/issues
homepage: http://netdisco.org/ homepage: http://netdisco.org/
license: http://opensource.org/licenses/BSD-3-Clause license: http://opensource.org/licenses/bsd-license.php
repository: https://github.com/netdisco/netdisco repository: https://github.com/netdisco/netdisco
version: '2.042010' version: '2.042010'
x_serialization_backend: 'CPAN::Meta::YAML version 0.018' x_serialization_backend: 'CPAN::Meta::YAML version 0.018'

View File

@@ -71,7 +71,7 @@ these is an optional service which the user is asked to confirm.
Pre-existing requirements are that there be a database table created and a Pre-existing requirements are that there be a database table created and a
user with rights to create tables in that database. Both the table and user user with rights to create tables in that database. Both the table and user
name must match those configured in your environment YAML file (default name must match those configured in your environment YAML file (default
C<~/environments/deployment.yml>). F<~/environments/deployment.yml>).
This script will download the latest MAC address vendor prefix data from the This script will download the latest MAC address vendor prefix data from the
Internet, and update the OUI table in the database. Hence Internet access is Internet, and update the OUI table in the database. Hence Internet access is
@@ -80,10 +80,17 @@ required to run the script.
Similarly the latest Netdisco MIB bundle is also downloaded and placed into Similarly the latest Netdisco MIB bundle is also downloaded and placed into
the user's home directory (or C<$ENV{NETDISCO_HOME}>). the user's home directory (or C<$ENV{NETDISCO_HOME}>).
If you upgrade Netdisco make sure you run this script again to make sure
your config remains compatible.
Before each upgrade also review the
L<Release notes|https://github.com/netdisco/netdisco/wiki/Release-Notes> since
additional steps might be required!
=cut =cut
print color 'bold cyan'; print color 'bold cyan';
say 'This is the Netdisco II deployment script.'; say 'This is the Netdisco 2 deployment script.';
say ''; say '';
say 'Before we continue, the following prerequisites must be in place:'; say 'Before we continue, the following prerequisites must be in place:';
say ' * Database added to PostgreSQL for Netdisco'; say ' * Database added to PostgreSQL for Netdisco';
@@ -92,6 +99,11 @@ say ' * "~/environments/deployment.yml" file configured with Database dsn/user/p
say ' * A full backup of any existing Netdisco database data'; say ' * A full backup of any existing Netdisco database data';
say ' * Internet access (for OUIs and MIBs)'; say ' * Internet access (for OUIs and MIBs)';
say ''; say '';
say 'If you are upgrading Netdisco 2 read the release notes:';
say 'https://github.com/netdisco/netdisco/wiki/Release-Notes';
say 'There you will find required and incompatible changes';
say 'which are not covered by this script.';
say '';
say 'You will be asked to confirm all changes to your system.'; say 'You will be asked to confirm all changes to your system.';
say ''; say '';
print color 'reset'; print color 'reset';
@@ -194,13 +206,13 @@ sub deploy_db {
} }
sub get_userpass { sub get_userpass {
my $term = shift; my $upterm = shift;
my $name = $term->get_reply(prompt => 'Username: '); my $name = $upterm->get_reply(prompt => 'Username: ');
my $pass = $term->get_reply(prompt => 'Password: '); my $pass = $upterm->get_reply(prompt => 'Password: ');
unless ($name and $pass) { unless ($name and $pass) {
say 'username and password cannot be empty, please try again.'; say 'username and password cannot be empty, please try again.';
($name, $pass) = get_userpass($term); ($name, $pass) = get_userpass($upterm);
} }
return ($name, $pass); return ($name, $pass);
@@ -257,7 +269,7 @@ sub deploy_oui {
print color 'reset'; print color 'reset';
} }
# This subroutine is baed on Wireshark's make-manuf # This subroutine is based on Wireshark's make-manuf
# http://anonsvn.wireshark.org/wireshark/trunk/tools/make-manuf # http://anonsvn.wireshark.org/wireshark/trunk/tools/make-manuf
sub shorten { sub shorten {
my $manuf = shift; my $manuf = shift;

View File

@@ -116,14 +116,25 @@ application:
You may wish to L<amend the PostgreSQL You may wish to L<amend the PostgreSQL
configuration|https://github.com/netdisco/netdisco/wiki/Install-Tips#enable-md5-authentication-to-postgresql> configuration|https://github.com/netdisco/netdisco/wiki/Install-Tips#enable-md5-authentication-to-postgresql>
so that local connections are working. The default PostgreSQL configuration so that local connections are working. The default PostgreSQL configuration
also needs tuning for modern server hardware. We recommend that you use the can also use tuning for modern server hardware. We recommend that you use one of the following
C<pgtune> Python program to auto-tune your C<postgresql.conf> file: tools to tune your C<postgresql.conf> file:
=over 4 =over 4
=item * =item L<postgresqltuner|https://github.com/jfcoz/postgresqltuner>
L<https://github.com/elitwin/pgtune> Script that will check your operating system resources and settings as well as your
running PostgreSQL database and will make recommendations based on actual load. Works
on new netdisco installs but will make the best suggestions once the database contains
a bigger dataset.
=item L<pgtune (fork)|https://pgtune.leopard.in.ua>
A web based application which will recommend which parameters to change.
=item L<pgtune|https://github.com/elitwin/pgtune>
Program to auto-tune your C<postgresql.conf>, regretfully not updated in a while.
=back =back
@@ -230,7 +241,7 @@ If you're running a version of Netdisco prior to 2.x then you should follow
the full installation instructions, above. This process is for upgrading the full installation instructions, above. This process is for upgrading
version 2.x only. version 2.x only.
Before upgrading please review the latest L<Release Notes|https://github.com/netdisco/netdisco/wiki/Release-Notes>. Before upgrading always review the latest L<Release Notes|https://github.com/netdisco/netdisco/wiki/Release-Notes>.
Then the process below should be run for each installation: Then the process below should be run for each installation:
# upgrade Netdisco # upgrade Netdisco
@@ -333,7 +344,7 @@ built upon.
=head1 COPYRIGHT AND LICENSE =head1 COPYRIGHT AND LICENSE
This software is copyright (c) 2011-2018 by The Netdisco Developer Team. This software is copyright (c) 2011-2019 by The Netdisco Developer Team.
Redistribution and use in source and binary forms, with or without Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met: modification, are permitted provided that the following conditions are met:

8
xt/01-local-pod.t Normal file
View File

@@ -0,0 +1,8 @@
#!/usr/bin/env perl
use strict;
use warnings;
use Test::More;
use Test::Pod;
all_pod_files_ok();