Skip to content

Commit 44681f4

Browse files
Update p3-fsjournal.md
1 parent 5787ef9 commit 44681f4

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lec9/p3-fsjournal.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,9 @@ backgroundColor: white
8989

9090
考虑一个应用以某种方式更新磁盘结构:将单个数据块附加到原有文件。
9191
- 通过打开文件,调用`lseek()`将文件偏移量移动到文件末尾,然后在关闭文件之前,向文件发出单个4KB写入来完成追加。
92-
92+
- lseek + write 并非原子操作。多个进程可能在 lseek 和 write 之间修改文件,导致偏移量失效。
93+
94+
9395
---
9496

9597
##### 文件系统数据结构

0 commit comments

Comments
 (0)