| ▲ | tremon 14 hours ago | ||||||||||||||||||||||||||||||||||||||||||||||
That's not useful as a rule of thumb, since you can't know the size of "all inactive anonymous pages" without doing extensive runtime analysis of the system under consideration. That's pretty much the opposite of what a rule of thumb is for. | |||||||||||||||||||||||||||||||||||||||||||||||
| ▲ | man8alexd 14 hours ago | parent [-] | ||||||||||||||||||||||||||||||||||||||||||||||
You are right, it is not a rule of thumb, and you can't determine optimal swap size right away. But you don't need "extensive runtime analysis". Start with a small swap - a few hundred megabytes (assuming the system has GBs of RAM). Check its utilization periodically. If it is full, add a few hundred megabytes more. That's all. | |||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||