fewit.ru :: Заметки недоайтишника

Ещё один криворукий админ

netsh interface ip set address name="Local Area Connection" static 192.168.1.15 255.255.255.0 192.168.1.1
netsh interface ip set dns "Local Area Connection" static 8.8.8.8
netsh interface ip set address "Local Area Connection" dhcp

Get-WindowsCapability -Online | ? Name -like 'OpenSSH*'
Add-WindowsCapability -Online -Name OpenSSH.Client~~~~0.0.1.0

Add-WindowsCapability -Online -Name OpenSSH.Server~~~~0.0.1.0

Start-Service sshd
# OPTIONAL but recommended:
Set-Service -Name sshd -StartupType 'Automatic'
# Confirm the Firewall rule is configured. It should be created automatically by setup.
Get-NetFirewallRule -Name *ssh*
# There should be a firewall rule named "OpenSSH-Server-In-TCP", which should be enabled
# If the firewall does not exist, create one
New-NetFirewallRule -Name sshd -DisplayName 'OpenSSH Server (sshd)' -Enabled True -Direction Inbound -Protocol TCP -Action Allow -LocalPort 22
New-NetFirewallRule -DisplayName "Allow inbound ICMPv4" -Direction Inbound -Protocol ICMPv4 -IcmpType 8 -Action Allow

26 декабря, 2020

Posted In: Windows

Метки: , , ,

Смотри какая версия сейчас:

DISM /online /Get-CurrentEdition

Смотрим на что можно перейти:

DISM /online /Get-TargetEditions

Переходим:

DISM /online /Set-Edition:ServerStandard /ProductKey:ХХХХХХХХХХХХХХХХ /AcceptEula

Публичные KMS ключи для Windows Server 2016

Windows Server 2016 Standard	WC2BQ-8NRM3-FDDYY-2BFGV-KHKQY
Windows Server 2019 Standard	N69G4-B89J2-4G8F4-WWYCC-J464C
Windows Server 2022 Standard	VDYBN-27WPP-V4HQT-9VMD4-VMK7H
Windows Server 2025 Standard	TVRH6-WHNXV-R9WG3-9XRFY-MY832

Полезные команды:
Убираем тестовый режим

bcdedit /set testsigning off

Продлить ещё на 180 дней:

slmgr /rearm

Смена ключа:

slmgr -ipk ТВОЙ_КЛЮЧ

Активация:

slmgr -ato

Проверка состояния активации:

slmgr -dlv

20 ноября, 2017

Posted In: Windows

Метки: ,