79 words
1 minute
macOS 关闭Swap

1. 关闭SIP#

关机后开机并继续按住电源按钮直到开启启动选项窗口,进入恢复模式。(Apple Silicon)

在终端中输入:

csrutil disable

2. 调整内存策略#

重新启动Mac后

sudo nvram boot-args="vm_compressor=2"

就可以设置为仅压缩、不使用swap

至此就关闭了sawp。

macOS 关闭Swap
https://fuwari.vercel.app/posts/macdisableswap/
Author
Akatsuki Sky
Published at
2025-02-12
License
CC BY-NC-SA 4.0