🤘 0 reputation

selgan

Standard

Joined: 8/24/2016

Last seen: 1/23/2019

Activity
  • Windows Management Framework 5.1
  • DFS adds a huge amount of complexity to an environment. We moved away from it because it caused more issues than it solved. I chose PDQ because it's so simple and easy to use. Simplicity is what I'm aiming for. Most of our endpoints at our remote sites are thin clients but we have some thick clients. I'm looking into a way to do this with DNS. I want to make an A record in DNS for each site that uses the same DNS name but points to a different IP. Not sure MS DNS can do that though. Once I get that figured out, I could then use robocopy scripts to keep my repositories in sync. 

  • It would be really cool if you could define repositories based on subnet(s) for pull scenarios. This would be done in preferences so that Auto Deploy jobs could leverage that rather than import your packages and create a different package for each subnet. We have 16 locations so this would get messy.

  • Found out how. Resubmitting back. Thanks!

     

    <?xml version="1.0" encoding="utf-8"?>
    <AdminArsenal.Export Code="PDQDeploy" Name="PDQ Deploy" Version="11.2.0.0" MinimumVersion="3.1">
    <Package>
    <PackageDefinition name="Definition">
    <CopyMode>Default</CopyMode>
    <InventoryScanProfileId value="null" />
    <RunAs value="null" />
    <ScanAfterDeployment value="null" />
    <Steps type="list">
    <CommandStep>
    <Command>cd /D C:\users
    for /D %%a in (*.*) do DEL /F /S /Q "%%a\Local Settings\Temp\*.*"
    for /D %%a in (*.*) do FOR /D %%b IN ("%%a\Local Settings\Temp\*.*") DO RMDIR /S /Q "%%b"
    for /D %%a in (*.*) do DEL /F /S /Q "%%a\Local Settings\Temporary Internet Files\*.*"
    for /D %%a in (*.*) do FOR /D %%b IN ("%%a\Local Settings\Temporary Internet Files\*.*") DO RMDIR /S /Q "%%b"</Command>
    <Files></Files>
    <SuccessCodes>0,1,255</SuccessCodes>
    <RunAs value="null" />
    <Conditions type="list">
    <PackageStepCondition>
    <Architecture>Both</Architecture>
    <Version>All</Version>
    <TypeName>OperatingSystem</TypeName>
    </PackageStepCondition>
    <PackageStepCondition>
    <IsUserLoggedOn>AlwaysRun</IsUserLoggedOn>
    <TypeName>LoggedOnUser</TypeName>
    </PackageStepCondition>
    </Conditions>
    <ErrorMode>StopDeploymentFail</ErrorMode>
    <IsEnabled value="true" />
    <Title>Clean User Appdata Temp Files-Folders</Title>
    <TypeName>Command</TypeName>
    </CommandStep>
    <CommandStep>
    <Command>del /q /s %systemroot%\temp\*
    for /d %%x in (%systemroot%\temp\*) do @rd /s /q "%%x"</Command>
    <Files></Files>
    <SuccessCodes>0,1,255</SuccessCodes>
    <RunAs value="null" />
    <Conditions type="list">
    <PackageStepCondition>
    <Architecture>Both</Architecture>
    <Version>All</Version>
    <TypeName>OperatingSystem</TypeName>
    </PackageStepCondition>
    <PackageStepCondition>
    <IsUserLoggedOn>AlwaysRun</IsUserLoggedOn>
    <TypeName>LoggedOnUser</TypeName>
    </PackageStepCondition>
    </Conditions>
    <ErrorMode>StopDeploymentFail</ErrorMode>
    <IsEnabled value="true" />
    <Title>Clean Windows Temp</Title>
    <TypeName>Command</TypeName>
    </CommandStep>
    <CommandStep>
    <Command>del /q /s %systemdrive%\temp\*
    for /d %%x in (%systemdrive%\temp\*) do @rd /s /q "%%x"</Command>
    <Files></Files>
    <SuccessCodes>0,1,255</SuccessCodes>
    <RunAs value="null" />
    <Conditions type="list">
    <PackageStepCondition>
    <Architecture>Both</Architecture>
    <Version>All</Version>
    <TypeName>OperatingSystem</TypeName>
    </PackageStepCondition>
    <PackageStepCondition>
    <IsUserLoggedOn>AlwaysRun</IsUserLoggedOn>
    <TypeName>LoggedOnUser</TypeName>
    </PackageStepCondition>
    </Conditions>
    <ErrorMode>StopDeploymentFail</ErrorMode>
    <IsEnabled value="true" />
    <Title>Clean C: Temp</Title>
    <TypeName>Command</TypeName>
    </CommandStep>
    <CommandStep>
    <Command>del /q /s %systemroot%\Logs\CBS\*
    for /d %%x in (%systemroot%\Logs\CBS\*) do @rd /s /q "%%x"</Command>
    <Files></Files>
    <SuccessCodes>0,1,255</SuccessCodes>
    <RunAs value="null" />
    <Conditions type="list">
    <PackageStepCondition>
    <Architecture>Both</Architecture>
    <Version>All</Version>
    <TypeName>OperatingSystem</TypeName>
    </PackageStepCondition>
    <PackageStepCondition>
    <IsUserLoggedOn>AlwaysRun</IsUserLoggedOn>
    <TypeName>LoggedOnUser</TypeName>
    </PackageStepCondition>
    </Conditions>
    <ErrorMode>StopDeploymentFail</ErrorMode>
    <IsEnabled value="true" />
    <Title>Clean Windows CBS Logs</Title>
    <TypeName>Command</TypeName>
    </CommandStep>
    </Steps>
    <Timeout value="60" />
    <UseCustomTimeout value="false" />
    </PackageDefinition>
    <Description>credit to:
    https://support.adminarsenal.com/hc/en-us/community/posts/213917368-Clean-Temp-Files
    https://community.spiceworks.com/scripts/show/3123-remotely-delete-temp-internet-files-temp-files-from-all-local-profiles-windows-2008-win7</Description>
    <FolderId value="null" />
    <Name>Clean Temp Files</Name>
    <Path>Clean Temp Files</Path>
    <Version></Version>
    <PackageDisplaySettings name="DisplaySettings">
    <DisplayType>Normal</DisplayType>
    <IconKey></IconKey>
    <SortOrder value="8" />
    </PackageDisplaySettings>
    </Package>
    </AdminArsenal.Export>

  • Very cool idea. I was looking for something like this. Any way for it to loop through all user profiles on the drive instead of just the currently logged in user?

  • I too would like this feature as a possibility. I have a use case right now where it would be helpful to run a script locally as a step on the PDQ server during automated Windows 10 Upgrades using MDT. Were PDQ able to run "out of band" from the actual deployment, I could monitor MDT progress using ODATA. Where my package fails today is that the powershell script runs on the target device and then MDT reboots it. So, PDQ thinks the package failed. I'm using manual sleep timers to get around this which is not full proof.

    I'm considering writing a powershell script that uses ps remoting into the PDQ server to kick off a job but then you lose some of the benefits of running deployments right from within PDQ (I.e. selecting my target devices).

  • Just came across this thread and am testing it out in our environment. This is much simpler than what I was trying to do using MDT. See https://github.com/OneWorldCHC/PDQDeploy-UpgradeWin10

    For those using this setup.exe method, I would encourage you to use OSBuilder from David Segura to automatically inject the latest SSU, LCU, and LSU into your install media. It'll save time for the patching process. https://www.osdeploy.com/osbuilder/overview

    Steve