Clear, practical technology insights BSOD Code Lookup · Windows Error Code Lookup · Wi-Fi Troubleshooting · PC Troubleshooting Checklist

Change User: The Command Changes User in Windows

Understand Change User: The Command Changes User in Windows with clear explanations, practical examples, and useful tips. This updated guide covers the...

Table of Contents

Change User: The Command Changes User in Windows is easier to understand when the core ideas are paired with practical examples. The sections below explain the topic clearly, highlight useful steps, and point out details that can prevent common errors.

  • Applies to: Windows Server (Semi-Annual Channel), Windows Server 2016, Windows Server 2012 R2, Windows Server 2012.

The change user command changes the installation mode for the Remote Desktop Session Host server (rd Session Host). To learn examples of how to use this command, please see the Example below.

Note:

In Windows Server 2008 R2, Terminal Services has been renamed to Remote Desktop Services.

Command syntax change user

 change user {/ execute | / install | / query} 

Parameters

Parameter Description / execute Enable mapping of.ini files in the main directory. This is the default setting. / install Disable mapping of.ini files in the home directory. All.ini files are read and written to the system directory. You must disable.ini file mapping when installing applications on rd Session Host server. / query Displays the current settings for the.ini file mapping. /? Show help at the command prompt.

Note

  • Use the change user / install command before installing the application to create an.ini file for that application in the system directory. These files are used as the source when the.ini file of a particular user is created. After installing the application, use the command change user / execute to revert to the standard.ini file mapping.
  • The first time you run the application, it will search the main directory for its.ini files. If the.ini file is not found in the main directory, but found in the system directory, Remote Desktop Services will copy the.ini file to the main directory, ensuring that each user has a unique copy. of.ini file. Any new.ini file is created in the main directory.
  • Each user must have a single copy of the.ini file for an application. This prevents situations where different users may have incompatible application configurations (For instance,, different default screens or folders).
  • When the system is in installation mode (ie change user / install ), some things will happen. All registry entries created are hidden under HKEY_LOCAL_MACHINESOFTWAREMicrosoftWindows NTCurrentversionTerminal ServerInstall , or in the subkey SOFTWARE or MACHINE. Subkeys added to HKEY_CURrenT_USER will be copied in the SOFTWARE subkey and the subkeys added to HKEY_LOCAL_MACHINE are copied in the subkey MACHINE. If the application queries the Windows directory using system calls, such as GetWindowsdirectory, the rd Session Host server will return the systemroot directory . If any.ini file entry is added using system calls, such as WritePrivateProfileString, they will be added to the.ini file in the systemroot folder.
  • When the system returns to executable mode (ie change user / execute ), and the application tries to read a registry entry that does not exist in HKEY_CURrenT_USER , Remote Desktop Services will check if the copy of the key exists in the subkey. Terminal ServerInstall or not. If so, the subkeys will be copied to the appropriate location in HKEY_CURrenT_USER. If the application tries to read from the.ini file does not exist, Remote Desktop Services will search that.ini file in the system root directory. If the.ini file is in the system root directory, the file will be copied to the Windows subdirectory in the user's home directory. If the application queries the Windows directory, the rd Session Host server will return the Windows subdirectory in the user's home directory.
  • When you log in, Remote Desktop Services will check if its system.ini files are newer than.ini files on your computer. If the system version is newer, your.ini file will be replaced or merged with the newer version. This depends on whether the INISYNC bit, 0x40, is set for this.ini file or not. The previous version of the.ini file was renamed Inifile.ctx. If the system registry values in the ServerInstall Terminal subkey are newer than your version in HKEY_CURrenT_USER, the version of your subkeys will be deleted and replaced with new subkeys from Terminal ServerInstall.

For instance,

  • Change port command in Windows
  • Change logon command in Windows
  • Change command in Windows

FAQ

What is Change User: The Command Changes User in Windows?

Applies to: Windows Server (Semi-Annual Channel), Windows Server 2016, Windows Server 2012 R2, Windows Server 2012.

Why is Change User: The Command Changes User in Windows important?

A clear understanding of Change User: The Command Changes User in Windows helps you make informed decisions, avoid common mistakes, and use the relevant tools or techniques more effectively.

How should beginners approach Change User: The Command Changes User in Windows?

Start with the fundamental concepts, follow the examples step by step, and test each change in a safe environment before applying it to important systems or data.

Discussion

Reader Comments 0

Sign in with email or Google to join the discussion.