File: README

package info (click to toggle)
lowmem 1.07
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 68 kB
  • ctags: 14
  • sloc: ansic: 113; sh: 93; makefile: 39
file content (81 lines) | stat: -rw-r--r-- 3,253 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
This package is, frankly, a collection of hacks, hung on a reasonable
framework to which you can add more hacks to save memory. The memory saving
hacks are divided into four groups, which run at different times:
initialisation, post anna run, and pre partitioning.

Initialisation hacks are in the debian-installer-startup.d/*lowmem script,
in the lowmemcheck package. The is what decides if the system is low on
memory, and it creates /var/lib/lowmem as a flag indicating the system
should be in lowmem mode. Other hacks test for this file. There are
actually different low memory levels, as determined by the number in the
file. 1 is standard low memory mode, 2 turns on additional lowmem hacks
that can make the installation more difficult for the user.

Post anna run hacks are in the lowmem package, which is queued for install
by anna on lowmem systems, and provides a menu item.

Pre partitioning hacks are also in the lowmem package, and are run as
the partitioner is starting up.

Current hacks:

	disable framebuffer
		Running w/o framebuffer saves lots of memory. The unifont.bgf
		is also removed, saving much ram.

	remove translations, force English
		Happens at both init, and also trimtemplates is called by
		udpkg when unpacking packages.

		Saves a significant, but not huge amount of memory.

	truncate log files
		Happens after anna run. By now the log files may be rather
		large, and so this truncates them and restarts the tails.

		Saves a few hundred K of memory, at the expense of
		diagnostics.

	remove debconf templates after load
		This is done at initialisation by rootskel. After
		initialisation, udpkg takes care of it. It's not in lowmem,
		because this is a safe, simple trick that's worth doing on
		even systems with lots of memory.

		Saves a few hundred K of memory.
	
	allow user more control over what udebs are loaded
		This hack is enabled in level 2 lowmem mode. It makes anna
		not install standard priority udebs by default, and the
		user can choose which to install. Careful selection by the
		user can allow for installs with as little as 24 mb or
		memory.

	remove all keymaps
		After keyboard is selected, not needed. Done post-anna.
	
	remove selected modules
		Pre partitioning, only kernel modules for filesystems,
		raid, lvm, and the like are needed anymore. This hack
		deletes some other modules to save memory. This frees
		up several megabytes for the partitioner to run in, but
		unfortuantly runs too late (after all these udebs are
		unpacked to the initrd) to reduce the overall amount of
		memory needed to install by more than the memory footprint
		of the partitioner. Therefore, removing even more modules
		at this point is not likely to help save any more memory.
	
Possible future hacks:

	progressive udeb installation
		Modify anna so it can install udebs on demand. Allows some
		udebs to be loaded after partitioning has enabled swap.

	find swap partitions and auto-swapon
		Try to scan disks for existing swap partitions and swapon.
		This will make later partitioning a bit more difficult, and
		requires a previous install.
	
	let user choose a partition to use as swap
		Scan disks for existing small-ish partitions, list them,
		and offer to turn them into swap space.