Jump to content

Scheduled Tasks


Recommended Posts

Guest bsbm525
Posted

Hello,

 

I logged onto a Windows XP SP2 client using a 'Standard User' account & then

added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin' acct.

(NOTE: I am still logged on as a Standard User)

 

When the Disk Cleanup scheduled task starts, the disk cleanup popup doesn't

appear and when I view the scheduled task under the scheduled tasks folder in

Control Panel it's status states it's running but it just stays there and

nothing else happens.

 

Is there a resolution for this?

I am trying to avoid giving the user Admin permissions if possible to run

scheduled tasks.

 

Thanks....

  • Replies 10
  • Created
  • Last Reply

Popular Days

Guest Pegasus \(MVP\)
Posted

Re: Scheduled Tasks

 

 

"bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

> Hello,

>

> I logged onto a Windows XP SP2 client using a 'Standard User' account &

> then

> added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin' acct.

> (NOTE: I am still logged on as a Standard User)

>

> When the Disk Cleanup scheduled task starts, the disk cleanup popup

> doesn't

> appear and when I view the scheduled task under the scheduled tasks folder

> in

> Control Panel it's status states it's running but it just stays there and

> nothing else happens.

>

> Is there a resolution for this?

> I am trying to avoid giving the user Admin permissions if possible to run

> scheduled tasks.

>

> Thanks....

>

 

This is the expected behaviour: Scheduled tasks that run under an

account other than your own will run invisibly in the background.

If they require some user interaction then you must not run them

in this way.

Guest bsbm525
Posted

Re: Scheduled Tasks

 

Do you know a way around this without giving the user Admin rights?

3rd party app?

Thanks....

 

"Pegasus (MVP)" wrote:

>

> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

> news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

> > Hello,

> >

> > I logged onto a Windows XP SP2 client using a 'Standard User' account &

> > then

> > added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin' acct.

> > (NOTE: I am still logged on as a Standard User)

> >

> > When the Disk Cleanup scheduled task starts, the disk cleanup popup

> > doesn't

> > appear and when I view the scheduled task under the scheduled tasks folder

> > in

> > Control Panel it's status states it's running but it just stays there and

> > nothing else happens.

> >

> > Is there a resolution for this?

> > I am trying to avoid giving the user Admin permissions if possible to run

> > scheduled tasks.

> >

> > Thanks....

> >

>

> This is the expected behaviour: Scheduled tasks that run under an

> account other than your own will run invisibly in the background.

> If they require some user interaction then you must not run them

> in this way.

>

>

>

Guest Pegasus \(MVP\)
Posted

Re: Scheduled Tasks

 

You could invoke it in a batch file with the "runas" command,

but since this involves recording the admin's password in the

batch file, you would create a big security hole.

 

The question is, of course, why you would want to run Disk

Cleanup frequently. You will find that running it often will make

no measurable difference to the performance of your PC other

than giving you a warm feeling inside, so why bother?

 

 

"bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

news:9767AD3D-E504-4F85-A6AD-12025369EDE0@microsoft.com...

> Do you know a way around this without giving the user Admin rights?

> 3rd party app?

> Thanks....

>

> "Pegasus (MVP)" wrote:

>

>>

>> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

>> news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

>> > Hello,

>> >

>> > I logged onto a Windows XP SP2 client using a 'Standard User' account &

>> > then

>> > added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin'

>> > acct.

>> > (NOTE: I am still logged on as a Standard User)

>> >

>> > When the Disk Cleanup scheduled task starts, the disk cleanup popup

>> > doesn't

>> > appear and when I view the scheduled task under the scheduled tasks

>> > folder

>> > in

>> > Control Panel it's status states it's running but it just stays there

>> > and

>> > nothing else happens.

>> >

>> > Is there a resolution for this?

>> > I am trying to avoid giving the user Admin permissions if possible to

>> > run

>> > scheduled tasks.

>> >

>> > Thanks....

>> >

>>

>> This is the expected behaviour: Scheduled tasks that run under an

>> account other than your own will run invisibly in the background.

>> If they require some user interaction then you must not run them

>> in this way.

>>

>>

>>

Guest bsbm525
Posted

Re: Scheduled Tasks

 

Well I do find it when disk cleanup is run once a month it does help the

performance especially when removing temp & temp internet files for starters.

 

Thanks.

 

 

"Pegasus (MVP)" wrote:

