On Sat, Dec 18, 2010 at 4:33 AM, Ala'a Mohammad amalawi@gmail.com wrote:
There has been some great work, I believe done cooperatively by Stanford and U.C. Berkeley, about how to deal with this. Do a web search for "crash-only systems". What you have to do is be able to quickly recover from such failures, getting you back to the same state you were in, or at least that latest state that you decided to checkpoint.
forgot to mention that one of the features I like most of CLISP is that its EXT:SAVEINITMEM will save a snapshot or an image without quiting the current image. http://www.gnu.org/software/clisp/impnotes/image.html
With some care and on Unix/Linux, you can use fork(2) a child process to create a copy of the currently running Lisp image and than save an image in the child. I have used that technique with SBCL and CMUCL, both in order to write out a Lisp images and to write out snapshots of large in-memory data structures without pausing or terminating system operation.
In general, I always keep a clean dump of the persistent data structures that I want to keep in addition to any dumped Lisp images. I use Lisp images to optimize startup times, and explicit serialization to carry data over from one system release to another. Snapshotting the relevant data also makes it possible to switch Lisp implementations (which is something that I've actually done, with live data, from cmucl to sbcl to ccl).
-Hans