ProgrammingThis forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
keyboard setup,
display setup,
disk partitioning,
identifying the target to install on (partition/lvm/mdadm + partitioning)
identifying the source to retrieve the packages from (URL/net? disk? USB? NFS?) and setup,
package selection (assuming there IS a choice).
filesystem to use (xfs,ext4,btrfs,other?)
boot configuration and initialization,
mount configuration (fstab setup mostly),
swap configuration and initialization,
Of course, if all of this is supposed to be done, then you aren't doing an installation, but something closer to just cloning a disk...
In which case all you do is install the finished clone.
Anaconda is rather complex because it is trying to do something that IS complex.
true, partitioning
unpacking includes target
source is easy, even internet ones
package selection is easy, also more of a gui thing (gui was not mentioned)
filesystem goes into partitioning
boot config is easy since you have all the data you need to do it
fstab (that includes swap) is easy when you do partitioning
i'm against using anaconda as an example as apparently it is so incredibly complex that very competent programmers can't rid it of bugs
slackwares installer is much much simpler and does it all except the partitioning part
(a gui version of it is a matter of making a gui more then anything else)
k, it doesn't do encryption and lvm
depends on the configuration of the LVM/partitioning. Anaconda is complex, as it is trying to do the whole install/configuration/configuration tasks. It has to be complex. That is one of the nice things about Slakware - it doesn't try to do everything. But then, the person installing has to know more.
In the case of btrfs, there are storage pools to be considered which can be one or more disks/partitions.
In the case of xfs/ext4 there are optimization configurations...
As far as not using something that has already been done..
Up to you. NIH exists in lots of forms.
Boot configuration depends on what you are dealing with - BIOS/UEFI, grub/grub2/lilo/elilo... and then there are signing issues for secureboot, unless that is disabled...
Lots of variables and combinations.
Slackware is much simpler in packaging too. But it depends on what you are doing. It is considered more complex since it doesn't directly deal with dependency lists...
When you're installing an OS, you have to be root user because you are creating partitions, file systems, etc. Or to be more precise, there's no users (other than the 'implicit root') at that time.
Just to add to what NevemTeve has written. The reason an installer requests a password is not to become root, since you already are root to do the install, but to add the password to the password file.
I'm writing a simple installer and I'm stumped
on how to create user accounts.
How cant I create root account without first being root?
This installer is made only in C++.
Thanks for your help!
Are you making a Linux installer or an application/applet/etc installer. If it is Linux installer, the installer is running in a live environment and the root account is created on the partition the will contains the new /etc/ and as such it can be created with a password that supplied by the "installing person" via the fact that you are root in the installer or that you are a user that can do su or sudo commands.
OS-installation is always happening in admin mode, initramfs notwithstanding (packed or otherwise).
Mind you, the installer program isn't part of the kernel.
OS-installation is always happening in admin mode, initramfs notwithstanding (packed or otherwise).
Mind you, the installer program isn't part of the kernel.
Right on!
Just to clarify:
The initial initramfs in the root of
the .iso will start up my installer.
I will use dracut at the end of the
install to make another initramfs on
the HD
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.