public inbox for linux-pm@vger.kernel.org
 help / color / mirror / Atom feed
From: Daniel Drake <ddrake@brontes3d.com>
To: linux-pm@osdl.org
Cc: suspend-devel@lists.sourceforge.net
Subject: Dangers of touching disk between suspend and resume
Date: Tue, 28 Nov 2006 10:21:47 -0500	[thread overview]
Message-ID: <1164727307.26898.12.camel@systems03.lan.brontes3d.com> (raw)

Hi,

I have some questions about this text in Documentation/power/swsusp.txt:

 * If you touch anything on disk between suspend and resume...
 *				...kiss your data goodbye.

It's obvious that this is a bad idea but I'm interested in the details.
I'm working with the userspace suspend-to-disk tools in this case.

Specifically, where it says "kiss your data goodbye" is that saying that
upon next resume you would lose data in open and unsaved documents (i.e.
session data), or does it mean that your root partition is effectively
destroyed?

Is the danger only in touching the swap partition where the resume data
is saved, or is mounting any of the filesystems that are mounted in the
suspended session dangerous? How dangerous? Are we talking instant loss
of entire filesystem, or just a chance that some files will be
corrupted? When does the corruption happen - during mount after suspend
but before resume, or during resume after suspend+modifications?

What kind of dangers are associated with suspending to disk, modifying
data on disk but then *not* resuming (doing a complete boot, e.g.
recreating the swap partition to prevent resume from being attempted)?

The context I'm thinking of is an engineer called out to repair a broken
system. This system will not boot, lets say the RAM is screwed and the
kernel hangs/panics during early init (before any resuming is
attempted).

Without touching the disks, there is no way of knowing if the system was
shut down fully or suspended-to-disk on last shutdown. It is unknown
whether it is safe to plug the disks into another system, mount them and
recover data (since the last session might have been suspended). Even
though some part of the hardware is broken, data loss is not an
acceptable risk (except of course when the hard disks have failed).

Any input appreciated.

Thanks!
-- 
Daniel Drake
Brontes Technologies, A 3M Company


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

             reply	other threads:[~2006-11-28 15:21 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-28 15:21 Daniel Drake [this message]
2006-11-28 15:43 ` [linux-pm] Dangers of touching disk between suspend and resume Alan Stern
2006-11-28 16:37   ` Stefan Seyfried
2006-11-28 19:43     ` Daniel Drake
2006-11-30 20:00     ` Peter Jones
2006-11-30 20:13       ` Stefan Seyfried
2006-11-30 22:17         ` Peter Jones
2006-12-01  7:39           ` Stefan Seyfried
2006-12-02  4:41             ` Nigel Cunningham
2006-12-04  8:10               ` Stefan Seyfried
2006-12-05 11:28                 ` Nigel Cunningham
2006-12-05 11:44                   ` Stefan Seyfried
2006-12-05 11:51                   ` Matt Sealey
2006-12-06  0:10                     ` Nigel Cunningham
2006-12-09 15:25                       ` Matthew Garrett
2006-11-30 20:42       ` Daniel Drake

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1164727307.26898.12.camel@systems03.lan.brontes3d.com \
    --to=ddrake@brontes3d.com \
    --cc=linux-pm@osdl.org \
    --cc=suspend-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox