login vsi company logo login vsi company logo 250x40

 

Avoid VDI problems. Test with Login VSI.

Learn how our industry-standard software solutions can benefit your business

Learn more about our products

  • Home
  • Blog
  • Login AM
  • SCCM Control Component - Prevent Interference with Login AM 2012

SCCM Control Component - Prevent Interference with Login AM 2012

SCCM Control Component - Prevent Interference with Login AM 2012

If you are, out of business reasons, in the situation that your servers can not completely be managed by Login AM or you need to share your maintenance window with, for example SCCM, then you need to be sure that none of these deployment solutions interfere with each other. 

For this situation we developed a component that takes care of the SCCM 2007 Agent.

To be able to deploy and maintain clients with Login AM, without having problems with the SCCM Agent, a custom component with the goal to control the SCCM Agent has been developed. This blog describes the SCCM Control Component.

This custom component is placed under the Solution 4 Component.

custom component for controling the sccm agent

Custom component for controling the SCCM Agent

The component has a System ActionSet with two phases:

system actionset

System ActionSet

System - StartUpBegin

This phase is started after every reboot of the Login AM Client. It contains two tasks.

system startupbegin sccm copy

System StartIpBegin - SCCM copy

First task is the SCCM-Copy.ps1 script – it copies all necessary files like the SCCM-automation.dll from the S4_Sources folder to the %S4_Files%\Framework\SCCM folder on the client.

The second task is the SCCM-Client-disable.ps1 script that is responsible for disabling the SCCM service if there are no deployments currently running, otherwise the script will wait until the SCCM Agent service is inactive.

System - StartUpEnd

This phase contains a custom action set that executes a script responsible for enabling the SCCM agent again. Script name is SCCM-Client-enable.ps1.

system startupend sccm client enable

System StartUpEnd - SCCM Client enable

Integration in component set Login AM

The custom component SCCM Control needs to be integrated in a component. As the scripts needs to run during deployment phase and every maintenance task, the best place to integrate it has been the Solution4 Base component set.

As the SCCM Client needs to be disabled before the Login AM Deployment starts it is necessary to change the startupBeginOrderNumber as shown in the screen shot below.

solution 4 sccm control

Solution 4 SCCM Control

Changes to standard Login AM framework

To be able to control the SCCM Agent also during Login AM Initialization we needed to change one small thing to the standard Login AM framework files.

The file that has been modified is Initialize-Solution4.ps1 and is located in the following folder:

%S4_Files%\Components\Solution4\Framework\Extensions\Framework\General

The section that has been modified is the section that builds the init script on the S4 client. The section is between row 116 and 123.

The change in this file is that if a file named pre-init.ps1 exists in the S4-Files location, this will be executed before the standard init.ps1 script is executed. In this case the pre-init.ps1 script does nearly the same as the SCCM-disable.ps1 script, it disables the SCCM Agent service.

#Create Init script
Set-Content -path "\\$ComputerName\admin$\Initialize-Solution4.ps1" 
-value "$s4_files\Init.ps1 -e $S4_EnvironmentID" | out-null
Add-Content -path "\\$ComputerName\admin$\Initialize-Solution4.ps1" 
-value "schtasks.exe /Delete /TN `"Solution4 Initialization`" /F"

After:

#Create Init script
If (Test-Path -Path "$S4_files\pre-init.ps1") {
	Set-Content -Path "\\$ComputerName\admin$\Initialize-Solution4.ps1" 
-value "$s4_files\Pre-Init.ps1" | out-null
	Add-Content -path "\\$ComputerName\admin$\Initialize-Solution4.ps1" 
-value "$s4_files\Init.ps1 -e $S4_EnvironmentID" | out-null
} Else {
	Set-Content -path "\\$ComputerName\admin$\Initialize-Solution4.ps1" 
-value "$s4_files\Init.ps1 -e $S4_EnvironmentID" | out-null
}
Add-Content -path "\\$ComputerName\admin$\Initialize-Solution4.ps1" 
-value "schtasks.exe /Delete /TN `"Solution4 Initialization`" /F"

This modification will probably move into the standard of future Login AM versions so that every customer has the possibility to execute necessary tasks before the initialization of Login AM.

The necessary scripts and the component itself can be found here and are provided “as is” without warranty.

 


 

Start using Login VSI today

Our industry-standard software is built to help you avoid problems, lower costs and improve performance. Request a Quote or get your free Trial below, and benefit from our award-winning services.

Free Price Request  Your Free Trial

 


About the company Login VSI

The company Login VSI provides end-user performance insights for virtualized desktop and server-based computing environments. Enterprise IT departments use flagship product Login VSI (for load testing) and Login PI (for continuity testing) in all phases of their virtual desktop deployment—from planning to deployment to change management—to build and safeguard a good performance, a high availability, and (as a result) a good and consistent end-user experience. For more information about Login VSI or for a free test license contact us.

Tags: How-to, Microsoft, Login AM

Popular Blogs

Login VSI officially recognized as an integration partner for WVD by Microsoft

Windows Virtual Desktop

I’m excited to share with you that as of this week Login VSI has officially been recognized as an integration partner for Windows Virtual Desktop (WVD) by Microsoft. Continue Reading
Join us at VMworld 2019 - Booth #866

Join us at VMworld 2019 - Booth #866

Join us at VMworld 2019 - Booth #866 Are you attending VMworld in San Francisco next week? Great, we are too! Continue Reading
State Of The Union Survey Results 2019

State of EUC Survey Results

State of EUC Survey Results At community site VDILIKEAPRO.com we recently surveyed almost 600 people who work in the End User Computing (EUC) industry with a focus on VDI and SBC. Continue Reading
Login VSI at VMworld 2019 - Our Debrief

VMworld 2019 - Our Debrief

VMworld 2019 It’s that time of the year again, we’ve just wrapped up VMworld US and it was great meeting many folks on the expo floor, vendor booths, sessions and of course for a drink in the evening. Continue Reading
Windows Virtual Desktop - Update - December 2019

Windows Virtual Desktop Enhanced in the Latest Update

Planning to move to Windows Virtual Desktop and/or Citrix Managed Desktop? A lot has already been written about Windows Virtual Desktop (WVD) in the last months and while I had my initial concerns on this service many people are suggesting that they are willing to move to a platform like WVD in the next two years. Continue Reading
Login VSI - Blog - 4 Things to Consider when Running Office 365 in the Cloud

4 Things to Consider when Running Office 365 in the Cloud

Recently a customer decided to move their entire VDI infrastructure into the cloud. The VDI environment was approximately 20,000 users. As you can imagine there are a lot of design decisions necessary to ensure the success of this migration. Continue Reading
Cookie Settings