O R G A N I C / F E R T I L I Z E R: 11.11

Nov 23, 2011

sccm: computers with names greater than 15 characters

and coincidentally, blog posts with really long titles.

if you run into scenarios where you find that computers with longer than 15 characters are exhibiting strange issues in an application, you can root out these computers with configmgr or AD. while the computer itself may show a longer than 15 character machine name, the records for it in AD and configmgr show a truncated value.

this is interesting because the computer is registered with its long name in DNS. it can "interesting" when you see a truncated name that doesn't resolve (especially where WINS is involved and handles the resolution for netbios lookup adding further confusion.)

funny enough, where you root out this problem exists kind of on the same plane for both AD and configmgr. it's the DNS host name that gives it away! take a look a these screenshots -- from SCCM and AD, respectively:


(removed the computer names out of this screenshot)


so what do you do with this information, now that you know? well, let's look at ways of identifying it.

first of all, you can count out the characters to see how many are in the name. since dnsname and dnshostname have the same thing, we could use something like this:

((Get-QADComputer myComputer).dnshostname.split(".")[0]) | Measure-object -Character


now we can loop that into a general search for the entire domain:

Get-QADComputer -SearchRoot 'whatev you use' -SizeLimit 0 | where {($_.dnshostname.split(".")[0] | Measure-Object -Character).characters -gt 15}

if sql is your thing and you prefer to query configmgr, here's the sql query:

select distinct dnshostname0 
where LEN(dnshostname0) > 15

hope that helps!

Nov 16, 2011

sccm: how old is my data?

here is something I wrote up not too long ago for the benefit of some of my coworkers. it's nothing new and might be what most of you know, but I wanted to post it up just in case. it's a question I'm asked often... so it seemed like something worthy of sharing.


How old is my data?

Let me first summarize a few things. SCCM is generally configured to hold a set amount of data per given data type. In some cases, you may find that you have data that is older than the specified age value (90 today, 30 sometime soon). So what’s going on here? The short answer is, the data is still current. There are many things that comprise the composite object record. Let’s take my client for example. Here is a screen shot:


As you will notice, Agent Name, Agent Site, and Agent Time all contain numbers in brackets. The [#] is an index of the property, so to speak. For example, if I were interested in Heartbeat Discovery, I would read the values this way:

Agent Name[0] :      Heartbeat Discovery
Agent Site[0] : XYZ
Agent Time[0] : 10/28/2011 7:31:05 AM

As you can see, this discovery record for my client actually contains three distinct discoveries that continue to supply it with fresh discovery information.


When will my data age out?

Data ages out of SCCM when all of the discoveries cease to meet the criteria. For example, in the screenshot above, if Heartbeat Discovery no longer provided discovery data, the agent time would continue to get older and older while the other two discoveries would continue to stay up to date. As long as there are up to date discoveries for a composite record, the entire record is considered fresh.


Why does this matter?

If you look at the agent names, you’ll notice three. Heartbeat Discovery is the agent itself providing discovery data once a day. As the name implies, it’s a heartbeat basically saying – I AM ALIVE! The other two discoveries are Active Directory based. Normally, you will see that old data persists because of the AD discoveries.

As long as the computer account persists in AD, the AD discovery will pick it up and post the new agent time. As you see, the time value for AD discovery is very close to 12:00:00 AM when most of the AD discoveries are kicked off. The heartbeat data is usually started on machine startup, on the other hand and every 24 hours after that.