Windows Server - как сбросить пароль Administrator через rescue режим: различия между версиями

Материал из Wiki - Iphoster - the best ever hosting and support. 2005 - 2023
Перейти к:навигация, поиск
Строка 7: Строка 7:
 
'''2) Ставим утилиту chntpw и монтируем диск''' <br>
 
'''2) Ставим утилиту chntpw и монтируем диск''' <br>
 
  # apt update && apt install chntpw -y
 
  # apt update && apt install chntpw -y
 +
# ntfsfix /dev/vdb1
 
  # mount -t ntfs-3g /dev/vdb1 /mnt
 
  # mount -t ntfs-3g /dev/vdb1 /mnt
 
  # cd /mnt/Windows/System32/config
 
  # cd /mnt/Windows/System32/config

Версия 17:51, 6 декабря 2021

Доступная цена

Windows Server - как сбросить пароль Administrator через rescue режим

1) Переводить VPS в rescue режим на Ubuntu/Debian
2) Ставим утилиту chntpw и монтируем диск

# apt update && apt install chntpw -y
# ntfsfix /dev/vdb1
# mount -t ntfs-3g /dev/vdb1 /mnt
# cd /mnt/Windows/System32/config

3) Смотрим список пользователей Windows Server и обнуляем пароль от Administrator:

# chntpw -l SAM - посмотреть список пользователей Windows Server
# chntpw -u Administrator SAM
Жмем 1 --> Enter --> q (Quit) --> y (Yes)

4) Убираем Rescue mode и входим на Windows Server через VNC или RDP без пароля

5) Меняем пароль через CTRL + ALT + DEL --> Изменить пароль (текущий пароль оставить пустым)
6) Включаем доступ по RDP и по-требованию отключаем брандмауэр


Ошибка при монтировании диска:

# mount -t ntfs-3g /dev/vdb1 /mnt
The disk contains an unclean file system (0, 0).
Metadata kept in Windows cache, refused to mount.
Failed to mount '/dev/vdb1': Operation not permitted
The NTFS partition is in an unsafe state. Please resume and shutdown
Windows fully (no hibernation or fast restarting), or mount the volume
read-only with the 'ro' mount option.

решается командой:

# ntfsfix /dev/vdb1