Friday 31 October 2014

**********NEWS (2015/09/2)**********
Updated Automatic installation from script. v1.0 for newer Debian & Ubuntu releases
*********************************************

2014/10/31
ON HOLD: CentOS 6.5 Install Script
Update Script 1.3.2 To 1.3.3 Added - Thanks to Bavo Seesink

2014/03/6
In The Works: CentOS 6.5 Install Script

Update Script 1.2 To 1.3.2 Added 

Fixed Netdisco 1.2 Update Script (EVAL ERROR)
Swedish Scripts Removed

2013/06/18
Fixed Netdisco Script Install (Internal Error 500)

2013/05/22
IRC Support Channel Added

2013/04/23
We fixed a error in the script installation files, the problem was four sed commands not being able to write to the targeted line, for the specific system ubuntu server12.04.
It should work on every system now, both server and desktop environments.

2013/04/18
We are up on SourceForge, all our files are hosted there from now on.
Feel free to visit us there as well.
*********************************************



---------- Manual Installations ----------

     1 - Manually installation from scratch. v1.0
          Manual Installation

 
     2 - Manual update to latest version. v1.2. This update is based on Netdisco v1.0 so we recommend you installing the v1.0 and afterwards you upgrade to 1.2
          Manual Update to 1.2


--------- Script/Auto Installations ---------

     1 - Automatic installation from script. v1.0
          Automatic Installation


     2 - Automatic update to version. v1.2. This update is based on Netdisco v1.0 so we recommend you installing the v1.0 and afterwards you upgrade to 1.2      
          Automatic Update to 1.2


     3 - Automatic update to version. v1.3.2. This update is based on Netdisco v1.2 script update so we recommend you installing the v1.2 and afterwards you upgrade to 1.3.2     
          Automatic Update to 1.3.2


     4 - Automatic update to version. v1.3.3. This update is based on Netdisco v1.3.2 script update so we recommend you installing the v1.3.2 and afterwards you upgrade to 1.3.3    
          Automatic Update to 1.3.3


------------- Other -------------

          MIBS Updater. Updater will download and install latest mibs-snapshot, nothing else will be touched.
          Automatic MIBS Update

Thursday 30 October 2014

Automatic Upgrade To Version 1.3.3

Simply download the bash file below
netdisco-update-1.3.2-to-1.3.3.sh

After the download locate to your Download file section usually /home/USERNAME/Downloads:

#cd /home/netdiscot1/Downloads


Give executable rights to file and run it:
#chmod 755 netdisco-update-1.3.2-to-1.3.3.sh

# ./netdisco-update-1.3.2-to-1.3.3.sh 


Any problems? Leave a comment or mail
persson.marcus92@gmail.com
tukic.adnan@gmail.com

Wednesday 30 October 2013

Automatic Upgrade To Version 1.3.2

Simply download the bash file below
netdisco-update-1.2-to-1.3.2.sh

After the download locate to your Download file section usually /home/USERNAME/Downloads:

#cd /home/netdiscot1/Downloads


Give executable rights to file and run it:
#chmod 755 netdisco-update-1.2-to-1.3.2.sh

# ./netdisco-update-1.2-to-1.3.2.sh


Any problems? Leave a comment or mail
persson.marcus92@gmail.com
tukic.adnan@gmail.com

Tuesday 16 April 2013

Automatic installation from script.

**********UPDATE (2013/06/18)**********
Internal Error 500 Fixed
************************************************

2013/04/18
MIBS download/install problem solved
************************************************


Simply download the bash file below
netdisco-install-eng.sh

After the download locate to your Download file section usually /home/USERNAME/Downloads:

#cd /home/netdiscot1/Downloads


Give executable rights to file and run it:
#chmod 755 netdisco-install-eng.sh

# ./netdisco-install-eng.sh 



Any problems? Leave a comment or mail
persson.marcus92@gmail.com
tukic.adnan@gmail.com

Manual Netdisco Installation

**********UPDATE (2013/04/18)**********
MIBS download/install problem solved
************************************************

Full manual installation off Netdisco - Network Management tool [English]

Netdisco Installation guide
(Last Edit: 2013-04-15)

To start with, this installation is not supporting systems that are NOT based on Debian. Like Redhat for example. Since the guide will be using apt-get and we havn’t tried yum.
We preformed this installation three times on Ubuntu and Linux Mint without any problems.
We recommend you being sudo or root user during the whole installation.


1. Start of by updating and upgrading your system.
#apt-get update
#apt-get upgrade


