From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Wed, 13 Oct 2021 20:26:47 +0200 From: Alexey Gladkov To: make-initrd@lists.altlinux.org Message-ID: <20211013182647.cysdajysbqfip6tt@example.org> References: <68c970bd-67be-c1b7-b5d3-b1dfc079d601@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable In-Reply-To: Subject: Re: [make-initrd] [PATCH v4 1/4] Separate new feature of bootchain-core from pipeline X-BeenThere: make-initrd@lists.altlinux.org X-Mailman-Version: 2.1.12 Precedence: list Reply-To: make-initrd@lists.altlinux.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Oct 2021 18:26:48 -0000 Archived-At: List-Archive: On Wed, Oct 13, 2021 at 09:07:23PM +0300, Arseny Maslennikov wrote: > On Wed, Oct 13, 2021 at 08:21:28PM +0300, Leonid Krivoshein wrote: > > From: Leonid Krivoshein > >=20 > > Pipeline live as a add-in over bootchain-core for backward > > compatibility with already existing solutions. > > For bootchain-core it is planned to implement a number of > > new features to cover the tasks of bootloading the installer > > and live systems. > >=20 > > Signed-off-by: Leonid Krivoshein > > --- > > features/bootchain-core/README.md | 81 +++++++++++++++++++ > > features/bootchain-core/config.mk | 8 ++ > > .../data/etc/initrd/cmdline.d/bootchain-core} | 3 +- > > .../data/etc/rc.d/init.d/bootchain} | 8 +- > > .../udev/rules.d/50-bootchain-waitdev.rules} | 2 +- > > .../data/lib/bootchain}/getimage | 2 +- > > .../data/lib/bootchain}/mountfs | 2 +- > > .../data/lib/bootchain}/overlayfs | 2 +- > > .../data/lib/bootchain}/rootfs | 2 +- > > .../data/lib/bootchain}/waitdev | 4 +- > > .../data/lib/initrd/cmdline.d/bootchain | 6 ++ > > .../data/lib/initrd/cmdline.d/pipeline | 2 +- > > .../lib/uevent/filters/bootchain-waitdev} | 4 +- > > .../data/sbin/bootchain-sh-functions} | 12 +-- > > .../data/sbin/bootchained} | 22 ++--- > > features/bootchain-core/rules.mk | 4 + > > features/pipeline/config.mk | 9 +-- > > features/pipeline/rules.mk | 6 -- > > 18 files changed, 133 insertions(+), 46 deletions(-) > > create mode 100644 features/bootchain-core/README.md > > create mode 100644 features/bootchain-core/config.mk > > rename features/{pipeline/data/etc/initrd/cmdline.d/pipeline =3D> > > bootchain-core/data/etc/initrd/cmdline.d/bootchain-core} (63%) > > rename features/{pipeline/data/etc/rc.d/init.d/pipeline =3D> > > bootchain-core/data/etc/rc.d/init.d/bootchain} (83%) > > rename features/{pipeline/data/etc/udev/rules.d/50-pipeline-waitdev.ru= les > > =3D> bootchain-core/data/etc/udev/rules.d/50-bootchain-waitdev.rules} (= 77%) > > rename features/{pipeline/data/lib/pipeline =3D> > > bootchain-core/data/lib/bootchain}/getimage (93%) > > rename features/{pipeline/data/lib/pipeline =3D> > > bootchain-core/data/lib/bootchain}/mountfs (91%) > > rename features/{pipeline/data/lib/pipeline =3D> > > bootchain-core/data/lib/bootchain}/overlayfs (95%) > > rename features/{pipeline/data/lib/pipeline =3D> > > bootchain-core/data/lib/bootchain}/rootfs (86%) > > rename features/{pipeline/data/lib/pipeline =3D> > > bootchain-core/data/lib/bootchain}/waitdev (83%) > > create mode 100755 > > features/bootchain-core/data/lib/initrd/cmdline.d/bootchain > > rename features/{pipeline =3D> > > bootchain-core}/data/lib/initrd/cmdline.d/pipeline (64%) > > rename features/{pipeline/data/lib/uevent/filters/pipeline-waitdev =3D> > > bootchain-core/data/lib/uevent/filters/bootchain-waitdev} (77%) > > rename features/{pipeline/data/sbin/pipeline-sh-functions =3D> > > bootchain-core/data/sbin/bootchain-sh-functions} (70%) > > rename features/{pipeline/data/sbin/pipelined =3D> > > bootchain-core/data/sbin/bootchained} (78%) >=20 > Should we call it /sbin/bootchained? It is not chained. :) Good catch! :) > Why not /sbin/bootchaind? You guys can choose the name that seems right to you. I mean we can call it "chaind". without "boot" prefix. > > create mode 100644 features/bootchain-core/rules.mk > >=20 > > diff --git a/features/bootchain-core/README.md > > b/features/bootchain-core/README.md > > new file mode 100644 > > index 0000000..e4b87d6 > > --- /dev/null > > +++ b/features/bootchain-core/README.md > > @@ -0,0 +1,81 @@ > > +# Feature: bootchain-core > > + > > +`bootchain-core` - it's a fork and further development the original > > +feature of `pipeline`. This feature allow us to consistently setup > > +steps-scripts one by one. For details about `pipeline` you can see > > +in ../features/pipeline/README.md. > > + > > +In fork process `pipeline` was divided by three parts: > > + > > +- `bootchain-core` - the main functional of feature `pipeline`, common > > + API and daemon. > > +- `bootchain-getimage` - method to networking boot from ISO-image with > > + the wget utility. > > +- `bootchain-waitdev` - method to boot from specified local media. > > + > > +The future work with `bootchain` allowed us to create a few modules. > > +They are expected to be upstream soon. This divide on modules allow > > +us to optimize fill in `initramfs` only which we are need. > > + > > +## Main components of bootchain-core > > + > > +- `/sbin/bootchain-sh-functions` - common API and evolution > > + of `pipeline-sh-functions`. > > +- `/sbin/bootchained` - daemon, evolution of `pipelined`. > > +- `/etc/rc.d/init.d/bootchain` - sysvinit start script. > > + > > +## Reasons of making fork and rename pipeline > > + > > <...> > > + > > +## External elements of the bootchain (steps-scripts) > > + > > +- `mountfs` - mounts a file or device from the result of the previous = or > > other > > + specified step. > > +- `overlayfs` - combines one or more elements of the boot chain using > > overlayfs. > > +- `rootfs` - forces the daemon to use the result of the previous eleme= nt as > > the > > + found root of stage 2. > > + > > +## Boot parameters > > + > > +- `bootchain=3Dname1[,name2][,name3]` - defines the initial state of t= he boot > > + chains, i.e. the steps that the daemon must go through one by one. T= hese > > can > > + be both built-in pseudo-steps and real scripts of the actions perfor= med. >=20 > =D0=9C=D0=BE=D0=B6=D0=BD=D0=BE =D0=BB=D0=B8 =D0=B1=D1=83=D0=B4=D0=B5=D1= =82 =D0=BF=D1=80=D0=B8 =D0=B6=D0=B5=D0=BB=D0=B0=D0=BD=D0=B8=D0=B8 =D0=BF=D0= =B8=D1=81=D0=B0=D1=82=D1=8C =D1=81=D0=B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1=8C=D0=B7=D0=BE=D0=B2=D0=B0=D1=82=D0=B5=D0=BB=D0=B8 =D0=B0=D0=BF=D1=81=D1=82=D1=80=D0=B8=D0=BC=D1=8F=D1=82 =D1=81=D0=B2=D0=BE= =D0=B8 =D0=BD=D0=B0=D1=80=D0=B0=D0=B1=D0=BE=D1=82=D0=BA=D0=B8, =D0=BD=D0=B5= =D0=BA=D0=BE=D1=82=D0=BE=D1=80=D1=8B=D0=B5 =D0=BD=D0=B5=D1=82. =D0=AD=D1=82= =D0=B8 =D0=BE=D0=B1=D0=B0 =D0=B2=D0=B0=D1=80=D0=B8=D0=B0=D0=BD=D1=82=D0=B0 = =D0=B8=D0=BC=D0=B5=D1=8E=D1=82 =D1=81=D0=B2=D0=BE=D0=B8 =D0=BF=D0=BB=D1=8E= =D1=81=D1=8B =D0=B8 =D0=BC=D0=B8=D0=BD=D1=83=D1=81=D1=8B. > > The > > + names these steps are listed separated by commas. > > +- `pipeline=3Dname1[,name2][,name3]` - alias for `bootchain=3D...`. > > +- `mountfs=3Dtarget` - specifies the file or device to be mounted. > > +- `overlayfs=3Dlist` - defines the list of elements to combine. > > + > > +## bootchain-sh-functions API > > + > <...> --=20 Rgrds, legion