Posts

Showing posts from August, 2023

How to add user into localgroup using Command Prompt

Type net localgroup groupname username /add, where username is the name of the existing user you want to add and groupname is the name of the group you want to add them to. For example, if the group name is Accounting and the username is Bill, you would type net localgroup Accounting Bill /add. Then press Enter  C:\windows\system32>net localgroup "Remote desktop users" username@domain.com /add System error 1378 has occurred. The specified account name is already a member of the group. C:\windows\system32>net localgroup "Remote desktop users" username@domain.com /del The command completed successfully. C:\windows\system32>net localgroup "Remote desktop users" username@domain.com /add The command completed successfully. C:\windows\system32>net localgroup "remote desktop users" Alias name     remote desktop users Comment        Members in this group are granted the right to logon remotely Members -----------------------------------------

Backup and restore of permission in windows using icacls

 Windows PowerShell Copyright (C) 2014 Microsoft Corporation. All rights reserved. PS C:\Users\Administrator> cd desktop PS C:\Users\Administrator\desktop> reg export HKLM\SYSTEM\CurrentControlSet\Services\LanmanServer\Shares shareperms.reg The operation completed successfully. PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> icacls c:\data /save ntfsperms.txt /t /c c:\Documents and Settings\*: Access is denied. PS C:\Users\Administrator\desktop> PS C:\Users\Administrator\desktop> icacls c:\test /save ntfsperms.txt /t /c processed file: c:\test processed file: c:\test\test2 processed file: c:\test\Test3 processe

MDT custom rule, MDT task sequence rule

 ------------------------------------------------------------------------- [Settings] Priority=Default Properties=MyCustomProperty [Default] ; OverrideProductKey=XXXXX-XXXXX-XXXXX-XXXXX-XXXXX ; Set Windows product key TaskSequenceID=EX01 ; Identifies the operating system task sequence to be deployed to the target computer DoCapture=NO ; Indicator of whether an image of the target computer is to be captured. OSInstall=Y ; Indicates whether the target computer is authorized to have the target operating system installed. SkipAdminPassword=YES ; Indicates whether the Administrator Password wizard page is skipped SkipApplications=YES ; Indicates whether the Select one or more applications to install wizard page is skipped. SkipBDDWelcome=YES ; Indicates whether the Welcome to Windows Deployment wizard page is skipped. SkipBitLocker=YES ; Indicates whether the Specify the BitLocker configuration wizard page is skipped. SkipCapture=YES ; Indicates whether the Specify whether to capture an ima