question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Hey 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:closed
  • Created a year ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
dipunmcommented, Jul 12, 2022

FYI, temporarily, I was able to get it all working by setting CONF_MAXSWAP to 4095 and by using count=4095 in the dd command.

0reactions
rootzollcommented, Jul 27, 2022

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,

Read more comments on GitHub >

github_iconTop 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 >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found