On Fri, 19 Mar 2021 22:55:43 +0000, Markus Robert Kessler wrote:
> - What can be done remotely now to "repair" the FS? -- I can hardly pull
> the card out of it and run an fsck on a second machine via VPN.
> B.t.w., badblocks came back with 0 errors, the SD card seems still ok.
>
A few questions:
- How full is the card? "df -h" should show that.
- How long has thus card been in use?
- Are you running 'fstrim' on the card and, if so , how frequently?
-- but see below ---
- Can you describe how you collect and store data on the Pi4 - by that I
mean how big are the files, how many are held on the Pi, how long is
each file held, or are you using a database?
- If you're using files, how is each written to? IOW is it left open and
data added until it hits a preset limit and a new one is opened, or is
the file normally closed and every so often the file is opened, data
appended to it and the file closed again. How often are old files
discarded to make room for more data and how are the old files chosen
for deletion?
- How easy is it to change the maximum number and size of files [or
rows in the database table(s)] on the Pi?
** Guess **
Could it be that you have never run fstrim? If so, running it may help:
something like "sudo fstrim -v /home" should do the trick - however I've
just tried it on a Pi 2B running Buster and, since I don't usually run
fstrim on the Pi, I thought it would do its thing (I run it weekly on a
Lenovo laptop with a Sanyo 120 GB SSD and Fedora Linux; several Kb of
blocks are trimmed each time fstrim is run. However, on the Pi 2 (16GB SD
card fitted) 'fstrim' just reports zero bytes trimmed, i.e. it didn't do
anything.
I assume from this that by design fstrim does nothing when pointed at a
partition on and SD card. Can anybody confirm this? The manpage is silent
about using in on SD cards.
However, the other stuff I asked about should let us make sensible
suggestions.
--
Martin | martin at
Gregorie | gregorie dot org
--- SoupGate-Win32 v1.05
* Origin: Agency HUB, Dunedin - New Zealand | FidoUsenet Gateway (3:770/3)
|