3

I've installed Manjaro on a USB stick (I mean real installation, not the live ISO - Manjaro ISO lacks persistence support) and also made a swap partition on it.

But I would like it to prefer using a swap partition on the host computer SSD whenever it can be found there (so it would work faster).

I don't really know how it works now, maybe it even does this by default. Does it? If it doesn't how do I make it to?

  • Bear in mind you don't have to use a swap partition. – steve Aug 13 at 21:21
0

Your OS needs to know exactly where that swap file or swap partition is, and that location will differ with every different installation it touches, so that's not going to be automagic.

However, you could use ZRAM which swaps into compressed memory. Here's an article on configuring it with Manjaro, an alternative for more speed.

0

Even if there is a swap partion on the computer you are running on, it may not be safe to use it. Some system save the running state to swap when hibernating, so you could damage the system's state.

Baring that, you can script a search of the drives and try to mount any swap partition that you find. Swap partitions have a specific type which is listed by tools such as "fdisk". This command will find the swap partirions on /dev/sdb"

   sudo fdisk -l /dev/sdb | grep swap

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.