„Windows 10 rendszergazdai alapbeállításai” változatai közötti eltérés
aNincs szerkesztési összefoglaló |
|||
(32 közbenső módosítás ugyanattól a felhasználótól nincs mutatva) | |||
1. sor: | 1. sor: | ||
'''Transclusion teszt, ne vedd komolyan!''' | |||
==Windows 10 v1903== | |||
<onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin| | <onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin| | ||
* Rendszergazdai rész | * Rendszergazdai rész | ||
6. sor: | 8. sor: | ||
* Felhasználói rész | * Felhasználói rész | ||
}}</onlyinclude> | }}</onlyinclude> | ||
<onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin|<br clear="all"> | |||
===Alapbeállítások a Vezérlőpulton=== | |||
A v1703 óta a Start menü, jobbklikk listaelemei közül száműzték a Vezérlőpultot és elemeit(!), ezért ''opcionálisan'' célszerű lehet azt a rendszergazda profilban a Keresés, Vez(érlőpult) paranccsal (vagy a Start menü, Windows Rendszer alól) történt elindítása után, a tálcára rögzíteni. | |||
<pre> | |||
<# PowerShell: TODO! - seems to be simple, but isn't: | |||
https://github.com/Disassembler0/Win10-Initial-Setup-Script/issues/147 #></pre> | |||
}}</onlyinclude> | |||
<onlyinclude>{{#ifeq: {{{transcludesection|user}}}|user| | |||
* Vezérlőpult, Kis ikonok. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Control Panel, Classic View | |||
https://gist.github.com/alirobe/7f3b34ad89a159e6daa1 | |||
#> | |||
$registryPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "StartupPage" -Value 1 -PropertyType "DWord" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "AllItemsIconView" -Value 1 -PropertyType "DWord" -Force | Out-Null</pre></div></div> | |||
* Vezérlőpult, Fájlkezelő beállításai, Nézet fül, Megosztás varázsló KI, Az operációs rendszer védett fájljainak elrejtése maradjon BE (pl. a ''desktop.ini''-k miatt), Ismert fájltípusok kiterjesztésinek elrejtése KI (soha nem fogják megtanulni...), Rejtett fájlok, mappák és meghajtók megjelenítése (BE), Üres meghajtók elrejtése (KI). | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Explorer tweaks - disable sharing wizard, show extensions, hidden files, empty drives | |||
https://superuser.com/questions/898495/disable-sharing-wizard-with-batch | |||
https://stackoverflow.com/questions/4491999/configure-windows-explorer-folder-options-through-powershell/28016877 | |||
#> | |||
$registryPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "SharingWizardOn" -Value 0 -PropertyType "DWord" -Force | Out-Null;` | |||
New-ItemProperty -Path $registryPath -Name "HideFileExt" -Value 0 -PropertyType "DWord" -Force | Out-Null;` | |||
New-ItemProperty -Path $registryPath -Name "Hidden" -Value 1 -PropertyType "DWord" -Force | Out-Null;` | |||
New-ItemProperty -Path $registryPath -Name "HideDrivesWithNoMedia" -Value 0 -PropertyType "DWord" -Force | Out-Null</pre> | |||
</div></div> | |||
}}</onlyinclude> | |||
<onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin| | |||
* Vezérlőpult, Rendszer, Távoli beállítások, Távsegítség KI. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Disable remote assistance | |||
https://superuser.com/questions/786383/how-to-enable-remote-assistance-and-add-an-exception-for-it-in-windows-firewall | |||
#> | |||
$registryPath = "HKLM:\System\CurrentControlSet\Control\Remote Assistance"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "fAllowToGetHelp" -Value 0 -PropertyType "DWord" -Force | Out-Null</pre></div></div> | |||
* Vezérlőpult, Rendszer, Rendszervédelem, Beállítás, bekapcsolás és ésszerű mennyiségű tárterület (3-5 GB) megadása. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Set and enable shadow storage (computer restore) on Windows drive | |||
https://www.tenforums.com/tutorials/33460-change-system-protection-max-storage-size-drive-windows-10-a.html | |||
https://docs.microsoft.com/hu-hu/powershell/module/Microsoft.PowerShell.Management/Enable-ComputerRestore?view=powershell-5.1 | |||
#> | |||
vssadmin Resize ShadowStorage /for=$env:SystemDrive /on=$env:SystemDrive /maxsize=3GB | Out-Null;` | |||
Enable-ComputerRestore -Drive $env:SystemDrive | Out-Null</pre> | |||
</div></div> | |||
* Vezérlőpult, Rendszer, Speciális beállítások, Indítás és helyreállítás, Automatikus újraindítás KI (hogy látsszon a kék halál). | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Disable automatic reboot on BSOD | |||
https://social.technet.microsoft.com/Forums/windowsserver/en-US/7badba7b-3157-443e-a3bf-7e6067bbdc25/disabling-bsod-automatic-restart-via-gpo?forum=winserverGP | |||
#> | |||
$registryPath = "HKLM:\System\CurrentControlSet\Control\CrashControl"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "AutoReboot" -Value 0 -PropertyType "DWord" -Force | Out-Null</pre> | |||
</div></div> | |||
* Vezérlőpult, Rendszer, Számítógépnév, töltsük ki a helyi szokásoknak megfelelően, munkacsoport-váltás esetén az újraindítást halasszuk el. | |||
<pre><# PowerShell: TODO! #></pre> | |||
* Vezérlőpult, Dátum és idő, Internetes idő, kiszolgáló Magyarországon ''time.kfki.hu'', ha van IP kapcsolat, akkor azonnali frissítés. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Change the BIOS timezone to UTC and set a new Internet time server; | |||
start synchronization service whenever any network interface comes up | |||
https://social.technet.microsoft.com/Forums/en-US/636865b1-9211-48ca-9430-58f7a4b890ba/update-internet-time-using-batch-script-or-powershell?forum=winserversetup | |||
https://gist.github.com/alirobe/7f3b34ad89a159e6daa1 | |||
#> | |||
$TimeServer = "time.kfki.hu";` | |||
Stop-Service -Name "w32time";` | |||
$registryPath = "HKLM:\SYSTEM\CurrentControlSet\Control\TimeZoneInformation"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -path $registryPath -Name "RealTimeIsUniversal" -Value 1 -PropertyType "DWord" -Force | Out-Null; ` | |||
$registryPath = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\DateTime\Servers"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "0" -Value $TimeServer -PropertyType "String" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "(Default)" -Value "0" -PropertyType "String" -Force | Out-Null; ` | |||
sc.exe triggerinfo w32time start/networkon stop/networkoff | Out-Null; ` | |||
Start-Service -Name "w32time" | Out-Null; ` | |||
w32tm /config /manualpeerlist:$TimeServer,0x9 /update | Out-Null; ` | |||
w32tm /resync /force | Out-Null</pre> | |||
<blockquote>''Megjegyzés:'' a fenti kód azt is beállítja, hogy a BIOS-ban tárolt időt ne a helyi időzóna idejének (az MS-DOS alapértelmezése), hanem UTC időnek tekintsük (a Un*x rendszerek - így a Linux, MacOSX, stb. - alapértelmezése). A beállítás multiboot munkaállomások esetén hasznos, monoboot Windows 10 esetén irreleváns. Maga a BIOS idő itt nem módosul (a Windowsnak nincsen ''hwclock'' jellegű eszköze - '''TODO!'''), így azt érdemes ellenőrizni, ha kell, manuálisan beállítani. A kód beállítja továbbá az időszinkron szolgáltatás elindítását a hálózatra kapcsolódáskor (a tényleges szinkronizálásról azonban alább, külön kell gondoskodni). Fentiek beállítására jelenleg nincs felhasználói felület.</blockquote> | |||
</div></div> | |||
* Vezérlőpult, Energiagazdálkodási lehetőségek, Alvó állapotba lépés idejének módosítása, asztali munkaállomás esetén a használt (általában a kiegyensúlyozott) sémában sose menjen alvó állapotba (ez megakadályozná az esetleges távoli bejelentkezést); opcionálisan a képernyő kikapcsolása is letiltható vagy hosszabbra állítható. Hordozható gép esetén ugyanezt csak az ''Áramforráshoz csatlakoztatva'' állapotra állítsuk be. Notebook esetén vizsgáljuk felül a főkapcsolók funkcióját is (''opcionálisan'' de javasoltan a főkapcsoló megnyomására ''Alvás'' helyett ''Leállítás''). | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Power settings (current power scheme - the balanced - only) | |||
https://stackoverflow.com/questions/33790965/set-a-one-line-powershell-for-sleep-and-hibernate-to-turn-off | |||
#> | |||
powercfg /CHANGE monitor-timeout-ac 10;` | |||
powercfg /CHANGE monitor-timeout-dc 5;` | |||
powercfg /CHANGE standby-timeout-ac 0;` | |||
powercfg /CHANGE standby-timeout-dc 15;` | |||
powercfg /CHANGE disk-timeout-ac 0;` | |||
powercfg /CHANGE disk-timeout-dc 15;` | |||
powercfg /CHANGE hibernate-timeout-ac 0;` | |||
powercfg /CHANGE hibernate-timeout-dc 0;` | |||
powercfg /SETACVALUEINDEX SCHEME_CURRENT sub_buttons pbuttonaction 3;` | |||
powercfg /SETDCVALUEINDEX SCHEME_CURRENT sub_buttons pbuttonaction 3</pre> | |||
</div></div> | |||
}}</onlyinclude> | |||
<onlyinclude>{{#switch: {{{transcludesection|user}}}|admin|user= | |||
* Vezérlőpult, Hang, Hangok fül, Nincsenek hangok hangséma betöltése}}</onlyinclude><onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin|, Rendszerindítási hangjelzés lejátszása ''opcionálisan'' BE.}}</onlyinclude><onlyinclude>{{#switch: {{{transcludesection|user}}}|admin|user=<br clear="all"> | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# No event sounds except the startup sound | |||
https://www.tenforums.com/tutorials/5838-change-event-sounds-sound-scheme-windows-10-a.html | |||
https://superuser.com/questions/1300539/change-sound-scheme-in-windows-via-register | |||
https://www.sevenforums.com/tutorials/179448-startup-sound-enable-disable.html | |||
#> | |||
$registryPath = "HKCU:\AppEvents\Schemes\Apps"; ` | |||
Get-ChildItem -Path $registryPath | Select Name | ForEach-Object { ` | |||
$app = $_.Name -replace "HKEY_CURRENT_USER", "HKCU:"; ` | |||
Get-ChildItem -Path $app | Select Name | ForEach-Object { ` | |||
$event = $_.Name -replace "HKEY_CURRENT_USER", "HKCU:"; ` | |||
$eventnone = "$event\.None"; $eventcurrent = "$event\.Current"; ` | |||
IF(!(Test-Path $eventnone)) { ` | |||
New-Item -Path $eventnone -Force | Out-Null; ` | |||
New-ItemProperty -Path $eventnone -Name '(Default)' -Type 'ExpandString' -Value '' | Out-Null }; ` | |||
New-ItemProperty -Path $eventcurrent -Name '(Default)' -Type 'String' -Value '' | Out-Null }}; ` | |||
$registryPath = "HKCU:\AppEvents\Schemes"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "(Default)" -Value ".None" -PropertyType "String" -Force | Out-Null;` | |||
</pre>}}</onlyinclude> | |||
<onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin| | |||
<pre>$registryPath = "HKLM:\Software\Microsoft\Windows\CurrentVersion\Authentication\LogonUI\BootAnimation"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "DisableStartupSound" -Value 0 -PropertyType "DWord" -Force | Out-Null | |||
</pre>}}</onlyinclude>{{#switch: {{{transcludesection|user}}}|admin|user=<br clear="all"> | |||
</div></div> | |||
}}</onlyinclude> | |||
<onlyinclude>{{#ifeq: {{{transcludesection|admin}}}|admin|<br clear="all"> | |||
===Egyéb alapbeállítások=== | |||
* Minden hálózatra kapcsolódáskor legyen időszinkron - Ez a gép, Kezelés, Feladatütemező, Művelet, Feladat létrehozása; Általános fülön Név ''Initial Time Synchronization'', Felhasználói fiók ''SYSTEM'', Futtatás akkor is, ha nincs bejelentkezve; Indítás fülön Új, Feladat megkezdése Eseménynél, Napló ''Microsoft-Windows-NetworkProfile/Műveletek'', Forrás ''NetworkProfile'', Eseményazonosító ''10000'', OK; Műveletek fülön Új, Program/parancsfájl ''w32tm'', Argumentumok ''/resync'', OK; Feltételek fülön Feladat indítása csak akkor, ha a számítógép hálózati áramról működik KI; OK. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Set a schedule to make a time synchronisation whenever any network interface comes up | |||
https://secopsmonkey.com/windows-time-synchonization-the-battle-continues.html | |||
https://www.petri.com/import-scheduled-tasks-powershell | |||
#> | |||
IF(!(Get-ScheduledTask | Where TaskName -EQ "Initial Time Synchronization")){Register-ScheduledTask -Xml @' | |||
<Task xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task" version="1.2"> | |||
<Triggers> | |||
<EventTrigger> | |||
<Subscription> | |||
&lt;QueryList&gt;&lt;Query&gt;&lt;Select Path='Microsoft-Windows-NetworkProfile/Operational'&gt; | |||
*[System[Provider[@Name='Microsoft-Windows-NetworkProfile'] and (EventID=10000)]]&lt;/Select&gt;&lt;/Query&gt;&lt;/QueryList&gt; | |||
</Subscription> | |||
</EventTrigger> | |||
</Triggers> | |||
<Settings> | |||
<DisallowStartIfOnBatteries>false</DisallowStartIfOnBatteries> | |||
<StopIfGoingOnBatteries>false</StopIfGoingOnBatteries> | |||
</Settings> | |||
<Actions Context="Author"> | |||
<Exec> | |||
<Command>w32tm</Command> | |||
<Arguments>/resync</Arguments> | |||
</Exec> | |||
</Actions> | |||
<Principals> | |||
<Principal id="Author"> | |||
<UserId>S-1-5-18</UserId> | |||
</Principal> | |||
</Principals> | |||
</Task> | |||
'@ -TaskName "Initial Time Synchronization" | Out-Null}</pre> | |||
<blockquote>''Megjegyzés:'' a fenti kódban azért használtam XML-t, mert az ''schtasks'' nem tudja kikapcsolni a futtatás tiltását akkumulátoros üzemmódban, viszont a PowerShell ''New-ScheduledTaskTrigger'' nem ismeri az event triggert ('''TODO!''').</blockquote> | |||
</div></div> | |||
* Ez a gép, a rendszerlemezen (amely általában a ''C:'') jobbklikk, Átnevezés, az új név legyen ''WINDOWS''. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre>IF (!(Get-Volume -DriveLetter ($env:SYSTEMDRIVE) -ErrorAction SilentlyContinue | ` | |||
Select-Object -ExpandProperty FileSystemLabel)) { | |||
Set-Volume -DriveLetter (Get-Volume -DriveLetter ($env:SYSTEMDRIVE) -ErrorAction SilentlyContinue | ` | |||
Select-Object -ExpandProperty DriveLetter) ` | |||
-NewFileSystemLabel "WINDOWS" }</pre> | |||
<blockquote>''Megjegyzés:'' a fenti kód csak akkor végzi el az átnevezést, ha a rendszerlemeznek még nincsen címkéje (a leírás szerinti telepítésnél így is van, de pl. [https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/sysprep--system-preparation--overview sysprep] után, vagy klónképből telepítésnél ez nem feltétlenül igaz).</blockquote> | |||
</div></div> | |||
* Ez a gép, Kezelés, Lemezkezelés: az (első) optikai olvasó betűjele legyen ''R''. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Setup 1st optical drive (if any) as drive R: | |||
https://wiki.geocom.hu/ | |||
#> | |||
Get-WmiObject -Class Win32_volume -Filter 'DriveType=5' | Select-Object -First 1 | ` | |||
Set-WmiInstance -Arguments @{DriveLetter='R:'} | Out-Null</pre> | |||
</div></div> | |||
}}</onlyinclude> | |||
<onlyinclude>{{#ifeq: {{{transcludesection|user}}}|user| | |||
* Asztalon jobbklikk, Nézet, Kis ikonok; ikonok elrendezése az asztalon. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Small icons on desktop | |||
http://www.tenforums.com/tutorials/62393-desktop-icons-size-change-windows-10-a.html | |||
#> | |||
$registryPath = "HKCU:\Software\Microsoft\Windows\Shell\Bags\1\Desktop"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "IconSize" -Value 32 -PropertyType "DWord" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "Mode" -Value 1 -PropertyType "DWord" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "LogicalViewMode" -Value 3 -PropertyType "DWord" -Force | Out-Null; ` | |||
Stop-Process -ProcessName Explorer</pre> | |||
<blockquote>''Megjegyzés:'' a fenti kód nem rendezi el az ikonokat az asztalon ('''TODO!''').</blockquote> | |||
</div></div> | |||
* Az Áruház és Posta alkalmazások tálcára rögzítését (jobbklikk után) oldjuk fel. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Unpin Mail and Store applications from the taskbar (Hungarian localized) | |||
https://stackoverflow.com/questions/45152335/unpin-the-microsoft-edge-and-store-taskbar-shortcuts-programmatically | |||
#> | |||
$appnames = "^Posta$|^Mail$|^Microsoft Store$"; ` | |||
((New-Object -Com Shell.Application).NameSpace('shell:::{4234d49b-0245-4df3-b780-3893943456e1}').Items() | ` | |||
Where-Object{$_.Name -match $appnames}).Verbs() | ` | |||
Where-Object{$_.Name.replace('&','') -match 'Unpin from taskbar|Levétel a tálcáról'} | ` | |||
ForEach-Object{$_.DoIt(); $exec = $true}</pre> | |||
</div></div> | |||
* ''Opcionálisan'' Start menü jobbklikk, Parancssor, fejlécen jobbklikk, Alapértelmezések, Betűtípus legyen ''Lucida Console'' 12-es; Elrendezés, Ablakméret legyen 80x25. | |||
<div class="toccolours mw-collapsible mw-collapsed"> | |||
<div style='text-align: right;'>PowerShell kódrészlet </div> | |||
<div class="mw-collapsible-content"> | |||
<pre><# Console window (cmd.exe) defaults - 80*25 chars, Lucida Console 12pt | |||
https://www.winhelponline.com/blog/set-cmd-prompt-default-window-size-position/ | |||
#> | |||
$registryPath = "HKCU:\Console"; ` | |||
IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` | |||
New-ItemProperty -Path $registryPath -Name "WindowSize" -Value 1638480 -PropertyType "DWord" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "FaceName" -Value "Lucida Console" -PropertyType "String" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "FontFamily" -Value 54 -PropertyType "DWord" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "FontSize" -Value 786432 -PropertyType "DWord" -Force | Out-Null; ` | |||
New-ItemProperty -Path $registryPath -Name "FontWeight" -Value 400 -PropertyType "DWord" -Force | Out-Null</pre> | |||
</div></div> | |||
}}</onlyinclude> | |||
A fentiek elvégzése után a gépet újra kell indítani. |
A lap jelenlegi, 2019. június 21., 22:35-kori változata
Transclusion teszt, ne vedd komolyan!
Windows 10 v1903
- Rendszergazdai rész
- Felhasználói rész
Alapbeállítások a Vezérlőpulton
A v1703 óta a Start menü, jobbklikk listaelemei közül száműzték a Vezérlőpultot és elemeit(!), ezért opcionálisan célszerű lehet azt a rendszergazda profilban a Keresés, Vez(érlőpult) paranccsal (vagy a Start menü, Windows Rendszer alól) történt elindítása után, a tálcára rögzíteni.
<# PowerShell: TODO! - seems to be simple, but isn't: https://github.com/Disassembler0/Win10-Initial-Setup-Script/issues/147 #>
- Vezérlőpult, Kis ikonok.
<# Control Panel, Classic View https://gist.github.com/alirobe/7f3b34ad89a159e6daa1 #> $registryPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\ControlPanel"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "StartupPage" -Value 1 -PropertyType "DWord" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "AllItemsIconView" -Value 1 -PropertyType "DWord" -Force | Out-Null
- Vezérlőpult, Fájlkezelő beállításai, Nézet fül, Megosztás varázsló KI, Az operációs rendszer védett fájljainak elrejtése maradjon BE (pl. a desktop.ini-k miatt), Ismert fájltípusok kiterjesztésinek elrejtése KI (soha nem fogják megtanulni...), Rejtett fájlok, mappák és meghajtók megjelenítése (BE), Üres meghajtók elrejtése (KI).
<# Explorer tweaks - disable sharing wizard, show extensions, hidden files, empty drives https://superuser.com/questions/898495/disable-sharing-wizard-with-batch https://stackoverflow.com/questions/4491999/configure-windows-explorer-folder-options-through-powershell/28016877 #> $registryPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "SharingWizardOn" -Value 0 -PropertyType "DWord" -Force | Out-Null;` New-ItemProperty -Path $registryPath -Name "HideFileExt" -Value 0 -PropertyType "DWord" -Force | Out-Null;` New-ItemProperty -Path $registryPath -Name "Hidden" -Value 1 -PropertyType "DWord" -Force | Out-Null;` New-ItemProperty -Path $registryPath -Name "HideDrivesWithNoMedia" -Value 0 -PropertyType "DWord" -Force | Out-Null
- Vezérlőpult, Rendszer, Távoli beállítások, Távsegítség KI.
<# Disable remote assistance https://superuser.com/questions/786383/how-to-enable-remote-assistance-and-add-an-exception-for-it-in-windows-firewall #> $registryPath = "HKLM:\System\CurrentControlSet\Control\Remote Assistance"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "fAllowToGetHelp" -Value 0 -PropertyType "DWord" -Force | Out-Null
- Vezérlőpult, Rendszer, Rendszervédelem, Beállítás, bekapcsolás és ésszerű mennyiségű tárterület (3-5 GB) megadása.
<# Set and enable shadow storage (computer restore) on Windows drive https://www.tenforums.com/tutorials/33460-change-system-protection-max-storage-size-drive-windows-10-a.html https://docs.microsoft.com/hu-hu/powershell/module/Microsoft.PowerShell.Management/Enable-ComputerRestore?view=powershell-5.1 #> vssadmin Resize ShadowStorage /for=$env:SystemDrive /on=$env:SystemDrive /maxsize=3GB | Out-Null;` Enable-ComputerRestore -Drive $env:SystemDrive | Out-Null
- Vezérlőpult, Rendszer, Speciális beállítások, Indítás és helyreállítás, Automatikus újraindítás KI (hogy látsszon a kék halál).
<# Disable automatic reboot on BSOD https://social.technet.microsoft.com/Forums/windowsserver/en-US/7badba7b-3157-443e-a3bf-7e6067bbdc25/disabling-bsod-automatic-restart-via-gpo?forum=winserverGP #> $registryPath = "HKLM:\System\CurrentControlSet\Control\CrashControl"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "AutoReboot" -Value 0 -PropertyType "DWord" -Force | Out-Null
- Vezérlőpult, Rendszer, Számítógépnév, töltsük ki a helyi szokásoknak megfelelően, munkacsoport-váltás esetén az újraindítást halasszuk el.
<# PowerShell: TODO! #>
- Vezérlőpult, Dátum és idő, Internetes idő, kiszolgáló Magyarországon time.kfki.hu, ha van IP kapcsolat, akkor azonnali frissítés.
<# Change the BIOS timezone to UTC and set a new Internet time server; start synchronization service whenever any network interface comes up https://social.technet.microsoft.com/Forums/en-US/636865b1-9211-48ca-9430-58f7a4b890ba/update-internet-time-using-batch-script-or-powershell?forum=winserversetup https://gist.github.com/alirobe/7f3b34ad89a159e6daa1 #> $TimeServer = "time.kfki.hu";` Stop-Service -Name "w32time";` $registryPath = "HKLM:\SYSTEM\CurrentControlSet\Control\TimeZoneInformation"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -path $registryPath -Name "RealTimeIsUniversal" -Value 1 -PropertyType "DWord" -Force | Out-Null; ` $registryPath = "HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\DateTime\Servers"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "0" -Value $TimeServer -PropertyType "String" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "(Default)" -Value "0" -PropertyType "String" -Force | Out-Null; ` sc.exe triggerinfo w32time start/networkon stop/networkoff | Out-Null; ` Start-Service -Name "w32time" | Out-Null; ` w32tm /config /manualpeerlist:$TimeServer,0x9 /update | Out-Null; ` w32tm /resync /force | Out-Null
Megjegyzés: a fenti kód azt is beállítja, hogy a BIOS-ban tárolt időt ne a helyi időzóna idejének (az MS-DOS alapértelmezése), hanem UTC időnek tekintsük (a Un*x rendszerek - így a Linux, MacOSX, stb. - alapértelmezése). A beállítás multiboot munkaállomások esetén hasznos, monoboot Windows 10 esetén irreleváns. Maga a BIOS idő itt nem módosul (a Windowsnak nincsen hwclock jellegű eszköze - TODO!), így azt érdemes ellenőrizni, ha kell, manuálisan beállítani. A kód beállítja továbbá az időszinkron szolgáltatás elindítását a hálózatra kapcsolódáskor (a tényleges szinkronizálásról azonban alább, külön kell gondoskodni). Fentiek beállítására jelenleg nincs felhasználói felület.
- Vezérlőpult, Energiagazdálkodási lehetőségek, Alvó állapotba lépés idejének módosítása, asztali munkaállomás esetén a használt (általában a kiegyensúlyozott) sémában sose menjen alvó állapotba (ez megakadályozná az esetleges távoli bejelentkezést); opcionálisan a képernyő kikapcsolása is letiltható vagy hosszabbra állítható. Hordozható gép esetén ugyanezt csak az Áramforráshoz csatlakoztatva állapotra állítsuk be. Notebook esetén vizsgáljuk felül a főkapcsolók funkcióját is (opcionálisan de javasoltan a főkapcsoló megnyomására Alvás helyett Leállítás).
<# Power settings (current power scheme - the balanced - only) https://stackoverflow.com/questions/33790965/set-a-one-line-powershell-for-sleep-and-hibernate-to-turn-off #> powercfg /CHANGE monitor-timeout-ac 10;` powercfg /CHANGE monitor-timeout-dc 5;` powercfg /CHANGE standby-timeout-ac 0;` powercfg /CHANGE standby-timeout-dc 15;` powercfg /CHANGE disk-timeout-ac 0;` powercfg /CHANGE disk-timeout-dc 15;` powercfg /CHANGE hibernate-timeout-ac 0;` powercfg /CHANGE hibernate-timeout-dc 0;` powercfg /SETACVALUEINDEX SCHEME_CURRENT sub_buttons pbuttonaction 3;` powercfg /SETDCVALUEINDEX SCHEME_CURRENT sub_buttons pbuttonaction 3
- Vezérlőpult, Hang, Hangok fül, Nincsenek hangok hangséma betöltése, Rendszerindítási hangjelzés lejátszása opcionálisan BE.
<# No event sounds except the startup sound https://www.tenforums.com/tutorials/5838-change-event-sounds-sound-scheme-windows-10-a.html https://superuser.com/questions/1300539/change-sound-scheme-in-windows-via-register https://www.sevenforums.com/tutorials/179448-startup-sound-enable-disable.html #> $registryPath = "HKCU:\AppEvents\Schemes\Apps"; ` Get-ChildItem -Path $registryPath | Select Name | ForEach-Object { ` $app = $_.Name -replace "HKEY_CURRENT_USER", "HKCU:"; ` Get-ChildItem -Path $app | Select Name | ForEach-Object { ` $event = $_.Name -replace "HKEY_CURRENT_USER", "HKCU:"; ` $eventnone = "$event\.None"; $eventcurrent = "$event\.Current"; ` IF(!(Test-Path $eventnone)) { ` New-Item -Path $eventnone -Force | Out-Null; ` New-ItemProperty -Path $eventnone -Name '(Default)' -Type 'ExpandString' -Value '' | Out-Null }; ` New-ItemProperty -Path $eventcurrent -Name '(Default)' -Type 'String' -Value '' | Out-Null }}; ` $registryPath = "HKCU:\AppEvents\Schemes"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "(Default)" -Value ".None" -PropertyType "String" -Force | Out-Null;`
$registryPath = "HKLM:\Software\Microsoft\Windows\CurrentVersion\Authentication\LogonUI\BootAnimation"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "DisableStartupSound" -Value 0 -PropertyType "DWord" -Force | Out-Null
Egyéb alapbeállítások
- Minden hálózatra kapcsolódáskor legyen időszinkron - Ez a gép, Kezelés, Feladatütemező, Művelet, Feladat létrehozása; Általános fülön Név Initial Time Synchronization, Felhasználói fiók SYSTEM, Futtatás akkor is, ha nincs bejelentkezve; Indítás fülön Új, Feladat megkezdése Eseménynél, Napló Microsoft-Windows-NetworkProfile/Műveletek, Forrás NetworkProfile, Eseményazonosító 10000, OK; Műveletek fülön Új, Program/parancsfájl w32tm, Argumentumok /resync, OK; Feltételek fülön Feladat indítása csak akkor, ha a számítógép hálózati áramról működik KI; OK.
<# Set a schedule to make a time synchronisation whenever any network interface comes up https://secopsmonkey.com/windows-time-synchonization-the-battle-continues.html https://www.petri.com/import-scheduled-tasks-powershell #> IF(!(Get-ScheduledTask | Where TaskName -EQ "Initial Time Synchronization")){Register-ScheduledTask -Xml @' <Task xmlns="http://schemas.microsoft.com/windows/2004/02/mit/task" version="1.2"> <Triggers> <EventTrigger> <Subscription> <QueryList><Query><Select Path='Microsoft-Windows-NetworkProfile/Operational'> *[System[Provider[@Name='Microsoft-Windows-NetworkProfile'] and (EventID=10000)]]</Select></Query></QueryList> </Subscription> </EventTrigger> </Triggers> <Settings> <DisallowStartIfOnBatteries>false</DisallowStartIfOnBatteries> <StopIfGoingOnBatteries>false</StopIfGoingOnBatteries> </Settings> <Actions Context="Author"> <Exec> <Command>w32tm</Command> <Arguments>/resync</Arguments> </Exec> </Actions> <Principals> <Principal id="Author"> <UserId>S-1-5-18</UserId> </Principal> </Principals> </Task> '@ -TaskName "Initial Time Synchronization" | Out-Null}
Megjegyzés: a fenti kódban azért használtam XML-t, mert az schtasks nem tudja kikapcsolni a futtatás tiltását akkumulátoros üzemmódban, viszont a PowerShell New-ScheduledTaskTrigger nem ismeri az event triggert (TODO!).
- Ez a gép, a rendszerlemezen (amely általában a C:) jobbklikk, Átnevezés, az új név legyen WINDOWS.
IF (!(Get-Volume -DriveLetter ($env:SYSTEMDRIVE) -ErrorAction SilentlyContinue | ` Select-Object -ExpandProperty FileSystemLabel)) { Set-Volume -DriveLetter (Get-Volume -DriveLetter ($env:SYSTEMDRIVE) -ErrorAction SilentlyContinue | ` Select-Object -ExpandProperty DriveLetter) ` -NewFileSystemLabel "WINDOWS" }
Megjegyzés: a fenti kód csak akkor végzi el az átnevezést, ha a rendszerlemeznek még nincsen címkéje (a leírás szerinti telepítésnél így is van, de pl. sysprep után, vagy klónképből telepítésnél ez nem feltétlenül igaz).
- Ez a gép, Kezelés, Lemezkezelés: az (első) optikai olvasó betűjele legyen R.
<# Setup 1st optical drive (if any) as drive R: https://wiki.geocom.hu/ #> Get-WmiObject -Class Win32_volume -Filter 'DriveType=5' | Select-Object -First 1 | ` Set-WmiInstance -Arguments @{DriveLetter='R:'} | Out-Null
- Asztalon jobbklikk, Nézet, Kis ikonok; ikonok elrendezése az asztalon.
<# Small icons on desktop http://www.tenforums.com/tutorials/62393-desktop-icons-size-change-windows-10-a.html #> $registryPath = "HKCU:\Software\Microsoft\Windows\Shell\Bags\1\Desktop"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "IconSize" -Value 32 -PropertyType "DWord" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "Mode" -Value 1 -PropertyType "DWord" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "LogicalViewMode" -Value 3 -PropertyType "DWord" -Force | Out-Null; ` Stop-Process -ProcessName Explorer
Megjegyzés: a fenti kód nem rendezi el az ikonokat az asztalon (TODO!).
- Az Áruház és Posta alkalmazások tálcára rögzítését (jobbklikk után) oldjuk fel.
<# Unpin Mail and Store applications from the taskbar (Hungarian localized) https://stackoverflow.com/questions/45152335/unpin-the-microsoft-edge-and-store-taskbar-shortcuts-programmatically #> $appnames = "^Posta$|^Mail$|^Microsoft Store$"; ` ((New-Object -Com Shell.Application).NameSpace('shell:::{4234d49b-0245-4df3-b780-3893943456e1}').Items() | ` Where-Object{$_.Name -match $appnames}).Verbs() | ` Where-Object{$_.Name.replace('&','') -match 'Unpin from taskbar|Levétel a tálcáról'} | ` ForEach-Object{$_.DoIt(); $exec = $true}
- Opcionálisan Start menü jobbklikk, Parancssor, fejlécen jobbklikk, Alapértelmezések, Betűtípus legyen Lucida Console 12-es; Elrendezés, Ablakméret legyen 80x25.
<# Console window (cmd.exe) defaults - 80*25 chars, Lucida Console 12pt https://www.winhelponline.com/blog/set-cmd-prompt-default-window-size-position/ #> $registryPath = "HKCU:\Console"; ` IF(!(Test-Path $registryPath)) {New-Item -Path $registryPath -Force | Out-Null}; ` New-ItemProperty -Path $registryPath -Name "WindowSize" -Value 1638480 -PropertyType "DWord" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "FaceName" -Value "Lucida Console" -PropertyType "String" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "FontFamily" -Value 54 -PropertyType "DWord" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "FontSize" -Value 786432 -PropertyType "DWord" -Force | Out-Null; ` New-ItemProperty -Path $registryPath -Name "FontWeight" -Value 400 -PropertyType "DWord" -Force | Out-Null
A fentiek elvégzése után a gépet újra kell indítani.