> You could invoke it in a batch file with the "runas" command,

> but since this involves recording the admin's password in the

> batch file, you would create a big security hole.

>

> The question is, of course, why you would want to run Disk

> Cleanup frequently. You will find that running it often will make

> no measurable difference to the performance of your PC other

> than giving you a warm feeling inside, so why bother?

>

>

> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

> news:9767AD3D-E504-4F85-A6AD-12025369EDE0@microsoft.com...

> > Do you know a way around this without giving the user Admin rights?

> > 3rd party app?

> > Thanks....

> >

> > "Pegasus (MVP)" wrote:

> >

> >>

> >> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

> >> news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

> >> > Hello,

> >> >

> >> > I logged onto a Windows XP SP2 client using a 'Standard User' account &

> >> > then

> >> > added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin'

> >> > acct.

> >> > (NOTE: I am still logged on as a Standard User)

> >> >

> >> > When the Disk Cleanup scheduled task starts, the disk cleanup popup

> >> > doesn't

> >> > appear and when I view the scheduled task under the scheduled tasks

> >> > folder

> >> > in

> >> > Control Panel it's status states it's running but it just stays there

> >> > and

> >> > nothing else happens.

> >> >

> >> > Is there a resolution for this?

> >> > I am trying to avoid giving the user Admin permissions if possible to

> >> > run

> >> > scheduled tasks.

> >> >

> >> > Thanks....

> >> >

> >>

> >> This is the expected behaviour: Scheduled tasks that run under an

> >> account other than your own will run invisibly in the background.

> >> If they require some user interaction then you must not run them

> >> in this way.

> >>

> >>

> >>

>

>

>

Guest VanguardLH
Posted

Re: Scheduled Tasks

 

"bsbm525" wrote in message

news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

>

> I logged onto a Windows XP SP2 client using a 'Standard User'

> account & then

> added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin'

> acct.

> (NOTE: I am still logged on as a Standard User)

>

> When the Disk Cleanup scheduled task starts, the disk cleanup popup

> doesn't

> appear and when I view the scheduled task under the scheduled tasks

> folder in

> Control Panel it's status states it's running but it just stays

> there and

> nothing else happens.

>

> Is there a resolution for this?

> I am trying to avoid giving the user Admin permissions if possible

> to run

> scheduled tasks.

 

 

When using RunAs to execute a program under a different account,

remember that you are NOT logged in under that account when the

scheduled job runs. You are running in under the OTHER account, not

yours, so where would its window be displayed? The other account is

not logged in so there is no desktop atop of which would appear the

program's window.

 

If they are admin-level jobs, why does a non-admin need to see

anything? It's not like they can do anything about it because

presumably you did not give the password to the user when the RunAs

option was enabled when defining the job.

 

Why does a disk cleanup job need to run under an admin-level account?

Why would you have a user account doing cleanup on other accounts to

which that user would not normally have permissions? Disk cleanup

should be a per-user task. If the users of the other accounts don't

log in for really long intervals, what would there be to cleanup that

the last cleanup didn't handle when they were logged in or were

scheduled to run under THEIR account at the scheduled time even when

they were not logged in?

Guest bsbm525
Posted

Re: Scheduled Tasks

 

For Disk Cleanup the user has to select which type of files to delete when

the selection screen popup appears to select files such as 'temp files', etc

after the initial scan. If it wasn't for that, then of course the task can

be run automatically with no user interaction.

 

These clients only has one main user not multiple and I am just trying to

figure out a way to run maintenance utilities automatically as scheduled

tasks without giving users local admin rights.

 

 

 

"VanguardLH" wrote:

> "bsbm525" wrote in message

> news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

> >

> > I logged onto a Windows XP SP2 client using a 'Standard User'

> > account & then

> > added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin'

> > acct.

> > (NOTE: I am still logged on as a Standard User)

> >

> > When the Disk Cleanup scheduled task starts, the disk cleanup popup

> > doesn't

> > appear and when I view the scheduled task under the scheduled tasks

> > folder in

> > Control Panel it's status states it's running but it just stays

> > there and

> > nothing else happens.

> >

> > Is there a resolution for this?

> > I am trying to avoid giving the user Admin permissions if possible

> > to run

> > scheduled tasks.

>

>

> When using RunAs to execute a program under a different account,

> remember that you are NOT logged in under that account when the

