воскресенье, 8 декабря 2019 г.

Find authenticating Domain Controller for your computer

Here's how you can find out which domain controller your computer is getting authenticated with:

gpresult /r

SET L

echo %logonserver%

nltest /dsgetdc:

gpresult /r /scope:computer

=VB Script= Set objDomain = GetObject("LDAP://rootDSE") strDC = objDomain.Get("dnsHostName") Wscript.Echo "Authenticating domain controller: " & strDC

Which DCs are there in the domain?

NETDOM QUERY PDC
NETDOM QUERY DC (Lists all DC’s in domain)
NETDOM QUERY FSMO


четверг, 5 декабря 2019 г.

RPC/WMI Troubleshooting

Reasons for RPC and WMI errors

1. File and printer sharing disabled
2. Network connectivity issues
3. Name resolution issues. Always check that your problem is not on a cluster using several IP addresses.
4. Firewall blocking.
5. Registry corruption

Two best iT administrator friends

Hyena - very convenient tool for managing Active Directory and not TOO expensive too.

BatchPatch - very usable and well created tool for actively managing WSUS and for a bunch of other uses with or without Active Directory.

Hyena + BatchPatch + Excel = Super-tool for nearly every need. If you have used PowerShell for your administrative needs it is very possible that you may forget about using it... for about 90%.

GPO Power Options

Configuring Power Options Using Domain Policies

Policies


Computer Configuration -> Administrative Templates -> System -> Power Management
[edit_power_plan_policy[4].png]

Preferences

Using group policies to manage the power profiles on Windows systems is a feature that has been missing and desired for many years. Starting with Windows Server 2008 R2, Windows Vista and Windows 7 power plans can be defined and applied using domain policies using computer preference settings. To configure a centrally managed power plan for Windows Vista and later operating systems, perform the following steps:
  1. Log on to a designated Windows Server 2008 R2 administrative server.
  2. Click Start, click All Programs, click Administrative Tools, and select Group Policy Management.
  3. Add the necessary domains to the GPMC as required.
  4. Expand the Domains node to reveal the Group Policy Objects container.
  5. Create a new GPO called PowerProfileGPO and open it for editing.
  6. After the PowerProfileGPO is opened for editing in the Group Policy Management Editor, expand the Computer Configuration node and expand the Preferences node.
  7. Expand the Control Panel Settings, right-click the Power Options node, and select New - Power Plan (Windows Vista and Later).
  8. On the Advanced Settings page, change the default action to Update, change the default power plan from Balanced to High Performance, check checkbox Set as the Active Power Plan, and click OK to complete the settings. If desired, change any of the default settings to other values.
  9. Close the Group Policy Management Editor and link the policy in the Group Policy Management Console to a test organizational unit.
  10. Once the new policy passes validation testing, link it to a production organizational unit as desired.




NetApp Volume - Fixed Filesystem Size error




NETAPP VOLUME HAS THE FIXED FILESYSTEM SIZE OPTION SET


The following error is reported when trying to alter the size of a destination flex vol that is in a SnapMirror relation, or that was in a SnapMirror relation.
I most often run into this on volumes that were migrated off older hardware and no longer in a SnapMirror relation, but the fs_size_fixed option is not automatically changed after relationship is broken.
FS_SIZE_FIXED
This option causes the file system to remain the same size and not grow or shrink when a SnapMirrored volume relationship is broken, or when a volume add is performed on it. It is automatically set to true when a volume becomes a SnapMirrored volume. It stays set to true after the snapmirror break command is issued for the volume. This allows a volume to be SnapMirrored back to the source without needing to add disks to the source volume. If the volume is a traditional volume and the size is larger than the file system size, setting this option to false forces the file system to grow to the size of the volume. If the volume is a flexible volume and the volume size is larger than the file system size, setting this option to false forces the volume size to equal the file system size.
TO CHANGE THE OPTION IN DATA ONTAP 7-MODE:
vol options volumename fs_size_fixed off  
TO CHANGE THE OPTION IN CLUSTERED DATA ONTAP:
volume modify -filesys-size-fixed false -volume volumename  
TO CHANGE THE OPTION USING DATA ONTAP POWERSHELL TOOLKIT, 7-MODE:
Get-NaVol volumename | Set-NaVolOption -key fs_size_fixed -value off  
TO CHANGE THE OPTION USING DATA ONTAP POWERSHELL TOOLKIT, CLUSTERED DATA ONTAP:
Get-NcVol volumename | Set-NcVolOption -key fs_size_fixed -value off