Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: Adding swap recommends fallocate, however fallocate has holes #1608

Closed
Eaterminer opened this issue Jan 11, 2025 · 3 comments · Fixed by flatcar/flatcar-website#381
Closed
Labels
good first issue Get started with Flatcar contribution with this issue. kind/docs

Comments

@Eaterminer
Copy link

Creating swap with holes is generally regarded as a really bad idea.
dd if=/dev/zero of=PATH is a better method because it doesn't create holes.

@tormath1
Copy link
Contributor

Hello @Eaterminer and thanks for the heads-up. I think a clean way to create swap files would be to rely on mkswap directly. Would you be happy to contribute to the documentation here: https://github.com/flatcar/flatcar-website/blob/faf23bd5283524e180cb83a8e0c1cc268c10b574/content/docs/latest/setup/storage/adding-swap.md?plain=1#L67-L69 and update those lines to something like:

mkswap -U clear --size 1024m --file /var/vm/swapfile1

@tormath1 tormath1 added the good first issue Get started with Flatcar contribution with this issue. label Jan 13, 2025
@Eaterminer
Copy link
Author

Sure, I'll get a PR by the end of today :)

@Eaterminer
Copy link
Author

@tormath1 PR opened, #381

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Get started with Flatcar contribution with this issue. kind/docs
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants