Skip to main content
10 events
when toggle format what by license comment
Dec 11, 2019 at 8:29 comment added jww Thanks @Dougie. Yeah, I know I need a swapfile. After removing dphys-swapfile I manually added a partition with swapfile and set swappiness. I can run my compiler again :)
Dec 10, 2019 at 22:09 comment added Dougie For some (unknown) reason the RPF folks don't ship Raspbian with a swap partition. They have dphys-swapfile enabled (albeit the file size used to be too small to be any use). I don't think the kernel cares whether the swap space is in a partition or in a file container in the root. The point I was trying to make was that having 1GB of RAM may mean swapping is unavoidable. @goldilocks
Dec 10, 2019 at 20:34 comment added goldilocks @Dougie A swap file has to be explicitly invoked (via swapon filepath); this is part of what the dphys-swapfile service does. If you have disabled dphys because you are using a different form of swap (eg., a partition listed in /etc/fstab), the swap file will never be spontaneously used regardless of circumstances. Whether there's much point in deleting it depends on how big it is in relation to how much space you have; if you never plan to re-enable dphys then it's just clutter.
Dec 10, 2019 at 19:59 comment added Dougie It's only safe to remove the swapfile if you will never over commit RAM. Swapping (which is much better on a USB device) is there to free up RAM from dormant processes to allow a memory hungry process to run. That's the sort of thing that's 100% invisible on your Windows laptop with 8GB or 16GB of RAM. On a Raspberry with 1GB of RAM having a swap file may save you from an unscheduled reboot.
Dec 10, 2019 at 17:45 comment added jww Thanks @godilocks. It looks like it is safe to remove dphys-swapfile.
Dec 10, 2019 at 17:41 vote accept jww
Dec 10, 2019 at 16:25 history edited goldilocks CC BY-SA 4.0
added 263 characters in body
Dec 10, 2019 at 16:14 history edited goldilocks CC BY-SA 4.0
added 2125 characters in body
Dec 10, 2019 at 15:57 history edited goldilocks CC BY-SA 4.0
added 811 characters in body
Dec 10, 2019 at 15:51 history answered goldilocks CC BY-SA 4.0