1

I have tried to set core affinity of smss.exe to not run on one critical core on Windows 7 and Windows Server 2008r2. It turns out that simply setting the core affinity to anything (even the full mask that smss.exe already has) seems to work but prevents users from rdp'ing into the machine until it is restarted. The users already logged in may continue to use their sessions.

This behaviour does not occur on Windows 8/Windows Server 2012.

Does anyone know why it is happening?

Hetman
  • 11
  • 1

1 Answers1

3

Smss.exe (Session Manager) is absolutely integral in creating new user sessions, including Terminal Services sessions when people log on remotely.

When Smss starts, it checks whether it is the first instance (the master Smss) or an instance of itself that the master Smss launched to create a session.

According to Mark Russinovich's Windows Internals book, Smss.exe includes algorithms that make use of processor affinity in a special way:

"By creating multiple instances of itself during boot-up and Terminal Services session creation, Smss can create multiple sessions at the same time (at maximum, four concurrent sessions, plus one more for each extra CPU beyond one)."

And:

If the system supports hot processor add, enables automatic processor affinity updates so that if new processors are added new sessions will take advantage of the new processors.

Your tweaking of the process's affinity mask is likely interfering with those algorithms.

So in short, don't do that. Whatever you're trying to accomplish, you're very likely going about it in the wrong way.

Ryan Ries
  • 55,481
  • 10
  • 142
  • 199