Skip to content

Commit 4c83b10

Browse files
committed
DOC-4028 RS: Fix comment out swap partitions example
1 parent 048669d commit 4c83b10

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

content/operate/rs/installing-upgrading/configuring/linux-swap.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ must have `sudo` access or be a root user to run the following commands:
2727
sudo swapoff -a
2828
```
2929

30-
1. Comment out the swap partitions configured in the OS so swap remains off even after a reboot:
30+
1. Comment out the swap partitions configured in `/etc/fstab` so swap remains off even after a reboot:
3131

3232
```sh
33-
sudo sed -i.bak '/ swap / s/^(.*)$/#1/g' /etc/fstab
33+
sudo sed -i.bak 's/^[^#].*swap.*/#&/' /etc/fstab
3434
```

0 commit comments

Comments
 (0)