in reply to [OT] Environment variable missing for scheduled task in Windows Server 2008

Hello Lotus1,

have you rebooted?

No seriously: see this:

> Changes that you make to environment variables do not affect services that run under the Local System account until you restart Windows

L*

PS I do not think the article is old: Last Updated: Apr 17, 2018 and given the problem I guess it affects ALL windows versions. The link about how to create system variables referes to win2000 but the underlying matter I suspect it's no changed a lot.

There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.

Replies are listed 'Best First'.
Re^2: [OT] Environment variable missing for scheduled task in Windows Server 2008
by Lotus1 (Vicar) on Jun 07, 2018 at 21:00 UTC

    I had considered that but since the other servers didn't do this I dismissed it. But now that you mention it, there are about 10 users logged into this one and not the others. Maybe something they are doing is preventing services.exe from getting the word. Maybe it is something different about 2008. The article you posted doesn't mention what Windows version it is referring to but it has a link to setting environment variables in Windows 2000 so it looks old. Still, it is a good find. It's pretty hard to find relevant articles with words like 'system' and 'server' and 'variable' in the search terms.

    I'll try rebooting in a few minutes after everyone logs out.

    Update: I rebooted and now the System account sees all the environment variables. Thanks.