Manage Learn to apply best practices and optimize your operations.

Top Windows command-line commands

3/6

Query group policy settings with gpresult /R

Source:  iStock/RUSSELLTATEdotCOM
Visual Editor: Sarah Evans/TechTarget

With gpresult /R you can see when the most recent changes to the Active Directory-based Group Policy settings took place on a computer and evaluate the current configuration.

The policies determine a computer's system, security and user settings, including what the users can do on their computers, such as which files they can access and which apps they can use. If the computer is remote, then you should use gpresult /S computername /U username /P password /R.

If you change Group Policy settings through the domain controller it can take 20-90 minutes for it to refresh and for the alterations to take hold. Sometimes you can't afford to wait that long because the user needs changes immediately. To make the updates go through faster, you can use gpupdate /force. The gpupdate command is the replacement for the former /refreshpolicy command.

Another similar command -- gpresult /H filename.html -- displays the Group Policy settings in HTML code.

View All Photo Stories
Virtual Desktop
SearchWindowsServer
Close