2. Install needed packets for netdisco to run proper
apt-get install postgresql-9.1 postgresql-server-dev-9.1 apache2 libperl-dev graphviz libnet-snmp-perl libapache2-mod-perl2 libapache-session-wrapper-perl libhtml-mason-perl libdbd-pg-perl libgraphviz-perl perl-modules libapache2-request-perl libnet-nbname-perl libsnmp-info-perl libapache-dbi-perl libmasonx-request-withapachesession-perl libparallel-forkmanager-perl libgraph-perl vim make build-essential libdb5.1-dev netdisco-common netdisco-frontend netdisco-backend netdisco-mibs-installer


3. Check apache2 is working and the two modules are loaded.
#service apache2 restart
#a2enmod perl
#a2enmod apreq


You might get an error here about netdisco.pm which means you are using the latest perl version. This will be fixed later on in the guide.
You might also get errors about the apreq and perl modules, this is because the two modules are sat on Auto-start in more than one configuration file. When it warns you simply ignore it.


4. Create a backup file for the postgresql configuration.
#cp /etc/postgresql/9.1/main/pg_hba.conf /etc/postgresql/9.1/main/pg_hba.conf.orig


5. Next up, edit the pg_hba.conf file with any editor of your choice (we are using vim).
#vim /etc/postgresql/9.1/main/pg_hba.conf       


When you are inside the file you are gonna locate the following configuration line:
#TYPE        DATABASE        USER        ADDRESS        METHOD


Add the following user beneath it to look like this:
#TYPE        DATABASE        USER        ADDRESS        METHOD
local            netdisco              netdisco                               trust


There is going to be other kinds of information and configuration but what you just did, is you added the following local user netdisco to be allowed in the sql database.


6. Now restart your database.
#service postgresql restart


7. Now we will start with the netdisco configuration. Move yourself into the netdisco folder(should be in /usr/share/doc/ if you installed it with apt-get):
#cd /usr/share/doc/netdisco-common/contrib/


unzip the configuration file.
#gunzip netdisco.conf.example.gz


Then make a backup and copy the netdisco.conf.example to netdisco.conf, if anything goes wrong you got a backup called netdisco.conf.example
#cp netdisco.conf.example /etc/netdisco/netdisco.conf


Next up edit the netdisco.conf file with any editor of your choice(we use vim)
#vim /etc/netdisco/netdisco.conf


Locate the following lines in the netdisco.conf:
db_Pg_user    netdisco
db_Pg_pw       PASSWORD


And change the “PASSWORD” to netdisco.
db_Pg_user    netdisco
db_Pg_pw    netdisco


8. Next up we are gonna change the files so they agree with the apache2, postgresql and netdisco. Start by copying /usr/share/doc/netdisco-backends/sql to /usr/lib/netdisco
#cp -r /usr/share/doc/netdisco-backend/sql/ /usr/lib/netdisco/


9. Configure the netdisco apache2. Open it up with any editor (we use vim).
#vim /etc/netdisco/netdisco_apache2.conf


Locate the following lines:
      session_user_name      => 'netdisco',
      session_password       => 'PASSWORD',


Change it to:
      session_user_name      => 'netdisco',
      session_password       => 'netdisco',


10. Next add two lines to your apache2.conf you can do this by editing the file or just write the output of a sentence to the file like this:
#echo "Include /etc/netdisco/netdisco_apache2.conf" >> /etc/apache2/apache2.conf
#echo "Include /etc/netdisco/netdisco_apache2_dir.conf" >> /etc/apache2/apache2.conf


This means the sentence “Include /etc/netdisco/netdisco_apache2.conf” and “Include /etc/netdisco/netdisco_apache2_dir.conf” now is located in apache2.conf as a sentence and a configuration.


11. Next up we are going to add some perl modules through CPAN.
Start with entering the cpan shell:
#perl -MCPAN -e shell
And your prompt should have changed to comthing like this: cpan[1]>
Now start the installations by typing in:


>install CPAN                 (installs/updates to the latest CPAN)
>install Digest::MD5                           
>install Bundle::DBI               
>install Apache::DBI
>install DBD::Pg
>install DB_File                   
>install Apache::Session
>install HTML::Entities
>install HTML::Mason
>force install MasonX::Request::WithApacheSession
>install Graph        
>install GraphViz     
>install Compress::Zlib
>install Parallel::ForkManager
>install Net::NBName
>install Net::LDAP
>install Net::SSLeay
>install IO::Socket::SSL
>install Apache2::Request


12. Next up we are going to create the database, there will be alot of text and information running through hopefully it will be made without any errors.
#/usr/bin/npg --init


