lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <542EA00B.4040401@pqgruber.com>
Date:	Fri, 03 Oct 2014 15:09:31 +0200
From:	Clemens Gruber <clemens.gruber@...ruber.com>
To:	linux-ext4@...r.kernel.org
Subject: Fast ext4 cleanup to avoid data loss after power failure

Hi,

I am using ext4 as root filesystem of my TQMa28-based board with 2GB eMMC.
In case of a power failure I have to clean up the filesystem in 1.5 to 2
seconds, that's how long the caps can sustain the power.

I pass the following rootflags on the kernel cmdline: data=journal,commit=1
In my user space application I open important files with O_SYNC.

Is there something else I can or should do to avoid data corruption?

I can detect when the power fails over a GPIO line, so I close open file
descriptors in one important application but doing a "normal"
poweroff/shutdown takes too long.

What would you do if you had 1.5 seconds until the power is gone?

Maybe a read-only rootfs and a separate small data partition?

Thanks for your help.

Best regards,
Clemens
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