Skip to content

Commit 54ac875

Browse files
Merge pull request #235979 from msaenzbosupport/patch-16
[Doc-A-THon] Updating codeblock and sudo
2 parents f542093 + b185926 commit 54ac875

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

articles/azure-netapp-files/performance-linux-nfs-read-ahead.md

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,15 @@ Read-ahead can be defined either dynamically per NFS mount using the following s
5353

5454
To show the current read-ahead value (the returned value is in KiB), run the following command:
5555

56-
`$ ./readahead.sh show <mount-point>`
56+
```bash
57+
./readahead.sh show <mount-point>
58+
```
5759

5860
To set a new value for read-ahead, run the following command:
5961

60-
`$ ./readahead.sh set <mount-point> [read-ahead-kb]`
62+
```bash
63+
./readahead.sh set <mount-point> [read-ahead-kb]
64+
```
6165

6266
### Example
6367

@@ -100,11 +104,15 @@ To persistently set read-ahead for NFS mounts, `udev` rules can be written as fo
100104

101105
1. Create and test `/etc/udev/rules.d/99-nfs.rules`:
102106

103-
`SUBSYSTEM=="bdi", ACTION=="add", PROGRAM="<absolute_path>/awk -v bdi=$kernel 'BEGIN{ret=1} {if ($4 == bdi) {ret=0}} END{exit ret}' /proc/fs/nfsfs/volumes", ATTR{read_ahead_kb}="15380"`
107+
```config
108+
SUBSYSTEM=="bdi", ACTION=="add", PROGRAM="<absolute_path>/awk -v bdi=$kernel 'BEGIN{ret=1} {if ($4 == bdi) {ret=0}} END{exit ret}' /proc/fs/nfsfs/volumes", ATTR{read_ahead_kb}="15380"
109+
```
104110

105111
2. Apply the `udev` rule:
106112

107-
`$udevadm control --reload`
113+
```bash
114+
sudo udevadm control --reload
115+
```
108116

109117
## Next steps
110118

0 commit comments

Comments
 (0)