Menu

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts Menu

Messages - Alex Kirhenshtein

#601
sample nxagentd.conf: Subagent=ups.nsm
[ups]
Device = 0:"COM1:":MEGATEC


Check wiki for more details: https://wiki.netxms.org/wiki/Uninterruptible_Power_Supply_(UPS)_Monitoring
#602
Right now it's RS232-only. We have plans to integrate with NUT (they have windows version too), but definitely not in next release.
#603
Hello.

APT use it's own keyring in /etc/apt/trusted.gpg and /etc/apt/trusted.gpg.d/*.gpg
You can check that: gpg --no-default-keyring --keyring /etc/apt/trusted.gpg --list-keys

Keys 7638D0442B90D010 and 9D6D8F6BC857C906 are Debian release keys, you need to install them:
apt-get install debian-keyring debian-archive-keyring

wheezy/main contains only stable version (1.2.17 at the moment), so unless you change source to "wheezy/beta", you don't need to explicitly specify version.
#604
General Support / Re: Portech SMS Driver
May 12, 2015, 01:57:27 PM
Change SMSDrvConfig to
host=192.168.50.200;login=voip;password=1234;mode=TEXT
#605
Часть есть в документации: https://www.netxms.org/documentation/adminguide/nxsl.html
Часть есть в Wiki: https://wiki.netxms.org/wiki/Scripting_Guide
#606
General Support / Re: Nagios integration
May 11, 2015, 10:49:22 PM
Yes, it's part of agent configuration (nxagentd.conf).
You can use single instance of the agent, for example:
ExternalParameter=CheckDiskCustom(*):/usr/lib64/nagios/plugins/check_nrpe -H $1 -c check_disk_custom -a 20 10 / >/dev/null 2>&1 ; echo $$?

then configure DCIs on the server: CheckDiskCustom(webserver), CheckDiskCustom(dbserver), etc. $1 will be int he command will be replaced with first DCI parameter, $2 will be replaced with second and so on.

If you want these DCIs to appear on the target nodes (e.g webserver) instead of keeping them all on the node where agent is installed – create them there and select server where agent is running as DCI proxy. Check this post for additional explanation: https://www.netxms.org/forum/configuration/netxms-agent-checks-on-non-agent-compatible-hosts/
#607
General Support / Re: Nagios integration
May 11, 2015, 06:37:28 PM
You can add them as external parameter (please note that "$" is escaped):
ExternalParameter=CheckDiskCustom:/usr/lib64/nagios/plugins/check_nrpe -H webserver -c check_disk_custom -a 20 10 / >/dev/null 2>&1 ; echo $$?
#608
Альтернативный вариант:if ($1 match "AC voltage: ([0-9]+) V") {
   return $1; // тут будет значение группы ([0-9]+)
}
return $1;

#609
Баг выглядит знакомым – обновите сервер на M4, скорее всего поможет.
#610
Сервер не должен падать. Включите пожалуйста сохранение dump файлов (https://www.netxms.org/documentation/adminguide/troubleshooting.html#enable-crash-dump-generation) и пришлите их на [email protected].

Quote from: parovoZZ on May 06, 2015, 01:37:31 PM
А из таблицы-то как получить значения? Вставляю колонки, прописываю OID и сервер уходит в ошибку. Перезапускаю службу и все изменения исчезают.
#611
I suggest you to change it from ExternalParameter to ExternalParameterProvider, this way data collection will work faster.
Detailed description: https://wiki.netxms.org/wiki/ExternalParametersProvider
#612
You can try to create ps1 script like this:

add-pssnapin Microsoft.Exchange.Management.PowerShell.E2010
Get-MailboxDatabaseCopyStatus | fl -Property Status
#613
General Support / Re: Dashboard theme
May 05, 2015, 12:24:22 PM
Not at the moment, but I like the idea. Registered in bug tracker: https://dev.raden.solutions/issues/820
#614
You can automate it a bit using nxshell (which is python internally) – generate CSV or xlsx file.
However, if you want fully automated reports – you need to use some kind of reporting engine, either built-in Jasper or some external solution.

Sample script which export summary table into csv file:#!/usr/bin/env python
# -*- coding: utf-8 -*-

import csv, sys

menuPath = "Table1" # Table's "Menu Path"
baseObjectId = 2 # Infrastructure Services
outputFile = 'test.csv'

for table in session.listDciSummaryTables():
    if table.getMenuPath() == menuPath:
        result = session.queryDciSummaryTable(table.getId(), baseObjectId)
        if result:
            with open(outputFile, 'w') as f:
                w = csv.writer(f, dialect='excel')
                columns = []
                for c in result.getColumns():
                    columns.append(c.getDisplayName())
                w.writerow(columns) # Header

                for row in result.getAllRows():
                    cells = []
                    for i in range(0, row.size()):
                        cells.append(row.get(i).getValue())
                    w.writerow(cells)
#615
Announcements / Re: NetXMS 2.0-M4 released
April 30, 2015, 09:57:03 PM
Hello.

That's a bug in nxshell. I've put fixed version on the web, please download it again (https://www.netxms.org/download/nxshell-2.0-M4.jar).

Quote from: jhuliagraziella on April 30, 2015, 09:00:46 PM
Hi!
I'm having a problem after updating to version M4.
I started making some scripts to add and configure nodes in python and tested them using version M2, they worked perfectly! But now they simply don't even run.
When I run this command:

java -Dnetxms.server=127.0.0.1 -Dnetxms.user=admin -jar nxshell-2.0-M4.jar script.py

I get the following error:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: No module named api

I verified my scripts and it looks everything is alright... :-\ What can I do about it?