this post was submitted on 27 May 2024
28 points (71.2% liked)

Linux

7847 readers
1 users here now

Welcome to c/linux!

Welcome to our thriving Linux community! Whether you're a seasoned Linux enthusiast or just starting your journey, we're excited to have you here. Explore, learn, and collaborate with like-minded individuals who share a passion for open-source software and the endless possibilities it offers. Together, let's dive into the world of Linux and embrace the power of freedom, customization, and innovation. Enjoy your stay and feel free to join the vibrant discussions that await you!

Rules:

  1. Stay on topic: Posts and discussions should be related to Linux, open source software, and related technologies.

  2. Be respectful: Treat fellow community members with respect and courtesy.

  3. Quality over quantity: Share informative and thought-provoking content.

  4. No spam or self-promotion: Avoid excessive self-promotion or spamming.

  5. No NSFW adult content

  6. Follow general lemmy guidelines.

founded 1 year ago
MODERATORS
 

swap feels like cheating

top 12 comments
sorted by: hot top controversial new old
[โ€“] [email protected] 17 points 5 months ago (1 children)

Windows has swap too though

[โ€“] [email protected] 7 points 5 months ago* (last edited 5 months ago) (2 children)
[โ€“] [email protected] 3 points 5 months ago (1 children)

Windows does have memory compression, though you can't really change the algorithm or how aggressive it is. AFAIK it is just a toggle of on or off.

[โ€“] [email protected] 4 points 5 months ago* (last edited 5 months ago)

Zram is very different. What Windows has is closer to Zswap.

[โ€“] [email protected] 3 points 5 months ago (2 children)

yeah, in poweshell type Enable-MMAgent -MemoryCompression

[โ€“] [email protected] 5 points 5 months ago* (last edited 5 months ago) (1 children)

That's not that same. That's closer to Zswap. "Enable-MMAgent -MemoryCompression" enables compressing inactive memory pages in RAM. Zram is 1 or more compressed block devices in RAM that can store a much larger variety of data.

[โ€“] [email protected] 1 points 5 months ago

Yeah, I remember using ramdrive.sys in the DOS days to make a drive letter in memory to speed up our CAD software. My point was windows has similar tools for memory compression and drives, just that it is not as easily tinkeres with like Linux.

[โ€“] [email protected] 1 points 5 months ago (1 children)

And the next question, can you make a RAM drive? Yes ImDisk. Even DOS had ramdrive.sys

[โ€“] [email protected] 6 points 5 months ago* (last edited 5 months ago) (1 children)

Zram offers way more flexibility and versatility compared to ImDisk.
Zram can be used for swap space or as a general-purpose RAM disk. Unlike a traditional RAM drive, Zram can compress data using a nice hand full of algorithms, notably Zstd; allowing it to store more information within the same RAM capacity leading to faster I/O and efficient memory usage with minimal CPU usage; & LZO-RLE; offering the fastest compression and decompression speeds leading to faster data swapping between compressed and uncompressed states, potentially improving overall system performance. Also, ImDisk afaik only offers NTFS compression for RAM drives which is... well.. pretty damn slow for this particular use comparatively.
Additionally, Zram persistence can be configured with writeback devices. ImDisk typically doesn't offer persistence.
ramdrive.sys isn't even worth talking about, it never had any kind of compression let alone anything else I mentioned previously.

[โ€“] [email protected] 2 points 5 months ago* (last edited 5 months ago)

These things exist in windows (or as 3 party tool like RAWcopy etc for writeback) its just their OS is not setup to make tinkering a simple matter like in Linux. You don't have to convince me as I'm already a Linux household since Windows10 came out. But the post was claiming Linux was superior because of Swap...Windows has this, so the meme is a bad one

[โ€“] [email protected] 2 points 5 months ago

If you use swap (excluding hibernation) it means you need more ram.

[โ€“] [email protected] 2 points 5 months ago

Get the aloe vera