##// END OF EJS Templates
README.md fix, rm-lost-file
Jan Wagner -
r74:d4ab3cfce58c
parent child
Show More
@@ -1,240 +1,240
1 # rpi2-gen-image
1 # rpi2-gen-image
2 ## Introduction
2 ## Introduction
3 `rpi2-gen-image.sh` is an advanced Debian Linux bootstrapping shell script for generating Debian OS images for the Raspberry 2 (RPi2) computer. The script at this time only supports the bootstrapping of the current stable Debian 8 "jessie" release.
3 `rpi2-gen-image.sh` is an advanced Debian Linux bootstrapping shell script for generating Debian OS images for the Raspberry 2 (RPi2) computer. The script at this time only supports the bootstrapping of the current stable Debian 8 "jessie" release.
4
4
5 ## Build dependencies
5 ## Build dependencies
6 The following list of Debian packages must be installed on the build system because they are essentially required for the bootstrapping process. The script will check if all required packages are installed and missing packages will be installed automatically if confirmed by the user.
6 The following list of Debian packages must be installed on the build system because they are essentially required for the bootstrapping process. The script will check if all required packages are installed and missing packages will be installed automatically if confirmed by the user.
7
7
8 ```debootstrap debian-archive-keyring qemu-user-static binfmt-support dosfstools rsync bmap-tools whois git-core```
8 ```debootstrap debian-archive-keyring qemu-user-static binfmt-support dosfstools rsync bmap-tools whois git-core```
9
9
10 ## Command-line parameters
10 ## Command-line parameters
11 The script accepts certain command-line parameters to enable or disable specific OS features, services and configuration settings. These parameters are passed to the `rpi2-gen-image.sh` script via (simple) shell-variables. Unlike environment shell-variables (simple) shell-variables are defined at the beginning of the command-line call of the `rpi2-gen-image.sh` script.
11 The script accepts certain command-line parameters to enable or disable specific OS features, services and configuration settings. These parameters are passed to the `rpi2-gen-image.sh` script via (simple) shell-variables. Unlike environment shell-variables (simple) shell-variables are defined at the beginning of the command-line call of the `rpi2-gen-image.sh` script.
12
12
13 #####Command-line examples:
13 #####Command-line examples:
14 ```shell
14 ```shell
15 ENABLE_UBOOT=true ./rpi2-gen-image.sh
15 ENABLE_UBOOT=true ./rpi2-gen-image.sh
16 ENABLE_CONSOLE=false ENABLE_IPV6=false ./rpi2-gen-image.sh
16 ENABLE_CONSOLE=false ENABLE_IPV6=false ./rpi2-gen-image.sh
17 ENABLE_WM=xfce4 ENABLE_FBTURBO=true ENABLE_MINBASE=true ./rpi2-gen-image.sh
17 ENABLE_WM=xfce4 ENABLE_FBTURBO=true ENABLE_MINBASE=true ./rpi2-gen-image.sh
18 ENABLE_HARDNET=true ENABLE_IPTABLES=true /rpi2-gen-image.sh
18 ENABLE_HARDNET=true ENABLE_IPTABLES=true /rpi2-gen-image.sh
19 APT_SERVER=ftp.de.debian.org APT_PROXY="http://127.0.0.1:3142/" ./rpi2-gen-image.sh
19 APT_SERVER=ftp.de.debian.org APT_PROXY="http://127.0.0.1:3142/" ./rpi2-gen-image.sh
20 ENABLE_MINBASE=true ./rpi2-gen-image.sh
20 ENABLE_MINBASE=true ./rpi2-gen-image.sh
21 BUILD_KERNEL=true ENABLE_MINBASE=true ENABLE_IPV6=false ./rpi2-gen-image.sh
21 BUILD_KERNEL=true ENABLE_MINBASE=true ENABLE_IPV6=false ./rpi2-gen-image.sh
22 BUILD_KERNEL=true KERNEL_SRCDIR=/tmp/linux ./rpi2-gen-image.sh
22 BUILD_KERNEL=true KERNEL_SRCDIR=/tmp/linux ./rpi2-gen-image.sh
23 ENABLE_MINBASE=true ENABLE_REDUCE=true ENABLE_MINGPU=true BUILD_KERNEL=true ./rpi2-gen-image.sh
23 ENABLE_MINBASE=true ENABLE_REDUCE=true ENABLE_MINGPU=true BUILD_KERNEL=true ./rpi2-gen-image.sh
24 ```
24 ```
25
25
26 #### APT settings:
26 #### APT settings:
27 ##### `APT_SERVER`="ftp.debian.org"
27 ##### `APT_SERVER`="ftp.debian.org"
28 Set Debian packages server address. Choose a server from the list of Debian worldwide [mirror sites](https://www.debian.org/mirror/list). Using a nearby server will probably speed-up all required downloads within the bootstrapping process.
28 Set Debian packages server address. Choose a server from the list of Debian worldwide [mirror sites](https://www.debian.org/mirror/list). Using a nearby server will probably speed-up all required downloads within the bootstrapping process.
29
29
30 ##### `APT_PROXY`=""
30 ##### `APT_PROXY`=""
31 Set Proxy server address. Using a local Proxy-Cache like `apt-cacher-ng` will speed-up the bootstrapping process because all required Debian packages will only be downloaded from the Debian mirror site once.
31 Set Proxy server address. Using a local Proxy-Cache like `apt-cacher-ng` will speed-up the bootstrapping process because all required Debian packages will only be downloaded from the Debian mirror site once.
32
32
33 ##### `APT_INCLUDES`=""
33 ##### `APT_INCLUDES`=""
34 A comma seperated list of additional packages to be installed during bootstrapping.
34 A comma seperated list of additional packages to be installed during bootstrapping.
35
35
36 #### General system settings:
36 #### General system settings:
37 ##### `HOSTNAME`="rpi2-jessie"
37 ##### `HOSTNAME`="rpi2-jessie"
38 Set system host name. It's recommended that the host name is unique in the corresponding subnet.
38 Set system host name. It's recommended that the host name is unique in the corresponding subnet.
39
39
40 ##### `PASSWORD`="raspberry"
40 ##### `PASSWORD`="raspberry"
41 Set system `root` password. The same password is used for the created user `pi`. It's **STRONGLY** recommended that you choose a custom password.
41 Set system `root` password. The same password is used for the created user `pi`. It's **STRONGLY** recommended that you choose a custom password.
42
42
43 ##### `DEFLOCAL`="en_US.UTF-8"
43 ##### `DEFLOCAL`="en_US.UTF-8"
44 Set default system locale. This setting can also be changed inside the running OS using the `dpkg-reconfigure locales` command. The script variant `minbase` (ENABLE_MINBASE=true) doesn't install `locales`.
44 Set default system locale. This setting can also be changed inside the running OS using the `dpkg-reconfigure locales` command. The script variant `minbase` (ENABLE_MINBASE=true) doesn't install `locales`.
45
45
46 ##### `TIMEZONE`="Europe/Berlin"
46 ##### `TIMEZONE`="Europe/Berlin"
47 Set default system timezone. All available timezones can be found in the `/usr/share/zoneinfo/` directory. This setting can also be changed inside the running OS using the `dpkg-reconfigure tzdata` command.
47 Set default system timezone. All available timezones can be found in the `/usr/share/zoneinfo/` directory. This setting can also be changed inside the running OS using the `dpkg-reconfigure tzdata` command.
48
48
49 ##### `EXPANDROOT`=true
49 ##### `EXPANDROOT`=true
50 Expand the root partition and filesystem automatically on first boot.
50 Expand the root partition and filesystem automatically on first boot.
51
51
52 #### Keyboard settings:
52 #### Keyboard settings:
53 These options are used to configure keyboard layout in `/etc/default/keyboard` for console and Xorg. These settings can also be changed inside the running OS using the `dpkg-reconfigure keyboard-configuration` command.
53 These options are used to configure keyboard layout in `/etc/default/keyboard` for console and Xorg. These settings can also be changed inside the running OS using the `dpkg-reconfigure keyboard-configuration` command.
54
54
55 ##### `XKB_MODEL`=""
55 ##### `XKB_MODEL`=""
56 Set the name of the model of your keyboard type.
56 Set the name of the model of your keyboard type.
57
57
58 ##### `XKB_LAYOUT`=""
58 ##### `XKB_LAYOUT`=""
59 Set the supported keyboard layout(s).
59 Set the supported keyboard layout(s).
60
60
61 ##### `XKB_VARIANT`=""
61 ##### `XKB_VARIANT`=""
62 Set the supported variant(s) of the keyboard layout(s).
62 Set the supported variant(s) of the keyboard layout(s).
63
63
64 ##### `XKB_OPTIONS`=""
64 ##### `XKB_OPTIONS`=""
65 Set extra xkb configuration options.
65 Set extra xkb configuration options.
66
66
67 #### Networking settings (DHCP):
67 #### Networking settings (DHCP):
68 This setting is used to set up networking auto configuration in `/etc/systemd/network/eth.network`.
68 This setting is used to set up networking auto configuration in `/etc/systemd/network/eth.network`.
69
69
70 #####`ENABLE_DHCP`=true
70 #####`ENABLE_DHCP`=true
71 Set the system to use DHCP. This requires an DHCP server.
71 Set the system to use DHCP. This requires an DHCP server.
72
72
73 #### Networking settings (static):
73 #### Networking settings (static):
74 These settings are used to set up a static networking configuration in /etc/systemd/network/eth.network. The following static networking settings are only supported if `ENABLE_DHCP` was set to `false`.
74 These settings are used to set up a static networking configuration in /etc/systemd/network/eth.network. The following static networking settings are only supported if `ENABLE_DHCP` was set to `false`.
75
75
76 #####`NET_ADDRESS`=""
76 #####`NET_ADDRESS`=""
77 Set a static IPv4 or IPv6 address and its prefix, separated by "/", eg. "192.169.0.3/24".
77 Set a static IPv4 or IPv6 address and its prefix, separated by "/", eg. "192.169.0.3/24".
78
78
79 #####`NET_GATEWAY`=""
79 #####`NET_GATEWAY`=""
80 Set the IP address for the default gateway.
80 Set the IP address for the default gateway.
81
81
82 #####`NET_DNS_1`=""
82 #####`NET_DNS_1`=""
83 Set the IP address for the first DNS server.
83 Set the IP address for the first DNS server.
84
84
85 #####`NET_DNS_2`=""
85 #####`NET_DNS_2`=""
86 Set the IP address for the second DNS server.
86 Set the IP address for the second DNS server.
87
87
88 #####`NET_DNS_DOMAINS`=""
88 #####`NET_DNS_DOMAINS`=""
89 Set the default DNS search domains to use for non fully qualified host names.
89 Set the default DNS search domains to use for non fully qualified host names.
90
90
91 #####`NET_NTP_1`=""
91 #####`NET_NTP_1`=""
92 Set the IP address for the first NTP server.
92 Set the IP address for the first NTP server.
93
93
94 #####`NET_NTP_2`=""
94 #####`NET_NTP_2`=""
95 Set the IP address for the second NTP server.
95 Set the IP address for the second NTP server.
96
96
97 #### Basic system features:
97 #### Basic system features:
98 ##### `ENABLE_CONSOLE`=true
98 ##### `ENABLE_CONSOLE`=true
99 Enable serial console interface. Recommended if no monitor or keyboard is connected to the RPi2. In case of problems fe. if the network (auto) configuration failed - the serial console can be used to access the system.
99 Enable serial console interface. Recommended if no monitor or keyboard is connected to the RPi2. In case of problems fe. if the network (auto) configuration failed - the serial console can be used to access the system.
100
100
101 ##### `ENABLE_IPV6`=true
101 ##### `ENABLE_IPV6`=true
102 Enable IPv6 support. The network interface configuration is managed via systemd-networkd.
102 Enable IPv6 support. The network interface configuration is managed via systemd-networkd.
103
103
104 ##### `ENABLE_SSHD`=true
104 ##### `ENABLE_SSHD`=true
105 Install and enable OpenSSH service. The default configuration of the service doesn't allow `root` to login. Please use the user `pi` instead and `su -` or `sudo` to execute commands as root.
105 Install and enable OpenSSH service. The default configuration of the service doesn't allow `root` to login. Please use the user `pi` instead and `su -` or `sudo` to execute commands as root.
106
106
107 ##### `ENABLE_RSYSLOG`=true
107 ##### `ENABLE_RSYSLOG`=true
108 If set to false, disable and uninstall rsyslog (so logs will be available only
108 If set to false, disable and uninstall rsyslog (so logs will be available only
109 in journal files)
109 in journal files)
110
110
111 ##### `ENABLE_SOUND`=true
111 ##### `ENABLE_SOUND`=true
112 Enable sound hardware and install Advanced Linux Sound Architecture.
112 Enable sound hardware and install Advanced Linux Sound Architecture.
113
113
114 ##### `ENABLE_HWRANDOM`=true
114 ##### `ENABLE_HWRANDOM`=true
115 Enable Hardware Random Number Generator. Strong random numbers are important for most network based communications that use encryption. It's recommended to be enabled.
115 Enable Hardware Random Number Generator. Strong random numbers are important for most network based communications that use encryption. It's recommended to be enabled.
116
116
117 ##### `ENABLE_MINGPU`=false
117 ##### `ENABLE_MINGPU`=false
118 Minimize the amount of shared memory reserved for the GPU. It doesn't seem to be possible to fully disable the GPU.
118 Minimize the amount of shared memory reserved for the GPU. It doesn't seem to be possible to fully disable the GPU.
119
119
120 ##### `ENABLE_DBUS`=true
120 ##### `ENABLE_DBUS`=true
121 Install and enable D-Bus message bus. Please note that systemd should work without D-bus but it's recommended to be enabled.
121 Install and enable D-Bus message bus. Please note that systemd should work without D-bus but it's recommended to be enabled.
122
122
123 ##### `ENABLE_XORG`=false
123 ##### `ENABLE_XORG`=false
124 Install Xorg open-source X Window System.
124 Install Xorg open-source X Window System.
125
125
126 ##### `ENABLE_WM`=""
126 ##### `ENABLE_WM`=""
127 Install a user defined window manager for the X Window System. To make sure all X related package dependencies are getting installed `ENABLE_XORG` will automatically get enabled if `ENABLE_WM` is used. The `rpi2-gen-image.sh` script has been tested with the following list of window managers: `blackbox`, `openbox`, `fluxbox`, `jwm`, `dwm`, `xfce4`, `awesome`.
127 Install a user defined window manager for the X Window System. To make sure all X related package dependencies are getting installed `ENABLE_XORG` will automatically get enabled if `ENABLE_WM` is used. The `rpi2-gen-image.sh` script has been tested with the following list of window managers: `blackbox`, `openbox`, `fluxbox`, `jwm`, `dwm`, `xfce4`, `awesome`.
128
128
129 #### Advanced system features:
129 #### Advanced system features:
130 ##### `ENABLE_MINBASE`=false
130 ##### `ENABLE_MINBASE`=false
131 Use debootstrap script variant `minbase` which only includes essential packages and apt. This will reduce the disk usage by about 65 MB.
131 Use debootstrap script variant `minbase` which only includes essential packages and apt. This will reduce the disk usage by about 65 MB.
132
132
133 ##### `ENABLE_REDUCE`=false
133 ##### `ENABLE_REDUCE`=false
134 Reduce the disk usage by deleting all man pages and doc files (harsh). APT will be configured to use compressed package repository lists and no package caching files. If `ENABLE_MINGPU`=true unnecessary start.elf and fixup.dat files will also be removed from the boot partition. This will make it possible to generate output OS images with about 160MB of used disk space. It's recommended to use this parameter in combination with `ENABLE_MINBASE`=true.
134 Reduce the disk usage by deleting all man pages and doc files (harsh). APT will be configured to use compressed package repository lists and no package caching files. If `ENABLE_MINGPU`=true unnecessary start.elf and fixup.dat files will also be removed from the boot partition. This will make it possible to generate output OS images with about 160MB of used disk space. It's recommended to use this parameter in combination with `ENABLE_MINBASE`=true.
135
135
136 ##### `ENABLE_UBOOT`=false
136 ##### `ENABLE_UBOOT`=false
137 Replace default RPi2 second stage bootloader (bootcode.bin) with U-Boot bootloader. U-Boot can boot images via the network using the BOOTP/TFTP protocol.
137 Replace default RPi2 second stage bootloader (bootcode.bin) with U-Boot bootloader. U-Boot can boot images via the network using the BOOTP/TFTP protocol.
138
138
139 ##### `ENABLE_FBTURBO`=false
139 ##### `ENABLE_FBTURBO`=false
140 Install and enable the hardware accelerated Xorg video driver `fbturbo`. Please note that this driver is currently limited to hardware accelerated window moving and scrolling.
140 Install and enable the hardware accelerated Xorg video driver `fbturbo`. Please note that this driver is currently limited to hardware accelerated window moving and scrolling.
141
141
142 ##### `ENABLE_IPTABLES`=false
142 ##### `ENABLE_IPTABLES`=false
143 Enable iptables IPv4/IPv6 firewall. Simplified ruleset: Allow all outgoing connections. Block all incoming connections except to OpenSSH service.
143 Enable iptables IPv4/IPv6 firewall. Simplified ruleset: Allow all outgoing connections. Block all incoming connections except to OpenSSH service.
144
144
145 ##### `ENABLE_USER`=true
145 ##### `ENABLE_USER`=true
146 Create pi user with password raspberry
146 Create pi user with password raspberry
147
147
148 ##### `ENABLE_ROOT`=true
148 ##### `ENABLE_ROOT`=true
149 Set root user password so root login will be enabled
149 Set root user password so root login will be enabled
150
150
151 ##### `ENABLE_ROOT_SSH`=true
151 ##### `ENABLE_ROOT_SSH`=true
152 Enable password root login via SSH. May be a security risk with default
152 Enable password root login via SSH. May be a security risk with default
153 password, use only in trusted environments.
153 password, use only in trusted environments.
154
154
155 ##### `ENABLE_HARDNET`=false
155 ##### `ENABLE_HARDNET`=false
156 Enable IPv4/IPv6 network stack hardening settings.
156 Enable IPv4/IPv6 network stack hardening settings.
157
157
158 ##### `ENABLE_SPLITFS`=false
158 ##### `ENABLE_SPLITFS`=false
159 Enable having root partition on an USB drive by creating two image files: one for the `/boot/firmware` mount point, and another for `/`.
159 Enable having root partition on an USB drive by creating two image files: one for the `/boot/firmware` mount point, and another for `/`.
160
160
161 ##### `CHROOT_SCRIPTS`=""
161 ##### `CHROOT_SCRIPTS`=""
162 Path to a directory with scripts that should be run in the chroot before the image is finally built. Every executable file in this direcory is run in lexicographical order.
162 Path to a directory with scripts that should be run in the chroot before the image is finally built. Every executable file in this direcory is run in lexicographical order.
163
163
164 #### Kernel compilation:
164 #### Kernel compilation:
165 ##### `BUILD_KERNEL`=false
165 ##### `BUILD_KERNEL`=false
166 Build and install the latest RPi2 Linux kernel. Currently only the default RPi2 kernel configuration is used. Detailed configuration parameters for customizing the kernel and minor bug fixes still need to get implemented. feel free to help.
166 Build and install the latest RPi2 Linux kernel. Currently only the default RPi2 kernel configuration is used. Detailed configuration parameters for customizing the kernel and minor bug fixes still need to get implemented. feel free to help.
167
167
168 ##### `KERNEL_SRCDIR`=""
168 ##### `KERNEL_SRCDIR`=""
169 Path to a directory of [RaspberryPi Linux kernel] sources (https://github.com/raspberrypi/linux) that will be copied, configured, build and installed inside the chroot.
169 Path to a directory of [RaspberryPi Linux kernel sources](https://github.com/raspberrypi/linux) that will be copied, configured, build and installed inside the chroot.
170
170
171 ##### `KERNEL_THREADS`=1
171 ##### `KERNEL_THREADS`=1
172 Number of parallel kernel building threads. If the parameter is left untouched the script will automatically determine the number of CPU cores to set the number of parallel threads to speed the kernel compilation.
172 Number of parallel kernel building threads. If the parameter is left untouched the script will automatically determine the number of CPU cores to set the number of parallel threads to speed the kernel compilation.
173
173
174 ##### `KERNEL_HEADERS`=true
174 ##### `KERNEL_HEADERS`=true
175 Install kernel headers with built kernel.
175 Install kernel headers with built kernel.
176
176
177 ##### `KERNEL_MENUCONFIG`=false
177 ##### `KERNEL_MENUCONFIG`=false
178 Start `make menuconfig` interactive menu-driven kernel configuration. The script will continue after `make menuconfig` was terminated.
178 Start `make menuconfig` interactive menu-driven kernel configuration. The script will continue after `make menuconfig` was terminated.
179
179
180 ##### `KERNEL_CONFIGSRC`=true
180 ##### `KERNEL_CONFIGSRC`=true
181 Run `make bcm2709_defconfig` (and optional `make menuconfig`) to configure the kernel sources before building. This setting is automatically set to `true` if no existing kernel sources directory was specified using `KERNEL_SRCDIR`.
181 Run `make bcm2709_defconfig` (and optional `make menuconfig`) to configure the kernel sources before building. This setting is automatically set to `true` if no existing kernel sources directory was specified using `KERNEL_SRCDIR`.
182
182
183 ##### `KERNEL_CLEANSRC`=false
183 ##### `KERNEL_CLEANSRC`=false
184 Clean the existing kernel sources directory `KERNEL_SRCDIR` (using `make mrproper`) after it was copied to the chroot and before the compilation of the kernel has started. This setting will be ignored if no `KERNEL_SRCDIR` was specified.
184 Clean the existing kernel sources directory `KERNEL_SRCDIR` (using `make mrproper`) after it was copied to the chroot and before the compilation of the kernel has started. This setting will be ignored if no `KERNEL_SRCDIR` was specified.
185
185
186 ##### `KERNEL_RMSRC`=true
186 ##### `KERNEL_RMSRC`=true
187 Remove all kernel sources from the generated OS image after it was built and installed.
187 Remove all kernel sources from the generated OS image after it was built and installed.
188
188
189 ## Understanding the script
189 ## Understanding the script
190 The functions of this script that are required for the different stages of the bootstrapping are split up into single files located inside the `bootstrap.d` directory. During the bootstrapping every script in this directory gets executed in lexicographical order:
190 The functions of this script that are required for the different stages of the bootstrapping are split up into single files located inside the `bootstrap.d` directory. During the bootstrapping every script in this directory gets executed in lexicographical order:
191
191
192 | Script | Description |
192 | Script | Description |
193 | --- | --- |
193 | --- | --- |
194 | `10-bootstrap.sh` | Debootstrap basic system |
194 | `10-bootstrap.sh` | Debootstrap basic system |
195 | `11-apt.sh` | Setup APT repositories |
195 | `11-apt.sh` | Setup APT repositories |
196 | `12-locale.sh` | Setup Locales and keyboard settings |
196 | `12-locale.sh` | Setup Locales and keyboard settings |
197 | `13-kernel.sh` | Build and install RPi2 Kernel |
197 | `13-kernel.sh` | Build and install RPi2 Kernel |
198 | `20-networking.sh` | Setup Networking |
198 | `20-networking.sh` | Setup Networking |
199 | `21-firewall.sh` | Setup Firewall |
199 | `21-firewall.sh` | Setup Firewall |
200 | `30-security.sh` | Setup Users and Security settings |
200 | `30-security.sh` | Setup Users and Security settings |
201 | `31-logging.sh` | Setup Logging |
201 | `31-logging.sh` | Setup Logging |
202 | `41-uboot.sh` | Build and Setup U-Boot |
202 | `41-uboot.sh` | Build and Setup U-Boot |
203 | `42-fbturbo.sh` | Build and Setup fbturbo Xorg driver |
203 | `42-fbturbo.sh` | Build and Setup fbturbo Xorg driver |
204 | `50-firstboot.sh` | First boot actions |
204 | `50-firstboot.sh` | First boot actions |
205
205
206 All the required configuration files that will be copied to the generated OS image are located inside the `files` directory. It is not recommended to modify these configuration files manually.
206 All the required configuration files that will be copied to the generated OS image are located inside the `files` directory. It is not recommended to modify these configuration files manually.
207
207
208 | Directory | Description |
208 | Directory | Description |
209 | --- | --- |
209 | --- | --- |
210 | `boot` | Boot and RPi2 configuration files |
210 | `boot` | Boot and RPi2 configuration files |
211 | `dpkg` | Package Manager configuration |
211 | `dpkg` | Package Manager configuration |
212 | `firstboot` | Scripts that get executed on first boot |
212 | `firstboot` | Scripts that get executed on first boot |
213 | `iptables` | Firewall configuration files |
213 | `iptables` | Firewall configuration files |
214 | `locales` | Locales configuration |
214 | `locales` | Locales configuration |
215 | `modules` | Kernel Modules configuration |
215 | `modules` | Kernel Modules configuration |
216 | `mount` | Fstab configuration |
216 | `mount` | Fstab configuration |
217 | `network` | Networking configuration files |
217 | `network` | Networking configuration files |
218 | `sysctl.d` | Swapping and Network Hardening configuration |
218 | `sysctl.d` | Swapping and Network Hardening configuration |
219 | `xorg` | fbturbo Xorg driver configuration |
219 | `xorg` | fbturbo Xorg driver configuration |
220
220
221 ## Logging of the bootstrapping process
221 ## Logging of the bootstrapping process
222 All information related to the bootstrapping process and the commands executed by the `rpi2-gen-image.sh` script can easily be saved into a logfile. The common shell command `script` can be used for this purpose:
222 All information related to the bootstrapping process and the commands executed by the `rpi2-gen-image.sh` script can easily be saved into a logfile. The common shell command `script` can be used for this purpose:
223
223
224 ```shell
224 ```shell
225 script -c 'APT_SERVER=ftp.de.debian.org ./rpi2-gen-image.sh' ./build.log
225 script -c 'APT_SERVER=ftp.de.debian.org ./rpi2-gen-image.sh' ./build.log
226 ```
226 ```
227
227
228 ## Flashing the image file
228 ## Flashing the image file
229 After the image file was successfully created by the `rpi2-gen-image.sh` script it can be copied to the microSD card that will be used by the RPi2 computer. This can be performed by using the tools `bmaptool` or `dd`. Using `bmaptool` will probably speed-up the copy process because `bmaptool` copies more wisely than `dd`.
229 After the image file was successfully created by the `rpi2-gen-image.sh` script it can be copied to the microSD card that will be used by the RPi2 computer. This can be performed by using the tools `bmaptool` or `dd`. Using `bmaptool` will probably speed-up the copy process because `bmaptool` copies more wisely than `dd`.
230
230
231 #####Flashing examples:
231 #####Flashing examples:
232 ```shell
232 ```shell
233 bmaptool copy ./images/jessie/2015-12-13-debian-jessie.img /dev/mmcblk0
233 bmaptool copy ./images/jessie/2015-12-13-debian-jessie.img /dev/mmcblk0
234 dd bs=4M if=./images/jessie/2015-12-13-debian-jessie.img of=/dev/mmcblk0
234 dd bs=4M if=./images/jessie/2015-12-13-debian-jessie.img of=/dev/mmcblk0
235 ```
235 ```
236 If you have set `ENABLE_SPLITFS`, copy the `-frmw` image on the microSD card, then the `-root` one on the USB drive:
236 If you have set `ENABLE_SPLITFS`, copy the `-frmw` image on the microSD card, then the `-root` one on the USB drive:
237 ```shell
237 ```shell
238 bmaptool copy ./images/jessie/2015-12-13-debian-jessie-frmw.img /dev/mmcblk0
238 bmaptool copy ./images/jessie/2015-12-13-debian-jessie-frmw.img /dev/mmcblk0
239 bmaptool copy ./images/jessie/2015-12-13-debian-jessie-root.img /dev/sdc
239 bmaptool copy ./images/jessie/2015-12-13-debian-jessie-root.img /dev/sdc
240 ```
240 ```
1 NO CONTENT: file was removed
NO CONTENT: file was removed
General Comments 0
Vous devez vous connecter pour laisser un commentaire. Se connecter maintenant