@@ -28,67 +28,39 @@ the network:
2828
2929 .. code :: bash
3030
31- $ mount {exc_image_base_name }.x86_64-{exc_image_version}.iso /mnt
32- $ cp /mnt/boot/x86_64/loader/initrd /srv/tftpboot/boot/initrd
33- $ cp /mnt/boot/x86_64/loader/linux /srv/tftpboot/boot/linux
34- $ umount /mnt
31+ $ mount {exc_image_base_name_live }.x86_64-{exc_image_version}.iso /mnt
32+ $ cp /mnt/boot/x86_64/loader/initrd /srv/tftpboot/boot/initrd
33+ $ cp /mnt/boot/x86_64/loader/linux /srv/tftpboot/boot/linux
34+ $ umount /mnt
3535
3636 .. note ::
3737
38- This step must be repeated with any new build of the live ISO image
38+ This step must be repeated with any new build of the live ISO image
3939
40402. Export Live ISO To The Network
4141
42- Access to the live ISO file is implemented using the AoE protocol
43- in {kiwi}. This requires the export of the live ISO file as remote
44- block device which is typically done with the :command: `vblade `
45- toolkit. Install the following package on the system which is
46- expected to export the live ISO image:
42+ Access to the live ISO file must be provided by either `ftp `,
43+ `http `, `https ` or `dolly `. The most simple method is to setup a FTP server
44+ e.g. `vsftpd ` and copy the live ISO file to the data directory:
4745
4846 .. code :: bash
4947
50- $ zypper in vblade
48+ $ mkdir -p /srv/ftp/image
49+ $ cp {exc_image_base_name_live}.x86_64-{exc_image_version}.iso /srv/ftp/image
5150
5251 .. note ::
5352
54- Not all versions of AoE are compatible with any kernel. This
55- means the kernel on the system exporting the live ISO image
56- must provide a compatible aoe kernel module compared to the
57- kernel used in the live ISO image.
58-
59- Once done, export the live ISO image as follows:
60-
61- .. code :: bash
62-
63- $ vbladed 0 1 INTERFACE {exc_image_base_name}.x86_64-{exc_image_version}.iso
64-
65- The above command exports the given ISO file as a block storage
66- device to the network of the given INTERFACE. On any machine
67- except the one exporting the file, it will appear as
68- :file: `/dev/etherd/e0.1 ` once the :command: `aoe ` kernel module
69- was loaded. The two numbers, 0 and 1 in the above example, classifies
70- a major and minor number which is used in the device node name
71- on the reading side, in this case :file: `e0.1 `. The numbers given
72- at export time must match the AOEINTERFACE name as described in
73- the next step.
74-
75- .. note ::
76-
77- Only machines in the same network of the given INTERFACE
78- can see the exported live ISO image. If virtual machines
79- are the target to boot the live ISO image they could all
80- be connected through a bridge. In this case INTERFACE
81- is the bridge device. The availability scope of the live
82- ISO image on the network is in general not influenced
83- by {kiwi} and is a task for the network administrators.
53+ Check if the image can be downloaded via:
54+ `wget ftp://IP/image/{exc_image_base_name_live}.x86_64-{exc_image_version}.iso `
55+ before the next step.
8456
85573. Setup live ISO boot entry in PXE configuration
8658
8759 .. note ::
8860
89- The following step assumes that the pxelinux.0 loader
90- has been configured on the boot server to boot up network
91- clients
61+ The following step assumes that the pxelinux.0 loader
62+ has been configured on the boot server to boot up network
63+ clients
9264
9365 Edit the file :file: `/srv/tftpboot/pxelinux.cfg/default ` and create
9466 a boot entry of the form:
@@ -97,22 +69,91 @@ the network:
9769
9870 LABEL Live-Boot
9971 kernel boot/linux
100- append initrd=boot/initrd rd.kiwi.live.pxe root=live:AOEINTERFACE=e0.1
72+ append initrd=boot/initrd ip=dhcp root=live:ftp://IP/image/{exc_image_base_name_live}.x86_64-{exc_image_version}.iso
10173
102- * The boot parameter `rd.kiwi.live.pxe ` tells the {kiwi} boot process to
103- setup the network and to load the required :mod: `aoe ` kernel module.
74+ * The `ip= ` parameter controls how the dracut network module sets up
75+ the network. Several options exists to control how the network
76+ interface should be setup. Please consult the dracut manual
77+ for further information.
10478
105- * The boot parameter `root=live:AOEINTERFACE=e0.1 ` specifies the
106- interface name as it was exported by the :command: `vbladed ` command
107- from the last step. Currently only AoE (Ata Over Ethernet)
108- is supported.
79+ * The boot parameter `root=live:PROTOCOL://IP/PATH... ` specifies the
80+ remote endpoint and protocol to find the live ISO file. So far
81+ `ftp `, `http `, `https ` and `dolly ` are supported.
10982
110834. Boot from the Network
11184
11285 Within the network which has access to the PXE server and the
113- exported live ISO image , any network client can now boot the
86+ IP in the root= option , any network client can now boot the
11487 live system. A test based on QEMU is done as follows:
11588
11689 .. code :: bash
11790
118- $ sudo qemu -boot n
91+ $ qemu -boot n
92+
93+ Available Remote Boot Options
94+ -----------------------------
95+
96+ There are the following kernel boot options available to control
97+ the behavior of the remote boot process.
98+
99+ rd.kiwi.live.curl_options=
100+ Options passed along to the curl call
101+
102+ rd.kiwi.live.dolly_options=
103+ Options passed along to the dolly call
104+
105+ rd.kiwi.live.system=
106+ Block device to use for the system. By default this is set to `/dev/ram0 `
107+
108+ ramdisk_size=bytes
109+ Size of the ramdisk in bytes. By default this is set to 2097152 (2G)
110+
111+ rd.kiwi.live.reset
112+ Force reset of the live system. This option only makes sense if
113+ the live system device (rd.kiwi.live.system) points to a persistent
114+ storage device. In this case {kiwi} loads the system only once
115+ and does not overwrite it unless a reset is requested.
116+
117+ Persistent Live System
118+ ----------------------
119+
120+ The remote boot process of a live ISO image, places the ISO file
121+ into a ramdisk by default. This means all data lives in memory and
122+ is not persistent. In order to boot up the live system from a remote
123+ location and keep it on a persistent storage, it's required to
124+ pass the `rd.kiwi.live.system ` boot option with the device name
125+ pointing to that persistent storage.
126+
127+ .. warning ::
128+
129+ All data on the device given via `rd.kiwi.live.system ` will be wiped
130+
131+ A test based on QEMU is done as follows:
132+
133+ Edit the file :file: `/srv/tftpboot/pxelinux.cfg/default ` and create
134+ a boot entry of the form:
135+
136+ .. code :: bash
137+
138+ LABEL Live-Boot
139+ kernel boot/linux
140+ append initrd=boot/initrd ip=dhcp root=live:ftp://IP/image/{exc_image_base_name_live}.x86_64-{exc_image_version}.iso ramdisk_size=3545728 rd.kiwi.live.system=/dev/sda rd.live.overlay.persistent rd.live.overlay.cowfs=xfs
141+
142+ * The `rd.live.overlay.persistent ` and `rd.live.overlay.cowfs=xfs `
143+ options are standard {kiwi} live ISO options to control if and how a
144+ persistent write partition should be created. The options only take
145+ an effect when booting into a persistent storage device.
146+
147+ Next create a persistent storage disk of 3G and attach it to the
148+ QEMU instance.
149+
150+ .. code :: bash
151+
152+ $ qemu-img create mydisk.raw 3G
153+ $ qemu -boot n -hda mydisk.raw
154+
155+ The live system will be deployed once to the locally attached disk and
156+ boots from it. Any subsequent boot process will not modify the local
157+ disk unless `rd.kiwi.live.reset ` is passed on the kernel command line.
158+ If deployed there is also no need for the network anymore and the
159+ system could also boot standalone.
0 commit comments