Kaseya Community

View Definitions - IP address range

This question is answered

I have been unable to figure out how to create a view based on a range of IP addresses. I can have it set to a single IP address, or an entire subnet, but not a specific range. 

For instance, I want a view that only includes the range of 192.168.0.100 - 192.168.0.254. Using 192.168.0.* does not work as it includes the IPs from .0-.99. I tried 192.168.0.* AND NOT <192.168.0.100 but that still included anything below .100.

Any idea how I can do this? The help documentation does not include anything about ranges. 

Verified Answer
  • I don't know if this would work, but you should be able to get pretty close using subnets.

    For example, 192.168.0.128/25 = 192.168.0.128 - 255

    and 192.168.0.96/27 = 192.168.0.96 - 127

    Using those two you could get your entire range with only four extras, which may or may not suffice. Things like this are why I always preach dividing networks into actual subnets, not pretty, human-readable ranges. It makes routing and generally working with them easier in the future.

    As a side note, for creating views for things that aren't naturally available in Kaseya, we have a stored procedure that runs nightly. First we create a view with only the 'Only show selected machine IDs' selected and then add a couple machines. Then find the ViewId in the viewDef table (select * from viewDev where viewName like 'NewViewName'). Then our procedure looks like:

    delete from viewCollection where viewId = <viewIdFromSelect>

    insert into viewCollection (viewId, agentGuid)

    select <viewIdFromSelect>, agentguid

    from ......

    Just finish that with the rest of your query to get the agentGuids you want in the view. Downside is the view isn't live, but if you can handle updating the view nightly, it is a simple way to create advanced views from data that isn't native to Kaseya. IP addresses are a little tricky because you have to split them around the '.', convert each octet to a number, and then compare each octet individually.

All Replies
  • I don't know if this would work, but you should be able to get pretty close using subnets.

    For example, 192.168.0.128/25 = 192.168.0.128 - 255

    and 192.168.0.96/27 = 192.168.0.96 - 127

    Using those two you could get your entire range with only four extras, which may or may not suffice. Things like this are why I always preach dividing networks into actual subnets, not pretty, human-readable ranges. It makes routing and generally working with them easier in the future.

    As a side note, for creating views for things that aren't naturally available in Kaseya, we have a stored procedure that runs nightly. First we create a view with only the 'Only show selected machine IDs' selected and then add a couple machines. Then find the ViewId in the viewDef table (select * from viewDev where viewName like 'NewViewName'). Then our procedure looks like:

    delete from viewCollection where viewId = <viewIdFromSelect>

    insert into viewCollection (viewId, agentGuid)

    select <viewIdFromSelect>, agentguid

    from ......

    Just finish that with the rest of your query to get the agentGuids you want in the view. Downside is the view isn't live, but if you can handle updating the view nightly, it is a simple way to create advanced views from data that isn't native to Kaseya. IP addresses are a little tricky because you have to split them around the '.', convert each octet to a number, and then compare each octet individually.

  • Ok I didn't think of using subnets in that field. Thanks for the other info as well.