Today we proudly released the next version of openITCOCKPIT 3.3.1.
We redesigned the status detail view for host and services. The new design will also improve your workflow, for example it is now possible to delete a scheduled downtime directly from the status details overview.
In addition we improved the representation of parent host outages, or if the associated host is in a none Up state.
With the new status details view, we also refactored the user permissions for external commands
like "Reset check time", "Schedule maintenance" and so on.
To enable an user to submit external commands, two conditions are required:
externalcommands
You can set the action permission externalcommands
at Administration Manage user roles.
We decided not to grant new privileges automatically, to avoid that users see objects or are allowed to actions they should not be.
With the new version, we release a complete rewrite of the downtime system in openITCOCKPIT. First of all, we separated "normally scheduled downtimes" from "recurring downtimes" in the menu.
We also added better filter options and the option to delete multiple downtimes at once.
We added a new overview for service group, which contain the host and service state.
If you create a new host or service or edit existing hosts and services, the interface will now always try to redirect you back to the previous page you were visiting.
We hope this will speed up your workflow.
We improved our Slack Notification Plugin. We added a two way implementation, so you can now acknowledge the state directly from Slack.
Also we improved the representation of the plugin output.
If you like to send "Push Notifications" to your smartphone, we added a new Notification Plugin for Pushover.
The required commands host-notify-by-pushover
and service-notify-by-pushover
will be created with every new installation of openITCOCKPIT automatically.
In your contact configuration, you need to create the custom macros with the name PUSHOVERUSER
and PUSHOVERAPP
. Set as value your user credentials,
you have got from the Pushover web site.
If you want to use the Pushover notification behind an HTTP/HTTPS proxy, please make sure to set the address and port of your HTTP/HTTPS proxy.
In one of our previous articles we described how to update an installation of openITCOCKPIT in detail. If you are already familiar with our update process, you can update to the new version in three easy steps:
tmux
sudo apt-get update
sudo apt-get dist-upgrade
Are you using Nagios or Naemon and want try openITCOCKPIT? No problem! We created a PHP script, which tries to import your existing Nagios or Naemon
configuration to a fresh instalation of openITCOCKPIT.
Once in a week our developers can choose a random project, they like to work on. We call this Happy Friday.
Unfortunately we don't have the time to finish every project by 100 percent.
Whenever we created something that could be useful, we publish it to our
GitHub account.
So maybe we missed a feature, or something is not working as expected but it is still worth to give it a shot.
This is basically the reason why we call it beta, we don't want to disappoint you 😉.
Also the migration setup is a bit complex at the moment and it would help, if you are an experienced linux user.
The project was successfully tested with different Nagios and Naemon configurations.
By writing your configurations files by hand, you have a lot of freedoms.
Unfortunately it is very hard to automatically import complex configuration files.
Instead of implementing every possible scenario, we decided to implement a default behavior which should fit 90% of the configurations out there.
define timeperiod{
timeperiod_name 24x7
alias 24x7
monday 00:00-24:00
tuesday 00:00-24:00
wednesday 00:00-24:00
thursday 00:00-24:00
friday 00:00-24:00
saturday 00:00-24:00
sunday 00:00-24:00
}
So maybe your definition of some complex time periods is broken after the import. If you use complex time periods,
you should check this after the import process is done.
openITCOCKPIT requires an host or service template for every host or service, that should be created. You can read more about
host and service templates in our Beginners guide. Due to the fact, that the objects which
are defined with register 0
are missing in the database, our import script needs to "guess" them.
Every host that will be created by the import script, simply uses the default host
template with the id 1
.
This host template exists by default on every openITCOCKPIT system.
The import script will create an service template of every check command
, which is defined in your configuration files.
The service template name, will be the same as the command name, converted to uppercase. So the check command check_ping
will become
the service template CHECK_PING
.
To keep the templates as generic as possible, the importer will set the following fields check_interval
, retry_interval
, notification_interval
, active_checks_enabled
and process_perf_data
to the most used value.
For example, you have ten Services using the check command check_ping with an check_interval of 1
and two services with an check_interval of 15
. Than the service template will use the value 1
as default value for check_interval
.
Please notice: The custom value for check_interval is not lost! The service will just overwrite the service template value with 15
.
The migration uses Statusengine as database backend, which does not support the
dumping host and service escalation configuration to the database anymore.
For this reason, you need to recreate your host and services escalations after the migration process.
Same as for Host- and Service escalations. You need to recreate your host and services depandencies after the migration process.
First of all, you need to install an instance of openITCOCKPIT. Please visit the download section for more information.
root
!
We will just use this machine to dump your monitoring configuration to a MySQL database. It is not important that the checks really work!
It does not matter if your current monitoring configuration is running on Nagios 3.x, Nagios 4.x or Naemon.
cd /tmp
wget https://labs.consol.de/naemon/release/v1.0.6/ubuntu16.04/amd64/naemon-core_1.0.6_ubuntu16.04_amd64.deb
wget https://labs.consol.de/naemon/release/v1.0.6/ubuntu16.04/amd64/libnaemon_1.0.6_ubuntu16.04_amd64.deb
dpkg -i libnaemon_1.0.6_ubuntu16.04_amd64.deb naemon-core_1.0.6_ubuntu16.04_amd64.deb
apt-get install -f -y
systemctl stop naemon
systemctl stop postfix
Statusengine (2.x) will dump all Naemon configuration items to a MySQL database.
apt-get install mysql-server
cd /tmp
wget https://github.com/nook24/statusengine/archive/2.1.3-1.tar.gz
tar xfv 2.1.3-1.tar.gz
cd statusengine-2.1.3-1/
./install.sh
cp statusengine/src/statusengine-naemon-1-0-5.o /opt/statusengine/statusengine-naemon-1-0-5.o
echo "broker_module=/opt/statusengine/statusengine-naemon-1-0-5.o use_log_data=0" > /etc/naemon/module-conf.d/statusengine.cfg
Now you need to connect Statusengine with your database. Due to the fact, that the system will only live for a very short time, we
will use the MySQL root
user for everything.
Open the file /opt/statusengine/cakephp/app/Config/database.php
and search for the line public $legacy = array(
.
Now pass your mysql root credentials, like in this example:
public $legacy = array(
'datasource' => 'Database/Mysql',
'persistent' => false,
'host' => 'localhost',
'login' => 'root',
'password' => 'passw0rd',
'database' => 'naemon',
'prefix' => 'naemon_',
'encoding' => 'utf8',
);
Now we can creat the database and table schema.
cd /tmp/statusengine-2.1.3-1/
mysql -u root -p < sql/naemon.sql
/opt/statusengine/cakephp/app/Console/cake schema update -y --plugin Legacy --file legacy_schema_innodb.php --connection legacy
Copy the file objects.cache
from your current monitoring system to /etc/naemon/conf.d/
.
scp root@current-monitoring.lan:/opt/naemon/var/objects.cache /etc/naemon/conf.d/objects.cache
If you don't know where this file is located on your currently running monitoring machine, open the nagios.cfg or naemon.cfg and look out for the line
object_cache_file=/opt/naemon/var/objects.cache
.
After you copied the file objects.cache
, you are new ready to load the configuration in the file /etc/naemon/naemon.cfg
.
Remove all predefined cfg_dir
and cfg_file
lines and add the following two lines:
cfg_dir=/etc/naemon/conf.d/templates/
cfg_file=/etc/naemon/conf.d/objects.cache
As already mentioned, we only need this system to dump all configuration objects to the MySQL database.
For this reason, we switch the the user naemon
and start Naemon Core in foreground.
sudo -u naemon /bin/bash
naemon /etc/naemon/naemon.cfg
Press CTRL+C
as soon as you can see these line (or after 10 minutes):
Successfully launched command file worker with pid 21162
gearman-job-server
and we don't need the Naemon Core anymore.
exit
to switch back to the user root
Now you need to start Statusengine, also in foreground mode, to get all required data into the database.
/opt/statusengine/cakephp/app/Console/cake statusengine_legacy -w
As soon as you can see the line Info: Finished dumping objects
you can kill Statusengine by pressing CTRL+C
.
Alternatively you can kill it after 10 minutes.
The openITCOCKPIT Configuration Importer it self is a PHP script. It will connect the the MySQL database to get all your configuration items, and create all objects on the openITCOCKPIT system via the HTTP API.
apt-get install git php-zip php-mysql
cd /tmp
curl -o composer-setup.php https://getcomposer.org/installer
php composer-setup.php
cp composer.phar /usr/local/bin/composer
cd /tmp
git clone https://github.com/it-novum/openITCOCKPIT-configuration-import.git
cd openITCOCKPIT-configuration-import/
composer install
If you also want to migrate all $USERx$
macros, you need to copy your resource.cfg
from your current
monitoring system.
scp root@current-monitoring.lan:/opt/openitc/nagios/etc/resource.cfg /tmp/openITCOCKPIT-configuration-import/resource.cfg
If you don't know where this file is located on your currently running monitoring machine, open the nagios.cfg or naemon.cfg and look out for the line
resource_file=/opt/openitc/nagios/etc/resource.cfg
.
You can set various configuration options. Open the file etc/config.yml
and adjust the folowing values to your environment
# Set the same value, as you use in your nagios.cfg or naemon.cfg.
interval_length: 60
# Path where the Importer will search for the resource.cfg
resource_cfg: resource.cfg
# 1 is the default config type of Statusengine - do not change
config_type: 1
# MySQL database host
mysql_host: 127.0.0.1
# MySQL database user
mysql_user: root
# MySQL database password
mysql_password: passw0rd
# MySQL database
mysql_database: naemon
# MySQL database table prefix
mysql_table_prefix: naemon
# IP address of your openITCOCKPIT V3 System
oitc_host: 192.168.1.10
# e-mail address for login
oitc_user: admin@openitcockpit.io
# Password of the given user
oitc_password: password123
Now you are ready to start the migration process.
php bin/Importer.php
If the process is finished, you can destroy this machine and continue working with openITCOCKPIT!
If you found a bug or have some issues running the import script, please create an issue at our GitHub repository.
Today we have released the next version of openITCOCKPIT 3.3.
One of the new features is the System health overview. A cron job is monitoring all important background processes and system metrics. As soon as an issue is detected, System health overview will change its state into warning or critical depending on the possible impact of the issue.
To avoid complete page reloads, we refactored high-traffic pages like the host and service overviews with AngularJS. Due to the new frontend framework, filter requests or pagination are completely handled by an API request instead of an complete page reload.
Also, the MySQL database is a common bottleneck. With the new version, we added a Redis in-memory database that will cache heavy operations like calculating user permissions.
To be able to add more filter options, we developed a completely new filter component and added it to the most visited pages. With every new version, the new filter will be added to more pages.
In the Log entries overview it is now possible to filter by one or more hosts. This makes debugging easier in case of an error, for example if you want to track why a notification was suppressed.
Is openITCOCKPIT theme too light or too dark? We adjusted the Design Module and the inbuilt themes, so it's easier to create your own style.
You now also have the option to add your logo to the top menu bar.
In one of our previous articles we described how to update an installation of openITCOCKPIT in detail. If you are already familiar with our update process, you can update to the new version in three easy steps:
tmux
apt-get update
apt-get dist-upgrade
One of your new year's resolutions should be, to update your openITCOCKPIT .
Whenever a new version of openITCOCKPIT is available, you will see a notice at the package manager:
From time to time we need to do some long running database updates. For this reason you should always run the update from a screen
or tmux
session.
While the database update is in progress, your monitoring is still available and schedules checks.
Long running database updates will always print a status information, like in the following example:
Convert table nagios_logentries from int to bigint(20) unsigned. This could take awhile...
All database changes will be applied full automatically - no manual action is required.
nagios.cfg
All openITCOCKPIT configuration files, are located in the directory /etc/openitcockpit
.
If you have modified one of the configuration files manually, apt
will offer you the following options:
Most of the time you will see this notice for the file /etc/openitcockpit/nagios.cfg
. This will happen, if we update the Nagios or Naemon Core to a new version.
To avoid any issues, you should always use the nagios.cfg
we ship with our packages (Option 1). Experienced users can also merge the files together.
To reapply your manual changes, after the update is done, you should create a backup of the file /etc/openitcockpit/nagios.cfg
first.
Example:
cp /etc/openitcockpit/nagios.cfg /root/nagios.cfg_upgrade
tmux
sudo apt-get update
sudo apt-get dist-upgrade
Yes, that's all .
Happy new year, your openITCOCKPIT Team!
Since openITCOCKPIT Version 3.0.11-6, which was released in June 2017, we moved our APT repository to a new URL https://packages.openitcockpit.com/.
To avoid manual user actions, our packages will update your sources.list automatically, to use the new repository.
However, we are still monitoring a few downloads from the old repository.
As already mentioned, usually openITCOCKPIT will update automatically to the new repository.
Via the Interface
Browse to Administration Package Manager. If you are still on the old repository, you will see the following warning:
Via the CLI
Make sure that the file /etc/apt/sources.list.d/openitcockpit.list
contains our new repository https://packages.openitcockpit.com
.
Import the repository key:
apt-key adv --recv --keyserver hkp://keyserver.ubuntu.com 1148DA8E
Add the new repository to your sources.list. In this example for Ubuntu Xenial:
echo 'deb https://packages.openitcockpit.com/repositories/xenial xenial main' > /etc/apt/sources.list.d/openitcockpit.list
apt-get update
You can find all supported distributions in our download section or on our GitHub Repository.
© 2019 it-novum GmbH - All Rights Reserved