> scheduled job runs. You are running in under the OTHER account, not

> yours, so where would its window be displayed? The other account is

> not logged in so there is no desktop atop of which would appear the

> program's window.

>

> If they are admin-level jobs, why does a non-admin need to see

> anything? It's not like they can do anything about it because

> presumably you did not give the password to the user when the RunAs

> option was enabled when defining the job.

>

> Why does a disk cleanup job need to run under an admin-level account?

> Why would you have a user account doing cleanup on other accounts to

> which that user would not normally have permissions? Disk cleanup

> should be a per-user task. If the users of the other accounts don't

> log in for really long intervals, what would there be to cleanup that

> the last cleanup didn't handle when they were logged in or were

> scheduled to run under THEIR account at the scheduled time even when

> they were not logged in?

>

>

Guest CurtB
Posted

Re: Scheduled Tasks

 

You can remove Temporary Internet Files automatically.

 

Internet Explorer > Tools > Intenet Options > Advanced tab > In the Security

section, check the box for "Empty Temporary Internet Files folder when

browser is closed"

 

"bsbm525" wrote:

> Well I do find it when disk cleanup is run once a month it does help the

> performance especially when removing temp & temp internet files for starters.

>

> Thanks.

>

>

> "Pegasus (MVP)" wrote:

>

> > You could invoke it in a batch file with the "runas" command,

> > but since this involves recording the admin's password in the

> > batch file, you would create a big security hole.

> >

> > The question is, of course, why you would want to run Disk

> > Cleanup frequently. You will find that running it often will make

> > no measurable difference to the performance of your PC other

> > than giving you a warm feeling inside, so why bother?

> >

> >

> > "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

> > news:9767AD3D-E504-4F85-A6AD-12025369EDE0@microsoft.com...

> > > Do you know a way around this without giving the user Admin rights?

> > > 3rd party app?

> > > Thanks....

> > >

> > > "Pegasus (MVP)" wrote:

> > >

> > >>

> > >> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

> > >> news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

> > >> > Hello,

> > >> >

> > >> > I logged onto a Windows XP SP2 client using a 'Standard User' account &

> > >> > then

> > >> > added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin'

> > >> > acct.

> > >> > (NOTE: I am still logged on as a Standard User)

> > >> >

> > >> > When the Disk Cleanup scheduled task starts, the disk cleanup popup

> > >> > doesn't

> > >> > appear and when I view the scheduled task under the scheduled tasks

> > >> > folder

> > >> > in

> > >> > Control Panel it's status states it's running but it just stays there

> > >> > and

> > >> > nothing else happens.

> > >> >

> > >> > Is there a resolution for this?

> > >> > I am trying to avoid giving the user Admin permissions if possible to

> > >> > run

> > >> > scheduled tasks.

> > >> >

> > >> > Thanks....

> > >> >

> > >>

> > >> This is the expected behaviour: Scheduled tasks that run under an

> > >> account other than your own will run invisibly in the background.

> > >> If they require some user interaction then you must not run them

> > >> in this way.

> > >>

> > >>

> > >>

> >

> >

> >

Guest Terry R.
Posted

Re: Scheduled Tasks

 

The date and time was 3/4/2008 12:46 PM, and on a whim, bsbm525 pounded

out on the keyboard:

> Well I do find it when disk cleanup is run once a month it does help the

> performance especially when removing temp & temp internet files for starters.

>

> Thanks.

>

>

> "Pegasus (MVP)" wrote:

>

>> You could invoke it in a batch file with the "runas" command,

>> but since this involves recording the admin's password in the

>> batch file, you would create a big security hole.

>>

>> The question is, of course, why you would want to run Disk

>> Cleanup frequently. You will find that running it often will make

>> no measurable difference to the performance of your PC other

>> than giving you a warm feeling inside, so why bother?

>>

>>

>> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

>> news:9767AD3D-E504-4F85-A6AD-12025369EDE0@microsoft.com...

>>> Do you know a way around this without giving the user Admin rights?

>>> 3rd party app?

>>> Thanks....

>>>

>>> "Pegasus (MVP)" wrote:

>>>

>>>> "bsbm525" <bsbm525@discussions.microsoft.com> wrote in message

>>>> news:BF129293-D29A-4F47-8A48-B24D35AEF545@microsoft.com...

>>>>> Hello,

>>>>>

