This discussion has been locked. The information referenced herein may be inaccurate due to age, software updates, or external references.
You can no longer post new replies to this discussion. If you have a similar question you can start a new discussion in this forum.

Node Related Syslog Messages widget doesn't show any syslogs

I have recently upgraded to NPM 2020.2.  When I look at the syslog viewer I see the messages, for a node, but when I look at the "Node Related Syslog messages" widget for the same node I don't see any messages for that node. 

Has anyone run into this issue?  Does anyone know how to fix it?

  • That's a legacy widget and unfortunately no replacement was added when they updated the syslogs a few versions back. If you search there was a thread on thwack where people created new versions using swql.
  • SELECT TOP 200 DateTime, Message FROM Orion.SysLog --WHERE Message LIKE '%YourSearchHere%' ORDER BY DateTime DESC
  • Can you please give some examples of what "MySearchHere"  might include.   I tried running that, but meaningless without a valid variable.

  • Create a SWQL query widget and add in the following to the Custom SWQL Query field. (Change orion_server_name to your actual server name) This will show the last 30 syslog messages for that node. At the bottom there the code if you want to use the search option as well. Just tick the Enable Search box and add in that bit of code.

    SELECT TOP 30

    let.Name AS [Message Type]

    ,Level AS [Severity]

    ,TOLOCAL(DateTime) AS [Log Time]

    ,SUBSTRING(Message,1,100) AS Message

    ,CONCAT('orion_server_name','/.../syslog') AS _linkfor_Message

    FROM Orion.OLM.LogEntry le

    JOIN Orion.OLM.LogEntryType let ON le.LogEntryTypeID = let.LogEntryTypeID

    WHERE NodeID = '${NodeID}'

    --AND le.Message LIKE '%${SEARCH_STRING}%' -- Remove The -- From beginning for the "Search SWQL Query" Box

    ORDER BY DATETIME DESC

  • Great query, thanks for sharing.

  • I struggled to work out what the Custom SWQL widget you guys are mentioning to put the code into. I eventally found it.

    Its called the Custom Query Widget. took me about 20 mins to understand what was being mentioned.

    You can find it when you click on Customize page, Select Add Widget, Click on the Unknown Group and Select Custom Query.

    Once you drag it onto the node page, click on Edit and copy the code from below.

  • Thank you for sharing.

    Noticed something odd when I put it in to a custom query:

    Updated orion_server_name and,got an unexpected error. 

    Changed the name to include https// solved part of that but not the whole thing.

    Wondering why the concat line did not work above. Any advice gratefully received.

    For now replaced that concat line with:

    ,'your_server_name/ui/orionlog/logviewer/now/1hours/0/syslog' AS _linkfor_Message

    Is it possible to get the hotlink to go to the SysLog View filtered on the device/message already, not just the unfiltered view?

  • Changed the link to:

    'your_server_name/.../LogEntryDetails.aspx +ToString(LogEntryID) AS [_linkfor_Message]

    seems to work, not in the browser so you can scroll up and down but opens up this event in a new window