Managing remote machines with cloud management gateway in Microsoft Endpoint Configuration Manager
Published Mar 18 2020 01:17 PM 147K Views
Microsoft

In light of the global situation that has escalated over the past weeks regarding COVID-19 and the coronavirus; there has been a significant increase in the number people working from home. Indeed, myself and the rest of the Microsoft Endpoint Manager team are among 100,000+ Redmond based Microsoft employees who are entering our third week of remote work.

 

This increase in the global workforce working from home is unsurprisingly putting an added focus from organizations on remote functionality and management. Not to mention an increased load and strain on services that were implemented to accommodate lower concurrent numbers of remote working employees.

 

Naturally we have seen an increase in the number of queries, questions and tweets around the tools and features Microsoft Endpoint Manager can offer in the way of remote management of the workforce. One of the most common topics I have had to field enquiries is around the use of cloud management gateway (CMG), usually in conjunction with keeping traffic off the VPN.

 

Firstly, let’s clarify some terms….

 

Internet-based client management is a longstanding concept in Configuration Manager whereby servers are placed in the DMZ and published to the Internet to allow clients to continue to be managed when roaming on the Internet.

 

Cloud management gateway, or as I shall refer to it in the rest of the blog, CMG for short, is a cloud service hosted in Azure that acts as a proxy for clients. It greatly simplifies the configuration required to manage clients on the Internet.

 

The final concept is cloud distribution point, also a cloud service hosted in Azure, that allows clients to retrieve content. For the purposes of simplicity, and because cloud distribution point has been deprecated in favor of enabling content distribution from a CMG, I will use the term “CMG” to refer to a content-enabled cloud management gateway for the remainder of this blog

 

Secondly, let’s talk about why clients will potentially still communicate over the VPN when a CMG is deployed. Essentially, the Configuration Manager client has logic that looks at several factors, including being able to resolve a management point and the internal domain. When these factors are not met, the client will evaluate as IsInternet=1 and will communicate with resources published to the Internet.  When a client is connected to a VPN it is likely that the client will meet enough criteria to consider itself IsInternet=0 which is why client traffic will go over the VPN and not the Internet even if split tunneling is configured to allow direct Internet traffic.

 

NOTE: Everything in this blog will require a split-tunnel VPN. If all the traffic is directed back to the corporate network by the VPN client, then even if the Configuration Manager client is ultimately going out to cloud services, it won’t be alleviating VPN traffic.

 

The good news is that there are a couple of configuration options that you can take to move traffic away from the VPN and directly to Internet sources. These options should hopefully free up some bandwidth for line of business traffic whilst ensuring clients remain managed and up to date.

 

When the VPN has a known IP range

 

If your VPN clients are sat neatly in a known IP range or ranges, then firstly you need to create boundaries in Configuration Manager to cover the VPN ranges:

 
 

Rob York_6-1584492420485.png

 

and then add them to a boundary group:

 

Rob York_1-1584492331636.png

 

Then you need to configure that boundary group to use cloud services. You do this on the references tab, to explicitly accommodate the CMG with the boundary group:

 

Rob York_2-1584492331659.png

 

And also on the options tab select  Prefer cloud based sources over on-premise sources

 

Rob York_3-1584492331671.png

 

This option will apply even if you don’t have a CMG, so can offer some respite to your VPN by directing clients to Microsoft Update for content.

 

When the VPN doesn’t have a known IP range

 

Admittedly this complicates matters, but we added the concept of default site boundary group in version 1610 as a replacement to the concept of fallback content location. This behavior means that if your VPN clients do not fall into a known boundary group, they can fallback to communicate with referenced site systems from the default site boundary group.

 

Again, add the CMG to the references tab

 

Rob York_4-1584492331682.png

 

NOTE: This will result in clients in the corporate network, but not in a known boundary, to connect to the CMG.

 

Force the client to Always Internet mode

 

If networking or boundary configuration makes either of the first two options unviable, you can always force the client to always consider itself IsInternet=1, effectively overriding the logic I talked about earlier. Toggling the client back and forth from explicitly Always Internet is not possible, hence why we make the previous options available. If needed, as a matter of last resort, you could (re)deploy the client using the CCMALWAYSINF parameter to ensure your remote clients are always managed by the CMG.

 

Finally, I wanted to call out an implementation within the Configuration Manager client when it comes to Microsoft Updates. You do not need to deploy your Microsoft software updates packages to the CMG: If a client is on the Internet communicating to a CMG, it will instead retrieve updates from Microsoft Updates. As long as the client can download directly from Microsoft Updates it will never download Microsoft updates from a CMG. Although, a good practice is to not deploy updates packages to a CMG that contain Microsoft Updates.

 

We had previously blocked the deploying of update packages to CMG and CDP for this very reason, but we relaxed the restriction in order to facilitate third party updates.

 

 

To allow clients to use cloud sources for Microsoft Update content, ensure you select the “If software updates are not available on distribution point in current, neighbor or site boundary groups, download content from Microsoft Updates” check box on the updates deployment:

 

Rob York_5-1584492331712.png

 

Rob York

@robdotyork

Program Manager

Microsoft Endpoint Manager

70 Comments
Brass Contributor

@Phil_Brandvold we have the same issue, and even though we have multiple management points, all of them also host a DP role with Software Update content. 
So what I did now (which was also confirmed by the MS engineer on our case as workaround) is splitting up our patching collections between VPN and on-prem devices with incremental updates... and using the deployments’ download settings to prevent VPN devices from using the content from local or neighbor sites.

 

Not the most ideal solution as some devices can still roam between on-prem and VPN but that should be a very small amount, and from initial tests it seems to be working ok for the most part. 

Copper Contributor