>>>>> I logged onto a Windows XP SP2 client using a 'Standard User' account &

>>>>> then

>>>>> added 'Disk Cleanup' as a 'scheduled task' using a different 'Admin'

>>>>> acct.

>>>>> (NOTE: I am still logged on as a Standard User)

>>>>>

>>>>> When the Disk Cleanup scheduled task starts, the disk cleanup popup

>>>>> doesn't

>>>>> appear and when I view the scheduled task under the scheduled tasks

>>>>> folder

>>>>> in

>>>>> Control Panel it's status states it's running but it just stays there

>>>>> and

>>>>> nothing else happens.

>>>>>

>>>>> Is there a resolution for this?

>>>>> I am trying to avoid giving the user Admin permissions if possible to

>>>>> run

>>>>> scheduled tasks.

>>>>>

>>>>> Thanks....

>>>>>

>>>> This is the expected behaviour: Scheduled tasks that run under an

>>>> account other than your own will run invisibly in the background.

>>>> If they require some user interaction then you must not run them

>>>> in this way.

>>>>

>>>>

>>>>

>>

>>

 

I put a batch file to clean temp folders on login into the All Users

startup folder, using the variable %TEMP% or %TMP% (may need both if the

path is different, but usually they're the same).

 

--

Terry R.

 

***Reply Note***

Anti-spam measures are included in my email address.

Delete NOSPAM from the email address after clicking Reply.

Guest VanguardLH
Posted

Re: Scheduled Tasks

 

"bsbm525" wrote in message

news:68E29501-1EA6-4A73-88CB-7C2758163EF7@microsoft.com...

> For Disk Cleanup the user has to select which type of files to

> delete when

> the selection screen popup appears to select files such as 'temp

> files', etc

> after the initial scan. If it wasn't for that, then of course the

> task can

> be run automatically with no user interaction.

>

> These clients only has one main user not multiple and I am just

> trying to

> figure out a way to run maintenance utilities automatically as

> scheduled

> tasks without giving users local admin rights.

 

 

The disk cleanup wizard can be automated without ANY user prompts.

Read Microsoft's KB article 315246. With policies, I assume you could

push the registry keys to have all users do the same set of cleanup

actions. Or you could use account logon scripts (to UNC pathed

network hosts) to retrieve a .reg file and run regedit in silent mode

(regedit.exe /s <regfile>) to get them into the user's copy of the

registry's .dat files. I don't know how you are pushing the .job file

for the scheduled task onto the user's hosts but that is probably also

possible.

 

As an end user of my own host with admin rights, I have a scheduled

task that runs the disk cleanup each week and I NEVER have to answer

any prompts. The scheduled task runs

"C:\WINDOWS\system32\cleanmgr.exe /sagerun:0" where I have previously

created the zero-named config set (use whatever config set number that

floats your boat).

Guest bsbm525
Posted

Re: Scheduled Tasks

 

thanks

 

"VanguardLH" wrote:

> "bsbm525" wrote in message

> news:68E29501-1EA6-4A73-88CB-7C2758163EF7@microsoft.com...

> > For Disk Cleanup the user has to select which type of files to

> > delete when

> > the selection screen popup appears to select files such as 'temp

> > files', etc

> > after the initial scan. If it wasn't for that, then of course the

> > task can

> > be run automatically with no user interaction.

> >

> > These clients only has one main user not multiple and I am just

> > trying to

> > figure out a way to run maintenance utilities automatically as

> > scheduled

> > tasks without giving users local admin rights.

>

>

> The disk cleanup wizard can be automated without ANY user prompts.

> Read Microsoft's KB article 315246. With policies, I assume you could

> push the registry keys to have all users do the same set of cleanup

> actions. Or you could use account logon scripts (to UNC pathed

> network hosts) to retrieve a .reg file and run regedit in silent mode

> (regedit.exe /s <regfile>) to get them into the user's copy of the

> registry's .dat files. I don't know how you are pushing the .job file

> for the scheduled task onto the user's hosts but that is probably also

> possible.

>

> As an end user of my own host with admin rights, I have a scheduled

> task that runs the disk cleanup each week and I NEVER have to answer

> any prompts. The scheduled task runs

> "C:\WINDOWS\system32\cleanmgr.exe /sagerun:0" where I have previously

> created the zero-named config set (use whatever config set number that

> floats your boat).

>

>


×
×
  • Create New...