→ 🚀What's New? Join Us for the Fall Product Launch! Register Now !

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
ChrisS
Engaged Sweeper III
Hi all,

I need a report that tells me which computers have offline files enabled for a large scale migration we are doing.

The location, at least for Windows 7 in WMI is:
Win32_OfflineFilesCache

on my PC (which has offline files enabled) it reports:
Active Enabled Location
True True C:\Windows\CSC


How can i query for this info in Lansweeper, and is the wmi class valid for xp also?

Many thanks for any help.

CS
1 ACCEPTED SOLUTION
Hemoco
Lansweeper Alumni
The specified WMI class isn't scanned. In Windows 7 there is a service called "Offline Files". If it is started, offline files is enabled. Use the report below to find Windows 7 machines with offline files enabled.

Select tblComputers.Computername, tblComputers.ComputerUnique,
tblComputers.Domain, tblServices.Caption, tblServices.Name,
tblServices.Pathname, tblServices.Started, tblServices.State
From tblComputers Inner Join
tblServices On tblComputers.Computername = tblServices.Computername
Where tblServices.Name = 'CscService' And tblServices.State = 'running'


For other operating systems you will have to scan registry keys. This article may provide some help.

View solution in original post

6 REPLIES 6
ChrisS
Engaged Sweeper III
Hi All,

I have worked this out and it seems to work well for me.
I have edited the report LanSweeper gave above for windows 7

Windows 7
Select Top 1000000 tblComputers.Computername, tblComputers.ComputerUnique,
tblComputers.Domain, tblComputers.LastknownIP, web40AllIPLocations.IPLocation,
tblServices.Name As Service, tblServices.Started, tblServices.State
From tblComputers Inner Join
tblServices On tblComputers.Computername = tblServices.Computername Inner Join
web40AllIPLocations On tblComputers.Computername =
web40AllIPLocations.Computername
Where tblServices.Name = 'CscService' And tblServices.State = 'running'
Order By tblComputers.Domain, web40AllIPLocations.IPLocation,
tblComputers.LastknownIP



For Windows XP

1. You need to add a registry scanning Key 1st
HKEY_LOCAL_MACHINE
SYSTEM\CurrentControlSet\Services\MRxSmb\Parameters
CSCEnabled

2. Then scan your Computers

3. Add the following report:

Select Top 1000000 tblComputers.Computername, tblComputers.ComputerUnique, tblComputers.Domain, tblComputers.LastknownIP, web40AllIPLocations.IPLocation, tblRegistry.Valuename As [Key], tblRegistry.Value As Enabled
From tblComputers Inner Join web40AllIPLocations OntblComputers.Computername = web40AllIPLocations.Computername Inner Join tblRegistry On tblComputers.Computername = tblRegistry.Computername
Where tblRegistry.Valuename = 'CSCEnabled' Order BytblComputers.Domain, web40AllIPLocations.IPLocation, tblComputers.LastknownIP


This is a good report for when you need to do migrations as it is important to take into account if a user is using offline files!

thanks

ChrisS
ChrisS wrote:
Hi All,

I have worked this out and it seems to work well for me.
I have edited the report LanSweeper gave above for windows 7

Windows 7
Select Top 1000000 tblComputers.Computername, tblComputers.ComputerUnique,
tblComputers.Domain, tblComputers.LastknownIP, web40AllIPLocations.IPLocation,
tblServices.Name As Service, tblServices.Started, tblServices.State
From tblComputers Inner Join
tblServices On tblComputers.Computername = tblServices.Computername Inner Join
web40AllIPLocations On tblComputers.Computername =
web40AllIPLocations.Computername
Where tblServices.Name = 'CscService' And tblServices.State = 'running'
Order By tblComputers.Domain, web40AllIPLocations.IPLocation,
tblComputers.LastknownIP


ChrisS


Is it possible to change the code so that it works with Lansweeper 5096?
Cause I get the "tblComputer" does not exist.
Thanks, Andreas
Andreas Gunnarsson wrote:
Is it possible to change the code so that it works with Lansweeper 5096?
Cause I get the "tblComputer" does not exist.

Use the report below for Lansweeper 5.0.
Select Top 1000000 tsysOS.Image As icon,
tblAssets.AssetID,
tblAssets.AssetName,
tblAssets.Domain,
tblAssets.IPAddress,
tsysIPLocations.IPLocation,
tblServicesUni.Name,
tblServices.Started,
tblServiceState.State
From tblAssets
Inner Join tblAssetCustom On tblAssets.AssetID = tblAssetCustom.AssetID
Inner Join tblServices On tblAssets.AssetID = tblServices.AssetID
Inner Join tblServiceState On tblServiceState.StateID = tblServices.StateID
Inner Join tblServicesUni On tblServicesUni.ServiceuniqueID =
tblServices.ServiceuniqueID
Inner Join tsysOS On tsysOS.OScode = tblAssets.OScode
Left Join tsysIPLocations On tblAssets.IPNumeric >= tsysIPLocations.EndIP And
tblAssets.IPNumeric <= tsysIPLocations.StartIP
Where tblServicesUni.Name = 'CscService' And tblServiceState.State = 'running'
And tblAssetCustom.State = 1
Order By tblAssets.Domain,
tsysIPLocations.IPLocation,
tblAssets.IPNumeric
Hemoco
Lansweeper Alumni
Please have a look at the article linked in our previous post. You may be able to determine your other computers' offline files status through the registry keys mentioned there.
ChrisS
Engaged Sweeper III
THANKYOU

That report is exactly what I'm after. Very helpful 🙂

my next question, is there a similar path/service for Windows XP?

EDIT: I have read there is no such service for XP, but any other help is appreciated


Thanks again

ChrisS
Hemoco
Lansweeper Alumni
The specified WMI class isn't scanned. In Windows 7 there is a service called "Offline Files". If it is started, offline files is enabled. Use the report below to find Windows 7 machines with offline files enabled.

Select tblComputers.Computername, tblComputers.ComputerUnique,
tblComputers.Domain, tblServices.Caption, tblServices.Name,
tblServices.Pathname, tblServices.Started, tblServices.State
From tblComputers Inner Join
tblServices On tblComputers.Computername = tblServices.Computername
Where tblServices.Name = 'CscService' And tblServices.State = 'running'


For other operating systems you will have to scan registry keys. This article may provide some help.