Skip to content

Commit 53144d9

Browse files
author
amsliu
committed
edit review feedback
1 parent e82974a commit 53144d9

3 files changed

Lines changed: 40 additions & 29 deletions

File tree

support/azure/virtual-machines/linux/serial-console-grub-proactive-configuration.md

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ You might have to perform a VM recovery for any of the following reasons:
2929
- Incorrect GRUB kernel parameters
3030
- Incorrect fstab configuration
3131
- Lost password
32-
- Firewall configuration
33-
- Networking configuration
32+
- Incorrect firewall configuration
33+
- Incorrect networking configuration
3434

3535
Many other scenarios are also possible, as detailed in the "Common scenarios for accessing the Serial Console" section of [Azure Serial Console for Linux](./serial-console-linux.md#common-scenarios-for-accessing-the-serial-console). Refer to this article for more help if you're a new user of the Serial Console.
3636

@@ -88,7 +88,7 @@ The VM must be configured to accept a value of **1** for the kernel parameter. T
8888

8989
[Enable SysRq video](https://youtu.be/0doqFRrHz_Mc)
9090

91-
To configure the VM to accept a restart through a SysRq commands on the Azure portal, you have to set a value of **1** for the kernel parameter, kernel.sysrq. For this configuration to persist a restart, add an entry to the **Sysctl.conf** file:
91+
To configure the VM to accept a restart through a SysRq commands on the Azure portal, you have to set a value of **1** for the kernel parameter, kernel.sysrq. To ensure this configuration persists after a restart, add an entry to the **Sysctl.conf** file:
9292

9393
`echo kernel.sysrq = 1 >> /etc/sysctl.conf`
9494

@@ -164,7 +164,7 @@ For Ubuntu 12.04 to obtain a **login:** prompt, follow these steps:
164164
exec /sbin/getty -L 115200 ttyS0 vt102
165165
```
166166

167-
2. Ask upstart to start the getty:
167+
2. Run the following command to start the getty service using Upstart:
168168

169169
```console
170170
sudo start ttyS0
@@ -211,7 +211,9 @@ If all goes well, the Recovery menu now displays additional options that can hel
211211

212212
#### Red Hat 7\.4\+ GRUB configuration
213213

214-
The default /etc/default/grub configuration on these versions is adequately configured
214+
For Red Hat 7.4 and later, the default `/etc/default/grub` configuration includes the necessary settings for serial console access and recovery. Unless you've made customizations to it, no further modifications are required.
215+
216+
On standard installations, the configuration appears as:
215217

216218
```console
217219
GRUB_TIMEOUT=5
@@ -375,7 +377,7 @@ It then displays the GRUB menu for an additional five seconds. Press the down ar
375377

376378
#### Force the kernel to a bash prompt
377379

378-
Having access to GRUB allows you to interrupt the initialization process. This interaction is useful for many recovery procedures. If you don't have a root password (as required by Single User mode), you can start the kernel by replacing the init program with a bash prompt.
380+
Having access to GRUB allows you to interrupt the initialization process. This interaction is useful for many recovery procedures. If you don't have a root password (as required by Single User mode), you can start the kernel by replacing the init program with a bash prompt.
379381

380382
1. To trigger the interruption, append `init=/bin/bash` to the kernel boot line.
381383

@@ -401,10 +403,12 @@ You might have to access the VM in Single User or Emergency mode. Select the ker
401403

402404
For more information about how to access Single User mode, see [Use Serial Console to access GRUB and single-user mode](./serial-console-grub-single-user-mode.md#general-single-user-mode-access)
403405

404-
:::image type="content" source="media/serial-console-grub-proactive-configuration/single-user-ubuntu.png" alt-text="Screenshot of the *Ubuntu entry in the boot the selected OS screen in GRUB.":::
406+
:::image type="content" source="media/serial-console-grub-proactive-configuration/single-user-ubuntu.png" alt-text="Screenshot of the GRUB boot menu showing Ubuntu selected (indicated by an asterisk).":::
405407

406408
## Next steps
407409

408-
Learn more about [Azure Serial Console](./serial-console-linux.md)
410+
Learn more about [Azure Serial Console](./serial-console-linux.md).
409411

410412
[!INCLUDE [Azure Help Support](../../../includes/azure-help-support.md)]
413+
414+
[!INCLUDE [Third-Party Disclaimer](../../../includes/third-party-disclaimer.md)]

support/azure/virtual-machines/linux/serial-console-nmi-sysrq.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,10 @@ From the SysRq Admin Guide:
6565
|``h`` | Displays help. (Any key other than those that are listed here also displays help, but "h" is easy to remember.)
6666
|``i`` | Send a SIGKILL to all processes, except for init.
6767
|``j`` | Forcibly thaws filesystems that are frozen by the FIFREEZE ioctl.
68-
|``k`` | Secure Access Key (SAK) that kills all programs on the current virtual console. NOTE: See important comments in the following SAK section.
68+
|``k`` | Secure Access Key (SAK) that kills all programs on the current virtual console.
6969
|``l`` | Shows a stack backtrace for all active CPUs.
7070
|``m`` | Dumps current memory information to your console.
71-
|``n`` | Used to make RT tasks nice-able.
71+
|``n`` | Allows real-time (RT) tasks to be reprioritized using the nice value. NOTE: The nice value controls a process’s priority for CPU scheduling, where lower values indicate higher priority.
7272
|``o`` | Shuts off your system (if configured and supported).
7373
|``p`` | Dumps the current registers and flags to your console.
7474
|``q`` | Dumps CPU lists of all armed hrtimers (but not regular timer_list timers) and detailed information about all clockevent devices.

support/azure/virtual-machines/windows/serial-console-cmd-ps-commands.md

Lines changed: 26 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ Because of SAC's limited screen buffer, it might be easier to manage longer comm
3333

3434
## Use CMD for Windows registry settings
3535

36-
To view and edit Windows registry csettings by using CMD, follow these steps:
36+
To view and edit Windows registry settings by using CMD, follow these steps:
3737

3838
1. Verify that RDP is enabled by running the following commands:
3939

4040
reg query "HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server" /v fDenyTSConnections
4141

4242
reg query "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v fDenyTSConnections
4343

44-
**Note:** The second key (under \Policies) exists only if the relevant Group Ppolicy setting is configured.
44+
**Note:** The second key (under \Policies) exists only if the relevant Group Policy setting is configured.
4545

4646
1. Enable RDP by running the following commands:
4747

@@ -53,7 +53,7 @@ reg add "HKLM\SOFTWARE\Policies\Microsoft\Windows NT\Terminal Services" /v fDeny
5353

5454
## Use CMD to manage Windows services
5555

56-
To manage Windows services by usign CMD< follow these steps:
56+
To manage Windows services by using CMD, follow these steps:
5757

5858
1. View the service state:
5959

@@ -95,15 +95,15 @@ To manage Windows services by usign CMD< follow these steps:
9595

9696
## Use CMD to manage networking features
9797

98-
Use manage networking features by using CMD, follow these steps:
98+
To manage networking features using CMD, follow these steps:
9999

100100
1. Show the network shell (netsh) properties:
101101

102-
> `netsh interface show interface`
102+
`netsh interface show interface`
103103

104104
1. Show IP properties:
105105

106-
> `netsh interface ip show config`
106+
`netsh interface ip show config`
107107

108108
1. Show IPSec configuration:
109109

@@ -169,7 +169,7 @@ You can use this command when troubleshooting to temporarily rule out the Window
169169

170170
`net localgroup Administrators <username> /add`
171171

172-
### Verify user account is enabled
172+
### Verify that the user account is enabled
173173

174174
`net user <username> | find /i "active"`
175175

@@ -185,17 +185,19 @@ Azure VMs created from generalized image will have the local administrator accou
185185

186186
Example lines of interest from a local admin account:
187187

188-
`Account active Yes`
188+
```text
189+
Account active Yes
189190
190-
`Account expires Never`
191+
Account expires Never
191192
192-
`Password expires Never`
193+
Password expires Never
193194
194-
`Workstations allowed All`
195+
Workstations allowed All
195196
196-
`Logon hours allowed All`
197+
Logon hours allowed All
197198
198-
`Local Group Memberships *Administrators`
199+
Local Group Memberships *Administrators
200+
```
199201

200202
### View local groups
201203

@@ -233,7 +235,7 @@ Use `604800000` to look back seven days instead of 24 hours.
233235

234236
`wmic product get Name,InstallDate | sort /r | more`
235237

236-
The `sort /r` sorts descending by install date to make it easy to see what was recently installed. Use `<spacebar>` to advance to the next page of output, or `<enter>` to advance one line.
238+
The `sort /r` command sorts results in descending order by install date, making it easier to identify recently installed applications. Use `<spacebar>` to advance to the next page of output, or `<enter>` to advance one line.
237239

238240
### Uninstall an application
239241

@@ -273,7 +275,8 @@ See also [Repair a Windows Image](/windows-hardware/manufacture/desktop/repair-a
273275

274276
`icacls %programdata%\Microsoft\Crypto\RSA /save %temp%\MachineKeys_permissions_before.aclfile /t`
275277

276-
The path when using `/restore` needs to be the parent folder of the folder you specified when using `/save`. In this example, `\RSA` is the parent of the `\MachineKeys` folder specified in the `/save` example above.
278+
When using `/restore`, specify the parent folder of the one used in
279+
`/save`. For example, use `\RSA` if you previously saved permissions for `\MachineKeys`.
277280

278281
### Take NTFS ownership of a folder
279282

@@ -287,11 +290,13 @@ The path when using `/restore` needs to be the parent folder of the folder you s
287290

288291
### Remove non-present PNP devices
289292

293+
This command cleans up device entries for hardware no longer present on the system:
294+
290295
`%windir%\System32\RUNDLL32.exe %windir%\System32\pnpclean.dll,RunDLL_PnpClean /Devices /Maxclean`
291296

292297
## Manage Group Policy
293298

294-
### Force group policy update
299+
### Force a Group Policy update
295300

296301
`gpupdate /force /wait:-1`
297302

@@ -348,7 +353,7 @@ To run PowerShell in SAC, after you reach a CMD prompt, type:
348353
`powershell <enter>`
349354

350355
> [!CAUTION]
351-
> Remove the PSReadLine module from the PowerShell session before running any other PowerShell commands. here's a known issue where extra characters may be introduced in text pasted from the clipboard if PSReadLine is running in a PowerShell session in SAC.
356+
> Remove the PSReadLine module from the PowerShell session before running any other PowerShell commands. There's a known issue where extra characters may be introduced in text pasted from the clipboard if PSReadLine is running in a PowerShell session in SAC.
352357
353358
First check if PSReadLine is loaded. It's loaded by default on Windows Server 2016, Windows 10, and later versions of Windows. It would only be present on earlier Windows versions if it's manually installed.
354359

@@ -360,6 +365,8 @@ If the above command returns the PSReadLine module version, run the following co
360365

361366
`remove-module psreadline`
362367

368+
If PSReadLine is loaded, it may introduce extra characters when pasting text. To avoid this, unload the module using `remove-module psreadline`.
369+
363370
## View and Edit Windows Registry Settings using PowerShell
364371

365372
### Verify RDP is enabled
@@ -368,7 +375,7 @@ If the above command returns the PSReadLine module version, run the following co
368375

369376
`get-itemproperty -path 'hklm:\software\policies\microsoft\windows nt\terminal services' -name 'fdenytsconNections'`
370377

371-
The second key (under \Policies) only exists if the relevant group policy setting is configured.
378+
The second key under `\Policies` exists only if the relevant Group Policy setting is configured.
372379

373380
### Enable RDP
374381

@@ -545,7 +552,7 @@ or
545552

546553
`get-winevent -logname system -maxevents 1 -filterxpath "*[System[Level=2]]" | more`
547554

548-
Change `/c:10` to the desired number of events to return, or move it to return all events matching the filter.
555+
Change `/c:10` to the desired number of events to return, or remove it to return all matching events.
549556

550557
### Query event log by Event ID
551558

0 commit comments

Comments
 (0)