Jump to content

issue with cleanmgr (disk cleanup manager)


pat

Recommended Posts

Hi,

I am trying to automate the run of disk clean-up tool (cleanmgr) on my managed computers. I have created a script that prepares the "sageset" on computers and that seems to be working OK. The problem I am running into is that when I remotely launch the script/1-liner that executes the cleanmgr to effectively run the created sageset, it just hangs while using a certain percentage of CPU. Do you have any idea what I'm doing wrong?

prepare.sageset.ps1: this prepares the "sageset" in registry. I'm using sageset 0x0100.

run.cleanup.ps1: this starts the "sagerun". It works just fine when executed manually from powershell but I'm running into the above-descripted problem when run via pulseway.

 

Hope you can give me some directions. Thanks.

prepare.sageset.ps1

run.cleanup.ps1

Link to comment
Share on other sites

  • Administrators

Hi,

Does the cleanmgr process start when you're invoking the script from the Pulseway automation? Please note that when you're running the script it will run under the LOCALSYSTEM account, if you want it to run under the local user account you have to setup the powershell impersonation from the Pulseway Manager -> Settings -> Runtime.

-Paul

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...