swapfile broken
See original GitHub issueHey all,
Not sure when or how this happened, but the dphys-swapfile service keeps failing. I figured it happened when I updated from v1.7 to v1.7.2
I looked at my partitions and /mnt/temp is VFAT I went through the steps manually to create a swapfile (reading the bash scripts) and I think I found the issue:
admin# dd if=/dev/zero of=/mnt/temp/swapfile count=4096 bs=1MiB
dd: error writing '/mnt/temp/swapfile': File too large
The command does end up creating a file:
-rwxr-xr-x 1 bitcoin bitcoin 4294967295 Jul 12 03:00 swapfile
So maybe this is a red herring, but I think that is probably the root cause, I’m not sure whether I should change the format of the partition, or reduce the swapfile size?
Issue Analytics
- State:
- Created a year ago
- Comments:8 (5 by maintainers)
Top Results From Across the Web
How to Fix the Read-Error on Swap-Device Failure in Ubuntu ...
The Read-error on Swap-device error occurs when your Ubuntu system is low on swap memory. Here's how you can fix the issue.
Read more >How can I fix this 'Failed to activate swap /swapfile' error on ...
N.B.: I'm using hibernation, thus I need a 16 GB swapfile. Here is a Pastebin with boot-repair output. ls -al / shows: total...
Read more >Swap file creation broken? - Troubleshooting - DietPi
Hello, I try to create a swap file on my odroid and my pi 3. I do dietpi-drive_manager → selecting the drive →...
Read more >dphys-swapfile failed - Raspberry Pi Forums
dphys-swapfile is fundamentally broken because it's using fallocate which is badly broken. Here's a recipe to get a swap file working
Read more >raspbian - Failed to start dphys-swapfile.service
The swapfile service will run then out of the box without errors. ... to determine the filesystem and it was broken (causing segfaults)....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

FYI, temporarily, I was able to get it all working by setting
CONF_MAXSWAPto 4095 and by usingcount=4095in theddcommand.OK fixes so far will be inclused in v1.8.0 release - to be revisited with v1.8.1 - if no further reports it can be closed then,