• Home
  • Linux
  • Docker
  • Windows
    • PS
    • C#
    • Exchange Server
  • Other
    • Perl
    • IPV6
    • MacOS
  • DB
    • MSSQL
    • MariaDB
    • PG

Home

Обход мастера приветствия Windows 11

Details
Written by: po3dno
Category: Windows
Created: 14 August 2024
Hits: 231

Если перед запуском обновления Inplace заданы следующие записи реестра, Windows 11 больше не отображает мастер приветствия для этого пользователя при первом входе в систему (записи относятся к HKCU, поэтому они связаны с пользователем). Вот обязательные записи:

%WINDIR%\System32\Reg.exe ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Privacy" /v "TailoredExperiencesWithDiagnosticDataEnabled" /t REG_DWORD /d 0 /f
%WINDIR%\System32\Reg.exe ADD  "HKCU\Software\Microsoft\Windows\CurrentVersion\Privacy" /v "PrivacyConsentPresentationVersion" /t REG_DWORD /d 3 /f
%WINDIR%\System32\Reg.exe ADD  "HKCU\Software\Microsoft\Windows\CurrentVersion\Privacy" /v "PrivacyConsentSettingsVersion" /t REG_DWORD /d 4 /f
%WINDIR%\System32\Reg.exe ADD  "HKCU\Software\Microsoft\Windows\CurrentVersion\Privacy" /v "PrivacyConsentSettingsValidMask" /t REG_DWORD /d 63 /f
 

необходимо ввести в соответствующую учетную запись пользователя в Windows 10 перед обновлением. Записи реестра можно установить с помощью пакетной программы. Маркус отметил, что в более крупных средах записи, безусловно, можно развертывать через GPO. Если все работает, Мастер приветствия больше не должен доставлять неудобства.

Search update

Details
Written by: po3dno
Category: Power Shell
Created: 03 July 2024
Hits: 273

(New-Object -ComObject Microsoft.Update.Session).CreateupdateSearcher().Search("IsHidden=0 and IsInstalled=0").Updates | Select-Object Title

 

Stop-Service -Name BITS, wuauserv -Force
Remove-ItemProperty -Name AccountDomainSid, PingID, SusClientId, SusClientIDValidation -Path HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\ -ErrorAction SilentlyContinue
Remove-Item "$env:SystemRoot\SoftwareDistribution\" -Recurse -Force -ErrorAction SilentlyContinue
Start-Service -Name BITS, wuauserv
wuauclt /resetauthorization /detectnow
(New-Object -ComObject Microsoft.Update.AutoUpdate).DetectNow()

rebuild BCD

Details
Written by: po3dno
Category: Other
Created: 12 April 2024
Hits: 398

diskpart (opens Disk Partitioning tool)
select disk 0
list volume (please note the number of the volume that has no drive letter assigned and has FAT32 listed in Fs column)
select volume <the number of ~500 MB FAT32 volume with no drive letter, or with label ESP>
assign letter=Z: (gives drive letter Z: to EFI System Partition)
exit (closes Disk Partitioning tool)
cd /d Z:\EFI\Microsoft\Boot\ (changes current folder in Command Prompt window)
attrib Z:\EFI\Microsoft\Boot\BCD -h -r -s (removes hidden, read-only and system attributes from BCD folder)
ren Z:\EFI\Microsoft\Boot\BCD BCD.old (renames BCD folder to BCD.old)
bootrec /rebuildbcd (retries the rebuild)

New-ISOFileFromFolder

Details
Written by: po3dno
Category: Power Shell
Created: 18 December 2023
Hits: 431

Function New-ISOFileFromFolder{
    <#
        .SYNOPSIS
        Creates an ISO file from a filepath
    #>
    param(
        [Parameter(Mandatory=$true)]
        [String]$FilePath,
        [Parameter(Mandatory=$true)]
        [String]$Name,
        [Parameter(Mandatory=$true)]
        [String]$ResultFullFileName
    )
    write-host "Creating ISO $Name" -ForegroundColor Green  

    $fsi = New-Object -ComObject IMAPI2FS.MsftFileSystemImage
    $dftd = New-Object -ComObject IMAPI2.MsftDiscFormat2Data
    $Recorder = New-Object -ComObject IMAPI2.MsftDiscRecorder2

    $fsi.FileSystemsToCreate = 7
    $fsi.VolumeName = $Name
    $fsi.FreeMediaBlocks = 1000000  #default 332800

    
    $fsi.Root.AddTreeWithNamedStreams($FilePath,$false)


    
    $resultimage = $fsi.CreateResultImage()
    $resultStream = $resultimage.ImageStream


    Write-IStreamToFile $resultStream $ResultFullFileName
    
}

Read more …

add list users with random password

Details
Written by: po3dno
Category: Power Shell
Created: 14 November 2023
Hits: 1469

function Get-RandomPassword {
    param (
        [Parameter(Mandatory)]
        [int] $length,
        [int] $amountOfNonAlphanumeric = 1
    )
    Add-Type -AssemblyName 'System.Web'
    return [System.Web.Security.Membership]::GeneratePassword($length, $amountOfNonAlphanumeric)
}

"user1

user2" -split "`n" | %{$user = $_; $pwdplain = $(Get-RandomPassword 8); New-ADUser -Name $user -AccountPassword $(ConvertTo-SecureString -String $pwdplain  -AsPlainText -Force) -Enabled $true; write-host $user $pwdplain}

  1. Change Default Location for Domain Joined Computers
  2. Get-SharesWithShareAndNTFSPermissions
  3. Reset-ComputerMachinePassword
  4. Сброс пароля компьютера в домене без перезагрузки

Subcategories

Power Shell Article Count:  53

C# Article Count:  10

Perl Article Count:  1

Exchange Server Article Count:  15

Other Article Count:  24

MSSQL Article Count:  17

Windows Article Count:  25

MariaDB Article Count:  3

Linux Article Count:  8

Docker Article Count:  2

pg Article Count:  2

Page 4 of 32

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10

Login Form

  • Forgot your password?
  • Forgot your username?

Statistics

  • Users 2
  • Articles 176
  • Articles View Hits 157832