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 - zshnet

#16
General Support / Make missing data all zeros?
June 27, 2016, 06:46:29 PM
Hello all,

We have a lot of nodes that flap on SNMP availability due to routing issues. However, graphs can be deceiving as they simply replace any empty zones with a line connecting the two pieces of "real" data on either side.

Is there a good way to replace lost data with zeros, -1's, anything to make it obvious that it's an outage? I was thinking at worst I could add a transformation script, but something smarter would be preferred.

Thanks,
Zach
#17
Ah. It would appear I misunderstood what this means. I was hoping to filter tools based on which OS the client is running, as many of our object tools are local commands to the client.

Is there any way to do that? If not, we'll stick with our nested menus.

Thanks,
Zach
#18
Hi all,

I'm interested in filtering object tools by OS, as we have to keep up a few tools for linux, mac, and windows and it's starting to crowd menus.

I know there's a System OS name filter on object tools, but I could not figure out (by guessing likely candidates) what the OS names might be. Is there a way to check what NetXMS thinks my OS name is?

Thanks,
Zach
#19
Yes, that's what I'm saying. Since you deleted the node, it's not in the entire network anymore. You are only searching nodes in your network, when you select "Entire Network." However, I would suggest taking Tatjana's advice and checking on the server configuration, so that it doesn't happen again.
#20
Hey, thanks! That works perfectly. Thanks again for all your work + help!

Have a good one,
Zach
#21
Hi there,

Not sure if this is helpful to your issue, but alt-shift-a opens the alarm page for whatever node you've selected while F8 opens the alarm browser for all alarms. My suspicion is you were opening Alt-Shift-A while selecting a container for all items in your network, which would of course not contain the deleted node. Thus, when you click F8, an extra alarm appeared because it shows all alarms, regardless of the node. Also, in my experience, deleting or unmanaging a node does not remove all alarms relating to that node, so before/after deleting it you need to delete all alarms relating to that node.

Hope that helps!
Thanks,
Zach
#22
For some quick information, I chose this event because it was not filtering on event_severity, so I gave ID a try, and it seems to similarly not work. I have pasted the event below, so that you can see it exists.

27628   19.05.2016 11:56:32   Karmaloop-R1   0   SYS_NODE_CRITICAL   Critical   Node status changed to CRITICAL      0
#23
One last question, I hope! It appears to not be filtering anything. Running the following code, I get five events, 10, 11, 12, 13, 109. The filter should have spat out 27628, right? If I pull the columnfilter from the logfilter, I get that the filter is still in place, but I don't seem to get any filtering. Any guesses?



eventLog = session.openServerLog("EventLog")

columnFilter = ColumnFilter(ColumnFilter.EQUALS,27628)
columnFilter.setNumericValue(27628)
logFilter = LogFilter()
logFilter.setColumnFilter("event_id",columnFilter)
#print(columnFilter.getNumericValue())
#print(columnFilter.getOperation())
fill = logFilter.getColumnFilter("event_id")
print(fill.getNumericValue())
eventLog.query(logFilter)

table = eventLog.retrieveData(0,5)
for j in range(table.getRowCount()):
    #for i in range(table.getColumnCount()):
    print(table.getColumnDisplayName(0))
    print(table.getCellValue(j,0))


output is:
27628 [output of fill.getNumericValue()]
event_id
10
event_id
11
event_id
12
event_id
13
event_id
109
#24
That was it! I looked in the postgresql log:

2016-06-20 12:37:31 EDT ERROR:  column "source" does not exist at character 159
2016-06-20 12:37:31 EDT STATEMENT:  SELECT event_id,event_timestamp,event_source,dci_id,event_code,event_severity,event_message,user_tag,root_event_id FROM event_log WHERE event_id<=934558 AND (Source BETWEEN 0 AND 8153) LIMIT 1000

I guess the column isn't named Source? I'll have to look in the postgresql database to see what's there, unless you have a better idea of the column name.

Thanks,
Zach
#25
Good to know. We're currently running really hard on Debug levels, I think. The only relevant line I could find in any of the five (netxmsd.0/1/2/3/4) logfiles was this:
[20-Jun-2016 12:31:54.204] [DEBUG] [CLSN-4] User [email protected] authenticated (language=en clientInfo="nxjclient/2.0.3 (Linux 3.19.0-58-generic; libnxcl 2.0.3)")

Our debug level is currently at 6. We have a million of these messages:
[20-Jun-2016 12:31:54.245] [DEBUG] [CLSN-4] Sending message CMD_OBJECT

which is making it a bit hard to read through the logs. Searching for "database" "nxc" or similar terms got me nothing. Any guesses? Should I try to dig into the postgresql logs?

Thanks,
Zach
#26
I looked at it once but I can't seem to remember where the log file should be located on Linux. Any suggestions as to where I could look?

Thanks,
Zach
#27
Hi all,

I figured this belongs in a different topic. I am trying to query the event log, and am instead getting a Databaase Failure error of the following:


Traceback (most recent call last):
  File "nxshell_eventcounter.py", line 8, in <module>
    eventLog.query(logFilter)
at org.netxms.client.NXCSession.waitForRCC(NXCSession.java:1536)
at org.netxms.client.log.Log.query(Log.java:121)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)

org.netxms.client.NXCException: org.netxms.client.NXCException: Database failure



Any thoughts? I'm worried the Columfilter is being set incorrectly. My eventual goal is to use a column filter to query events only of a certain severity, but I figured I would start easy. My code is reproduced below:



eventLog = session.openServerLog("EventLog")

columnFilter = ColumnFilter(ColumnFilter.EQUALS,8153)
logFilter = LogFilter()
logFilter.setColumnFilter("Source",columnFilter)

eventLog.query(logFilter)

table = eventLog.retrieveData(0,2)


Thanks,
Zach
#28
I could have sworn I tried that. Well, thanks for the help! Feeling a bit foolish about that.

Thanks,
Zach
#29
Hi all,

I can see in the nxshell docs that I can get logs out of the server. However, it requires a string to get the right log. I tried "Event Log" "eventlog" "events" and a few others but can't seem to guess the correct string to pull the event log from the server. Can anyone point me to a list of the log strings?

For the curious, I'm attempting to build an audit of our events every night, and email an easy-to-read summary of what occurred every morning. We have a network with a huge number of devices, so the event log can be pretty dense. Rather than seeking out the event log on devices, this way engineering is forced to see problems in the network each morning. If you might have a better NetXMS way to do this without scripting, I'm all ears, but as a programmer scripting is usually my first stop.

Thanks,
Zach
#30
To quote my co-worker "That's an obvious button that none of us found before"

Thanks so much! I knew this had to be a solved problem.