13.Now chrown the netdisco user and create a admin for the netdisco.
#chown -R netdisco:netdisco /usr/share/netdisco
#chown -R www-data:www-data /usr/share/netdisco/html
#chown -R www-data:www-data /var/lib/netdisco/mason


#/usr/bin/netdisco -u admin
When your making the admin you will be promted and asked for four questions like this
n e t  d i s c o
--------------------------------------------------
Enter new password for admin [no change]: <YOURPASSWORD!>
Give admin Port Control [no change]? yes
Give admin Admin Rights [no change]? yes
User Full Name [none]? admin
Added user admin. (1)


14. Go into MIBS directory.
#cd /usr/share/netdsico/mibs/


When you located yourself to the /usr/share/netdisco/mibs directory start downloading all the mibs.
#wget http://downloads.sourceforge.net/project/netdisco/netdisco-mibs/1.3/netdisco-mibs-1.3.tar.gz


The file you just downloaded needs to untar and moved.
#tar -zxvf netdisco-mibs-1.3.tar.gz


And then move the files inside the one you just opened to the right directory.
#mv /usr/share/netdisco/mibs/netdisco-mibs-1.3/* /usr/share/netdisco/mibs/


Remove the one file you downloaded.
#rm -r netdisco-mibs-1.3 netdisco-mibs-1.3.tar.gz


15. Next we gonna edit the snmp.conf file with any editor (we use vim).
#vim /usr/share/netdisco/mibs/snmp.conf


Inside the file the snmp configuration is set to /usr/local which aint the right directory we sat it too since we installed it from apt-get. So you are going to replace every /usr/local to /usr/share.
A fast way to do that is by using a vim command to change all the local too /share:
:%s/local/share/g


After that copy the snmp.conf file
#cp /usr/share/netdisco/mibs/snmp.conf /etc/snmp/


And then install the up to date version of snmp from the internet.
#wget http://sourceforge.net/projects/net-snmp/files/net-snmp/5.7.2/net-snmp-5.7.2.tar.gz/download


locate yourself to the download section usually /home/USERNAME/Downloads
and tar the downloaded file:
#tar -zxvf net-snmp-5.7.2.tar.gz


Locate yourself to the downloaded file
#cd /net-snmp-5.7.2


Then run the final installation of snmp
./configure --with-perl-modules --enable-shared
make
make install


#cd /perl
perl Makefile.PL
make
make install


16. Check what version of perl you got installed:
#perl -v


IF YOU ARE RUNNING 5.14.X OR NEWER VERSION OF PERL YOU WILL HAVE TO DO SOME CHANGES. IF NOT ONLY CHECK SO THEY ARE CONFIGURED THE RIGHT WAY.


Edit this file and locate yourself to row 337
#vim /usr/share/perl5/netdisco.pm


Here you will edit the line:
qw(booleans array_refs hash_refs array_refs_mult hash_refs_mult)


To look like:
(qw(booleans array_refs hash_refs array_refs_mult hash_refs_mult))


Save and edit another file:
#vim /usr/share/netdisco/html/device.html


locate yourself to row 570 in the file


Edit the line:
qw(fw hw sw)


To look like this:
(qw(fw hw sw))


Now restart apache2, postgresql and netdisco:
#service apache2 restart
#service postgresql restart
#netdisco -p restart


You shouldn’t get any kind of errors and if you didn’t just open up any kind of browser and enter localhost to check the apache2 and then localhost/netdisco to enter the WEBUI.


And your done!


This guide is written by Marcus Persson & Adnan Tukic.


If you get any kind of errors or have any troubles with the installation feel free to let us know, and hopefully we will be able to answer you ASAP.

Any problems? Leave a comment or mail
persson.marcus92@gmail.com
tukic.adnan@gmail.com

Automatic Upgrade To Version 1.2[English]

Simply download the bash file below
netdisco-update-1.0-to-1.2.sh

After the download locate to your Download file section usually /home/USERNAME/Downloads:

#cd /home/netdiscot1/Downloads


Give executable rights to file and run it:
#chmod 755 netdisco-update-1.0-to-1.2.sh

# ./netdisco-update-1.0-to-1.2.sh


Any problems? Leave a comment or mail
persson.marcus92@gmail.com
tukic.adnan@gmail.com

Netdisco MIBS Updater[English]

Simply download the bash file below
netdisco-mibs-update.sh

After the download locate to your Download file section usually /home/USERNAME/Downloads:

#cd /home/netdiscot1/Downloads


Give executable rights to file and run it:
#chmod 755 netdisco-mibs-update.sh

# ./netdisco-mibs-update.sh 



Any problems? Leave a comment or mail
persson.marcus92@gmail.com
tukic.adnan@gmail.com