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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
|
.TH DEBOOTSTRAP 8 2001-04-27 "Debian Project" "Debian GNU/Linux manual"
.SH NAME
debootstrap \- Bootstrap a basic Debian system
.SH SYNOPSIS
.B debootstrap
.RB [ OPTION\&.\&.\&. ]
.I SUITE TARGET
.RI [ MIRROR
.RI [ SCRIPT ]]
.B debootstrap
.RB [ OPTION\&.\&.\&. ]
\-\-second\-stage
.SH DESCRIPTION
.B debootstrap
bootstraps a basic Debian system of
.I SUITE
into
.I TARGET
from
.I MIRROR
by running
.IR SCRIPT .
.I MIRROR
can be an http:// or https:// URL, a file:/// URL, or an ssh:/// URL.
.PP
The
.I SUITE
may be a release code name (eg, sid, stretch, jessie)
or a symbolic name (eg, unstable, testing, stable, oldstable)
.PP
Notice that file:/ URLs are translated to file:/// (correct scheme as
described in RFC1738 for local filenames), and file:// will \fBnot\fR work.
ssh://USER@HOST/PATH URLs are retrieved using
.BR scp ;
use of
.B ssh\-agent
or similar is strongly recommended.
.PP
\fBDebootstrap\fR can be used to install Debian in a system without using an
installation disk but can also be used to run a different Debian flavor in a \fBchroot\fR
environment.
This way you can create a full (minimal) Debian installation which
can be used for testing purposes (see the \fBEXAMPLES\fR section).
If you are looking for a chroot system to build packages please take a look at
\fBpbuilder\fR.
.SH "OPTIONS"
.PP
.IP "\fB\-\-arch=ARCH\fP"
Set the target architecture (use if dpkg isn't installed).
See also \-\-foreign.
.IP
.IP "\fB\-\-include=alpha,beta\fP"
Comma separated list of packages which will be added to download and extract
lists.
.IP
.IP "\fB\-\-exclude=alpha,beta\fP"
Comma separated list of packages which will be removed from download and
extract lists.
WARNING: you can and probably will exclude essential packages, be
careful using this option.
.IP
.IP "\fB\-\-extra-suites=alpha,beta\fP"
Also use packages from the listed suites of the archive.
.IP
.IP "\fB\-\-components=alpha,beta\fP"
Use packages from the listed components of the archive.
.IP
.IP "\fB\-\-no\-resolve\-deps\fP"
By default, debootstrap will attempt to automatically resolve any missing
dependencies, warning if any are found.
Note that this is not a complete dependency resolve in the sense of dpkg
or apt, and that it is far better to specify the entire base system than
rely on this option.
With this option set, this behaviour is disabled.
.IP
.IP "\fB\-\-log\-extra\-deps\fP"
If you want to record additional dependencies when resolving package dependencies,
set this option to track them through debootstrap.log.
.IP
.IP "\fB\-\-variant=minbase|buildd|fakechroot\fP"
Name of the bootstrap script variant to use.
Currently, the variants supported are minbase, which only includes
\fIrequired\fR packages and apt; buildd, which installs the build-essential
packages and fakechroot, which installs the packages without root privileges.
The default, with no \fB\-\-variant=X\fP argument, is to create a
base Debian installation with all packages of priority \fIrequired\fR and
\fIimportant\fR, including apt.
.IP
.IP "\fB\-\-merged-usr\fP"
Create /{bin,sbin,lib}/ symlinks pointing to their counterparts in /usr/.
(Default for most variants and suites.)
.IP
.IP "\fB\-\-no-merged-usr\fP"
Do not create /{bin,sbin,lib}/ symlinks pointing to their counterparts in /usr/.
(Default for the buildd variant of Debian 12 'bookworm' or older, and all
variants of Debian 9 'stretch' or older.)
.IP
.IP "\fB\-\-keyring=KEYRING\fP"
Override the default keyring for the distribution being bootstrapped,
and use
.IR KEYRING
to check signatures of retrieved Release files.
.IP
.IP "\fB\-\-no-check-gpg\fP"
Disables checking gpg signatures of retrieved Release files.
.IP
.IP "\fB\-\-force-check-gpg\fP"
Forces checking Release file signatures, disabling automatic fallback to
HTTPS in case of a missing keyring. Incompatible with the previous option.
.IP
.IP "\fB\-\-verbose\fP"
Produce more info about downloading.
.IP
.IP "\fB\-\-print\-debs\fP"
Print the packages to be installed, and exit.
Note that an empty or non-existing TARGET directory must be specified so
that debootstrap can download Packages files to determine which packages
should be installed, and to resolve dependencies. The TARGET directory
will be deleted unless \-\-keep\-debootstrap\-dir is specified.
.IP
.IP "\fB\-\-download\-only\fP"
Download packages, but don't perform installation.
.IP
.IP "\fB\-\-foreign\fP"
Do the initial unpack phase of bootstrapping only, for example if the
target architecture does not match the host architecture.
A copy of debootstrap sufficient for completing the bootstrap process
will be installed as /debootstrap/debootstrap in the target filesystem.
You can run it with the \fB\-\-second\-stage\fP option to complete the
bootstrapping process.
.IP
.IP "\fB\-\-second\-stage\fP"
Complete the bootstrapping process.
Other arguments are generally not needed.
.IP
.IP "\fB\-\-second\-stage\-target=DIR\fP"
Run second stage in a subdirectory instead of root. (can be used to create
a foreign chroot) (requires \-\-second\-stage)
.IP
.IP "\fB\-\-keep\-debootstrap\-dir\fP"
Don't delete the /debootstrap directory in the target after completing the
installation.
.IP
.IP "\fB\-\-cache\-dir=DIR\fP"
Cache .deb files under directory. It should be an absolute path.
.IP
.IP "\fB\-\-unpack\-tarball=FILE\fP"
Acquire .debs from gzipped tarball FILE (specified with absolute path)
instead of downloading via HTTP(S).
.IP
.IP "\fB\-\-make\-tarball=FILE\fP"
Instead of bootstrapping, make a gzipped tarball (written to FILE) of the
downloaded packages.
The resulting tarball may be passed to a later
.BR \-\-unpack\-tarball .
Note that an empty or non-existing TARGET directory must be specified so
that debootstrap can download packages to prepare the tarball. The TARGET
directory will be deleted unless \-\-keep\-debootstrap\-dir is specified.
.IP
.IP "\fB\-\-debian\-installer\fP"
Used for internal purposes by the debian-installer
.IP
.IP "\fB\-\-extractor=TYPE\fP"
Override automatic .deb extractor selection to
.IR TYPE .
Supported extractors are: dpkg-deb and ar.
.IP
.IP "\fB\-\-no\-check\-certificate\fP"
Do not check certificate against certificate authorities
.IP
.IP "\fB\-\-certificate=FILE\fP"
Use the client certificate stored in file (PEM)
.IP
.IP "\fB\-\-private\-key=FILE\fP"
Read the private key from file
.IP
.IP "\fB\-\-inrelease\-path\fP"
Determine the path to the InRelease file of the suite relative to the
normal position of an InRelease file
.IP
.SH EXAMPLES
.
.PP
To setup a \fIstretch\fR system:
.PP
debootstrap stretch ./stretch-chroot http://deb.debian.org/debian
.PP
debootstrap stretch ./stretch-chroot file:///LOCAL_MIRROR/debian
.PP
Full process to create a complete Debian installation of \fIsid\fR (unstable)
in a chroot:
.PP
main # debootstrap sid sid-root http://deb.debian.org/debian/
[ ... watch it download the whole system ]
main # echo "proc sid-root/proc proc defaults 0 0" >> /etc/fstab
main # mount proc sid-root/proc -t proc
main # echo "sysfs sid-root/sys sysfs defaults 0 0" >> /etc/fstab
main # mount sysfs sid-root/sys -t sysfs
main # cp /etc/hosts sid-root/etc/hosts
main # chroot sid-root /bin/bash
.SH AUTHOR
.B debootstrap
was written by Anthony Towns <ajt@debian.org>.
This manpage was written by Matt Kraai <kraai@debian.org>.
|