Difference between revisions of "Server Installation Guide"

From NetXMS Wiki
Jump to navigation Jump to search
(Added DB2 to supported DB list)
(Replaced content with "Information moved to documentation: https://www.netxms.org/documentation/adminguide/installation.html")
Line 1: Line 1:
= Requirements =
Information moved to documentation:
Read this chapter and perform a thorough review of the system or systems onto which you are planning to install NetXMS software. The system/s must meet software, hardware, and configuration requirements listed in this chapter.


== Hardware ==
https://www.netxms.org/documentation/adminguide/installation.html
Minimum requirements: Intel Pentium III 500 MHz, 256MB RAM, 100MB of free disk space.
 
Recommended: Intel Pentium IV 1 GHz, 512MB RAM, 100MB of free disk space.
 
Additional RAM may be required for large installations (1000+ nodes). For non-Intel platforms, an equivalent hardware must be used.
 
== Operating System ==
The server can run on the following operating systems:
 
* Linux
* FreeBSD
* Windows XP, Windows Server 2003, Windows Vista, Windows 7, Windows Server 2008
* Solaris 10, 11
* HP-UX 11.23, 11.31
* AIX 5.3, 6.x
* MacOS X
 
If you wish to compile NetXMS server with encryption support on UNIX, you must have OpenSSL package installed.
 
== Database ==
The following database engines can be used as a backend:
 
* Microsoft SQL (2000 or higher)
* [[Oracle]] (10 or higher)
* MySQL (5.0.3 or higher)
* PostgreSQL (8.0 or higher)
* SQLite (bundled with NetXMS)
* IBM DB2
 
Database size and load is very hard to predict, because it is dependent on a number of monitored nodes and collected parameters. If you plan to install database engine on the same machine as NetXMS server, increase your hardware requirements accordingly.
 
= Installing NetXMS Server on UNIX =
1. Download the latest version from http://www.netxms.org/download, if you don't have it. You will need source archive (named netxms-''VERSION''.tar.gz, for example netxms-{{version}}.tar.gz). Please note that in the following steps ''VERSION'' will be used as a substitution for an actual version number.<br/>
 
2. Unpack the archive:
 