@Phil_Brandvold @Andy D'Hollander  Alternatively, all you need is a dedicated MP.  Should only take half a day to spin up a VM and install the required features\roles :).  I'd debateley say this is better, and easier to get rid of afterwards once this bug is resolved.

 

@Rob York appreciate you're a busy man.  Is there any rough timeline we can expect for this to be resolved?  Also, an official KB doc so people aren't spending days with PremSupport to eventually just find these comments themselves.

Copper Contributor

I am running CB1910, currently have IBCM deployed and have just set up Cloud Management Gateway with DP. Our VPN is configured with split tunneling. The on-prem DP's are blocked through the VPN tunnel, so users have had to end their VPN connection to receive content. CMG was set up to allow content to be received by remote clients whether or not a VPN connection is established. I am still having an issue receiving content when VPN is connected. I have created a VPN Boundary Group with the CMG and the VPN IP range boundary. The CMG is shown as the assigned management point in the client properties when a VPN connection is established. "Prefer cloud based sources over on-premise sources" is enabled in the VPN boundary group. When attempting to install from the Software Center, I see in the cas.log file after ContentLocationRequest is, "No reply received", "Failed to create Location Request Message body" and "GetLocationSyncEx3 failed with error 0x80004005". Do you have any thoughts what may be causing the issue?

Microsoft

@John Pine there is a known bug where user apps will not be available in software center if AAD is being used for auth. We're working on a fix. If that is not the issue here then i suggest you raise a case and support can dig into it.

Copper Contributor

@Rob York Thanks for the reply. I found your previous comment, Workaround is to make an MP available to the VPN boundary. Adding an internal MP to my VPN boundary group along with the CMG seems to work.

Brass Contributor

@Rob York Is there any ETA on that fix?
Is there any information we could provide to you or the team regarding our environment configuration or other items that could help your team? If so I'd be happy to do so. 

Copper Contributor

Hello!

We're experiencing a bit different problem: Internet clients connects through CMG just fine, but when client connects through VPN it cannot communicate with CMG and I can't see any applications in Software Center. If I set ClientAlwaysOnInternet=1 on the client and connect it through VPN everything works well.

We've requested MS PS and they said that there is 'some' issues with our VPN.

Which Assigned management point should be showed up in General tab of the client applet when it falls back into boundary group with CMG assigned?

I have ****.cloudapp.net/ccm_proxy.... Do you have the same? 

2020-05-10_01-03-54.png

Microsoft

@Andy D'Hollander No ETA at the moment, We've identified the issue but that is only part of the effort. Coding, testing and shipping will take some time. The recommended workaround is to have an MP available to the clients.

Brass Contributor

@Rob York Thanks for the update! The workaround works fine for us so far so no problem :) 

Copper Contributor

@Rob York How will we be notified when a fix is available for this bug? We tried the workaround but our network is not able to handle the load mainly because of windows updates and defender updates.

Copper Contributor

What service is running to determine if the connection type is internet or intranet and how often is it checking?

Copper Contributor

@Rob York

When you say "Overlapping boundaries are supported for content but you would probably still some some(?) clients going to on prem sources. Best option is to get the AD site split out", you mean that I should remove the VPN subnet from AD sites in active directory? Is it possible to exclude a subnet from the AD site boundary instead?

Brass Contributor

@Rob York  

Would the same issue apply "If a client is reporting as intranet and talking to CMG it wont use AAD auth. We're investigating. Workaround is to make an MP available to the VPN boundary", if a client is not using a VPN, but is actually on-premises and is showing Intranet. 

 

This is what we are seeing. We currently have two MPs on-premises and they are available to all boundaries.

Copper Contributor

Is this fixed in 2006? I'm on 2002 and have to add on-prem MPs to allow user assignments.

Microsoft
Copper Contributor

Awesome! Thanks so much! Looks like I need to upgrade then. :)

Copper Contributor

We are considering to implement CMG and have this question:
If I can control when the remote PCs wake up and assuming they are connect it
to the router, the PC should be able communicate with the CMG, correct?
For installing/uninstalling applications we would like to do this when
user is not working or using the VPN.

Copper Contributor

Hi Rob,

 

We would have the same issue (user apps not showing in softwarecenter) on some of Windows 10 hybrid joined device "when a client is reporting as intranet (connected over VPN to corporate network) and talking to CMG it use AAD auth but received the below message in SCClient.log. 

 

GetAadUserTokenInteractive returned an empty result object (Microsoft.SoftwareCenter.Client.Data.WmiDataConnector at GetAadUserToken)

 

Received empty AAD user token (Microsoft.SoftwareCenter.Client.Data.ACDataSource+<>c at <RefreshLocalSettingsAsync>b__16_0)

 

Workaround is to make an MP available to the VPN boundary" - This is not working as we already added MP to VPN boundary. Also we had upgraded our SCCM CB version to 2103. As per MS, this issue would be taken care post upgrading 2006 but our case the issue still persist.

 

Anyone has any solution who already raised a case with MS. Please advise.

Brass Contributor

Similar to Vijay, we too still have this issue for users who are remote and connected to the CMG (no VPN involved).  In this scenario any apps marked as Available to specific users or groups of users do not appear in the Software Center when that user is working remotely, though other apps that are Available for all devices do.  As soon as the user comes back into the office and connects the apps then appear correctly.

 

We are currently running SCCM 2103, and remote clients do seem to be reporting correctly through the CMG.  Looking in the logs, this does appear to be some kind of AAD auth token issue, though I'm no expert in this area.

 

Thoughts please?

Copper Contributor

Do you have a User Setting enabled in MECM? Thats works in our Education Company.

 

romanmensch_0-1630424148590.png

 

Version history
Last update:
‎Mar 18 2020 02:33 PM
Updated by: