~ubuntu-branches/debian/stretch/uswsusp/stretch

« back to all changes in this revision

Viewing changes to HOWTO

  • Committer: Bazaar Package Importer
  • Author(s): Rodolfo García Peñas (kix), Rodolfo García Peñas (kix), Closes: #552484, #576803, #528483, Closes: #495111, #595125, #486352, #433872, #590233, Closes: #550725, #549118, Closes: #437094, #586674, #547158, #567604, Closes: #520705, Anibal Monsalve Salazar
  • Date: 2011-03-14 08:26:16 UTC
  • mfrom: (0.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20110314082616-7mjcl6tfzsv22arm
Tags: 1.0-1
[ Rodolfo García Peñas (kix) ]
* New 1.0 version [Closes: #589743, #578496, #617534]
* A lot of new machines. 
  [Closes: #552484, #576803, #528483] 
  [Closes: #495111, #595125, #486352, #433872, #590233] 
* A new length for addressing 
  [Closes: #550725, #549118]
  (http://lkml.org/lkml/2009/11/3/377)
* Support for Kernel Mode Set (KMS) 
  [Closes: #437094, #586674, #547158, #567604]
* Switch to dpkg-source 3.0 (quilt) format
* Compiled without splash support. 
  libsplash is not included in stable, many bugs.
* Moved the manpage file "suspend.conf.8" to manual section 5.
  [Closes: #520705]

[ Anibal Monsalve Salazar ]
* Update uploaders list

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
Suspend to disk HOWTO
2
2
~~~~~~~~~~~~~~~~~~~~~
3
3
Copyright (C) 2006 Pavel Machek <pavel@suse.cz>
4
 
Copyright (C) 2006 Rafael J. Wysocki <rjw@sisk.pl>
 
4
Copyright (C) 2006-2011 Rafael J. Wysocki <rjw@sisk.pl>
5
5
 
6
6
 
7
7
I. Quick start
118
118
                          udev, this option should not be needed)
119
119
  --enable-splashy        Enable splashy support
120
120
  --enable-fbsplash       Enable fbsplash support
 
121
  --enable-threads        Enable multithreaded image saving (helps with image
 
122
                          compression and encryption enabled at the same time
 
123
                          if you have 2 or more CPUs)
 
124
  --disable-resume-static Do not link the resume tool statically (this should
 
125
                          be used on openSUSE and other distros putting the
 
126
                          requisite libraries into their initramfs images)
121
127
 
122
128
If you want to generate an initramfs image using the provided script, the
123
129
following options are available:
147
153
 
148
154
(f) Optinally create initramfs image
149
155
 
150
 
- Edit conf/suspend.conf file to reflect the configuration
 
156
- Edit conf/uswsusp.conf file to reflect the configuration
151
157
of your system (please refer to Section II of this document for details).
152
158
 
153
159
[There should be just one resume partition, for now. You'll need at most 1/2
274
280
in the directory where you have placed the sources.
275
281
 
276
282
4) Create the configuration file for the s2disk tool.  Its default name
277
 
is /etc/suspend.conf, but this can be customized by changing CONFIG_FILE
 
283
is /etc/uswsusp.conf, but this can be customized by changing CONFIG_FILE
278
284
in config_parser.h.  It is also possible to specify the configuration file
279
285
name from the command line, by using the -f option, eg.
280
286
 
301
307
max loglevel = <ignored>
302
308
early writeout = <y/n>
303
309
splash = <y/n>
 
310
threads = <y/n>
304
311
 
305
312
The "resume offset" parameter is necessary if a swap file is used for
306
313
suspending.  In such a case the device identified by the "resume device"
355
362
need additional files. See the documentation of your splash system for
356
363
more information.
357
364
 
 
365
The "threads" parameter, if set to 'y', causes s2disk to use 3 threads for
 
366
saving the image, which generally reduces the time necessary to save it
 
367
if both image compression and encryption are used at the same time (one
 
368
thread compresses the image, one thread encrypts it and one writes the
 
369
data to the storage).
 
370
 
358
371
The resume tool can use the same configuration file that is used by the
359
372
s2disk tool, but it will ignore most of the above parameters.  It will use the
360
373
value of "suspend loglevel" as the kernel console loglevel during resume.
369
382
for it explicitly.
370
383
 
371
384
In order to create the configuration file for s2disk and/or resume, it is
372
 
recommended to edit the file suspend.conf in the conf/ subdirectory of the
 
385
recommended to edit the file uswsusp.conf in the conf/ subdirectory of the
373
386
package source.  Then this file will be automatically placed in /etc and
374
387
in the resume initrd file by scripts provided in this package.
375
388
 
486
499
(j) Put the configuration file for the resume tool in the etc directory on
487
500
the initrd filesystem, eg.
488
501
 
489
 
# cp /etc/suspend.conf /mnt/etc/
 
502
# cp /etc/uswsusp.conf /mnt/etc/
490
503
 
491
504
(k) Unmount the initrd filesystem and move the file containing it to your /boot
492
505
directory, eg.
514
527
        TEMPLATE resume
515
528
        BEGIN
516
529
                FILE "/usr/local/sbin/resume"
517
 
                FILE "/etc/suspend.conf"
 
530
                FILE "/etc/uswsusp.conf"
518
531
                SCRIPT "/init"
519
532
                BEGIN
520
533
                        !if [ -z "$noresume" ]
589
602
 
590
603
For this purpose you need to generate the RSA key pair using the
591
604
suspend-keygen tool provided along with the s2disk and resume tools.  The
592
 
output file of suspend-keygen should be saved as /etc/suspend.key (or
 
605
output file of suspend-keygen should be saved as /etc/uswsusp.key (or
593
606
something else pointed to by the "RSA key file =" configuration  parameter of
594
607
s2disk).  This file contains the public modulus (n), public exponent (e), the
595
608
AES-encrypted private exponent (d), the AES-encrypted primes (p), (q) and
607
620
for the passphrase needed to decrypt (d, p, q, u).  Next, if the user provides
608
621
the right passphrase, the resume tool will decrypt (k, i) needed for decrypting
609
622
the image.
 
623