{{#tag:syntaxhighlight|tar zxvf netxms-{{version}}.tar.gz|lang=bash}}
 
3. Change directory to netxms-version and run configure script:
 
{{#tag:syntaxhighlight|
cd netxms-{{version}}
sh ./configure --with-server --with-mysql --with-agent
|lang=bash}}
 
Important arguments:
 
* --prefix=DIRECTORY: installation prefix, all files go to the specified directory;
* --with-server: build server. Don't forget to add at least one DB Driver as well;
* --with-pgsql: build Postgres DB Driver (if you plan to use PostgreSQL as backend database);
* --with-mysql: build MySQL DB Driver (if you plan to use MySQL as backend database);
* --with-odbc: build ODBC DB driver (if you plan to connect to your backend database via ODBC; you will need UNIX ODBC package to do that);
* --with-sqlite: build SQLite DB driver (if you plan to use embedded SQLite database as backend database);
* --with-agent: build monitoring agent. It is strongly recommended to install agent on a server box;
* --disable-encryption: Disable encryption support.
 
To learn more about possible configure parameters, run it with --help option.
 
4. Run make and make install:
 
{{#tag:syntaxhighlight|
make
make install
|lang=bash}}
 
5. Copy sample config files to desired locations:
 
{{#tag:syntaxhighlight|
cp contrib/netxmsd.conf-dist /etc/netxmsd.conf
cp contrib/nxagentd.conf-dist /etc/nxagentd.conf
|lang=bash}}
 
By default, both server and agent will look for configuration files in /etc directory. If you wish to place configuration files in a different location, don't forget to use –c command line switch for agent and –config-file command-line switch for server to specify an alternate location.
 
 
 
6. Create Database and User with access rights to this database.
 
Example for MySQL:
 
mysql -u root -p mysql
mysql> CREATE DATABASE netxms;
mysql> GRANT ALL ON netxms.* TO netxms@localhost IDENTIFIED BY 'PaSsWd';
mysql> \q
 
[[Oracle | Example for Oracle 11g]].
 
Please note that database that user you have created should have rights to create new tables.
 
 
7. Modify server configuration file (default is /etc/netxmsd.conf). It should look the following way:
 
DBDriver = mysql.ddr
DBServer = localhost
DBName = netxms
DBLogin = netxms
DBPassword = PaSsWd
LogFile = /var/log/netxmsd
LogFailedSQLQueries = yes
 
 
Description of configuration parameters:
 
{| class="wikitable" style="width: 70%"
! Parameter || Description
|-
| CodePage || Server's code page. Default value depends on your system, usually ISO8859-1. You should change it if you plan to use national characters in object names, comments, etc. This parameter will have no effect if server was compiled without iconv support.
|-
| DBDriver || Database driver to be used. You can use one of the following drivers:
 
* mysql.ddr Driver for MySQL database.
* odbc.ddr ODBC connectivity driver (you can connect to MySQL, PostgreSQL, MS SQL, and Oracle via ODBC).
* oracle.ddr Driver for Oracle database.
* pgsql.ddr Driver for PostgreSQL database.
* sqlite.ddr Driver for embedded SQLite database.
 
|-
| DBServer || Database server to connect to (for ODBC driver, name of ODBC source).
|-
| DBName || Database name (for SQLite driver, database file name).
|-
| DBLogin || Database user name.
|-
| DBPassword || Database user's password.
|-
| LogFile || Server's log file. To write a log to syslog (or Event Log on Windows), use ''{syslog}'' as file name.
|-
| LogFailedSQLQueries || Controls logging of failed SQL queries. Possible values are "yes" (default) or "no". It is recommended to keep this parameter set to "yes" to simplify diagnostics of database-related problems and bugs.
|}
 
8. Modify agent's configuration file (/etc/nxagentd.conf). For detailed description of possible parameters, please consult NetXMS User's Manual. For the normal server's operation, you should add at least the following line to your agent's configuration file:
 
MasterServers = 127.0.0.1, your_server_IP_address
 
 
9. Initialise this database with nxdbmgr utility using sql-script in sql/dbinit_''DBTYPE''.sql. ''DBTYPE'' can be "mssql", "mysql", "pgsql", "oracle", or "sqlite".
 
MySQL example:
 
$ /usr/local/bin/nxdbmgr init /usr/local/share/netxms/sql/dbinit_mysql.sql
 
 
10. Run agent and server:
 
<pre>
# /usr/local/bin/nxagentd -d
# /usr/local/bin/netxmsd -d
</pre>
 
Now you have working NetXMS server.
 
= Upgrading NetXMS Server on UNIX =
1. Download the latest version from http://www.netxms.org/download, if you don't have it. You will need source archive (named netxms-VERSION.tar.gz, for example netxms-{{version}}.tar.gz). Please note that in the following steps VERSION will be used as a substitution for an actual version number.<br/>
 
2. Unpack the archive:
 
$ tar zxvf netxms-{{version}}.tar.gz
 
3. Change directory to netxms-version and run configure script:
 
$ cd netxms-{{version}}
$ sh ./configure --with-server --with-mysql
 
Be sure to include all options that were used at installation time.
 
 
4. Run make:
 
$ make
 
5. Stop NetXMS server.
6. Stop NetXMS agent.
7. Check database for possible inconsistencies:
 
$ nxdbmgr check
 
Proceed to the next step only if database checker does not report any errors!
 
8. Run make install:
 
$ make install
 
9. Upgrade database:
 
$ nxdbmgr upgrade
 
10. Start NetXMS agent.
 
11. Start NetXMS server.
 
= Installing NetXMS Server on Windows =
1. Download the latest version from http://www.netxms.org/download, if you don't have it. You will need Windows installer (named netxms-''VERSION''.exe or netxms-''VERSION''-x64.exe, for example netxms-{{version}}.exe). Please note that in following steps ''VERSION'' will be used as a substitution for an actual version number.
 
2. Run the installer package on your server machine. Installation wizard will be shown. Follow the prompts until the Select Components window opens.
 
3. On the Select Components window, select NetXMS Server option and an appropriate database client library. You do not have to install database client library from NetXMS package, if it is already installed on the machine.
 
[[File:netxms_setup_components.png]]
 
If you plan to run NetXMS console from the same machine, select Administrator's Console option as well.
 
4. Follow the prompts until Ready to Install window opens.
 
5. On Ready to Install window, check whether everything is correct, then press the Install button.
 
6. After copying files, Server Configuration Wizard will open:
 
[[Image:server_config_step1.png]]
 
Press the Next button to start NetXMS server configuration.
 
7. Database selection window will open:
 
[[Image:server_config_step2.png]]
 
* Select the desired database engine and driver. For most databases, you will have two drivers available – native and ODBC. Please note that if you select ODBC, you will have to manually configure ODBC source.
* Enter the name of database server or ODBC source.
* In DBA login name and DBA password fields, enter database administrator’s login name and password. You have to fill these fields only if you have chosen Create new database option.
* Enter the desired database name, database user name and password. If you are not using ODBC, the wizard will create database and a user for you. If ODBC is used, database and user should be created beforehand.
 
'''Microsoft SQL note:'''
 
If you wish to use Windows authentication for database connectivity, use * (asterisk) as a login name and leave the password field blank. If you specify asterisk as DBA login, user with which you are logged in to Windows should have administrative rights to the database server. If you use asterisk as DB login, you should run NetXMS Server service as a user with appropriate rights to the database.
 
'''Oracle note:'''
 
We recommend to use native database driver (oracle.ddr).
 
8. On the next window, you will be prompted for various polling parameters:
 
[[Image:server_config_step3.png]]
 
* Check Run IP autodiscovery process check-box, if you wish NetXMS server to automatically discover your IP network.
* Increase number of status and configuration pollers if you plan to monitor large number of nodes.
 
9. On the next window, enter address of your SMTP server. NetXMS will use it to send notification e-mails. If you have mobile phone attached to management server via serial cable or USB, select mobile phone driver and COM port; otherwise, select "<nowiki><none></nowiki>".
 
10. Then next window will prompt you for logging method. Either check Event Log or select file, and press the Next button.
 
11. Windows service configuration window will appear:
 
[[Image:server_config_step6.png]]
 
In most situations, you can run NetXMS server under Local System account. You may need to run it under specific account if you are using Microsoft SQL database and Windows authentication, or for security reasons.
 
12. Windows service dependency window will appear:
 
[[Image:server_config_step7.png]]
 
If you have database engine running on same server, you can find it in service list and mark, so NetXMS server's service will depend on database service and service startup order will be correct.
 
13. Follow the prompts until server configuration will be complete. After successful server configuration, installation will be finished, and you will have NetXMS server up and running.
 
 
= Upgrading NetXMS Server on Windows =
1. Download the latest version from http://www.netxms.org/download, if you don't have it. You will need Windows installer (named netxms-''VERSION''.exe, for example netxms-{{version}}.exe).
 
2. Stop NetXMS server.
 
3. Check database for possible inconsistencies:
 
C:\NetXMS\bin> nxdbmgr check
 
Proceed to the next step only if database checker does not report any errors!
 
4. Run NetXMS installer and follow the prompts. Normally, you will not need to change any settings on installation wizard windows. Alternatively, you can run the installer with /SILENT option to disable any prompts:
 
C:\Download> netxms-{{version}}.exe /SILENT
 
5. Check whether NetXMS Server service is running again. If it's not, most likely you have to upgrade your database to newer version. To upgrade database, use nxdbmgr utility:
 
C:\NetXMS\bin> nxdbmgr upgrade
 
6. Start NetXMS server, if it is not already started.
 
= Default Credentials =
Login: admin
 
Password: netxms

Revision as of 19:41, 15 November 2017