IPv6 collection?

andyinindy
Contributor II

Hello.

I noticed that neither the 8.73 nor the 9.24 JSS seem to collect the IPv6 addresses of our systems. This is an issue for us as we move to implement IPv6 on our network. I noticed a feature request here:

https://jamfnation.jamfsoftware.com/featureRequest.html?id=937

I have upvoted this, but it seems that we will need to collect this data manually for the time being. Perhaps a script triggered by the Network State Change trigger that collects the data, runs a recon, and stores it in an EA?

Wish I didn't have to do this manually... I am surprised that the suite doesn't have IPv6 support built-in.

--Andy

3 REPLIES 3

tron_jones
Release Candidate Programs Tester

You could make a policy that is "Ongoing" with "Network State Change" that is configured to do a "Recon". Add this EA and it will grab the IPv6 Address. No IPv6 address returns a result of "none".

#!/bin/bash
#3-3-13 
#Get IPv6 Address as an Extension Attribute

#Change "NetworkService" to "Ethernet", "Wi-Fi", etc. for the service you want to get address from

IPv6=`networksetup -getinfo **"NetworkService"** | grep "IPv6 IP address:" | cut -d " " -f4`

echo "<result>$IPv6</result>"

andyinindy
Contributor II

Yeah, thanks @tron_jones, this is what we were thinking as well. However, we need to grab the address for only the active interface. I grabbed this code from teh inerwebs:

#!/bin/bash

SERVICE_GUID=`printf "open
get State:/Network/Global/IPv4
d.show" | scutil | grep "PrimaryService" | awk '{print $3}'`

SERVICE_NAME=`printf "open
get Setup:/Network/Service/$SERVICE_GUID
d.show" | scutil | grep "UserDefinedName" | awk -F': ' '{print $2}'`

networksetup -getinfo $SERVICE_NAME | grep "IPv6 IP address" | awk -F ":" '{print $2}' | sed 's/^[ 	]*//'

Still, it sucks that this is something that we need to do manually. Why can't the JSS capture the IPv6 address just like it does the IPv4 address?

mm2270
Legendary Contributor III
Why can't the JSS capture the IPv6 address just like it does the IPv4 address?

Agreed. While this doesn't impact us right now, it seems insane to need to run a full recon against your Macs just to capture something that should only take a split second to grab via script. I suspect at some point JAMF will build in something that allows clients to send updated IPv6 addresses to their records on each check in, just as it does now with IPv4.