Currently you can find a lot of different instructions in wiki, forums, IRC comments... about what commands people need to run to mount all the stuff (/dev, /dev/pts, /sys...) needed to make a chroot to run Gentoo inside it. From my point of view, either stage3 or another package (baselayout?) should provide an *official* script that we could run or read as reference to mount all properly before trying to chroot into it, otherwise people will still get confused with the dirs they need to mount and the options they need to use. Thanks a lot
I disagree with this being done through stages / catalyst. I'm fine with this being added to a @system package and thus getting in the stages through that. I'm reassigning this to the base-system team.
Not sure what you mean here. If that's just about running gentoo inside gentoo, I think we should probably recommend lxc instead of chroot, which should provide better isolation (or at least control over it) and already has scripts: https://wiki.gentoo.org/wiki/LXC#Automatic_setup:_LXC_standard_Gentoo_template_script IIRC this works on other distros too. If that's about having an alias for mounting stuff when doing a first install, that's more releng stuff and this doesn't belong to @system nor stage3 but rather to the install medias. This would require handbook updates and also imply that the handbook relies on booting from an official gentoo media, which I don't think is currently the case, and hence I'm not really convinced of its usefulness.
at this point, most of the container tech is in the kernel, so lxc is not needed at all. you can get the same level of isolation with the `unshare` command. while i would like a shell script that we could ship with images, i know it'd grow out of control quickly to try and support things sanely. i have a ~200 line script already that i use everywhere, but it does exactly what i expect. i suspect everyone will want to do their own thing instead. what if it was a standalone package people had to emerge ? either independent of gentoolkit, or part of it ?
(In reply to SpanKY from comment #3) > at this point, most of the container tech is in the kernel, so lxc is not > needed at all. you can get the same level of isolation with the `unshare` > command. > > while i would like a shell script that we could ship with images, i know > it'd grow out of control quickly to try and support things sanely. i have a > ~200 line script already that i use everywhere, but it does exactly what i > expect. i suspect everyone will want to do their own thing instead. > > what if it was a standalone package people had to emerge ? either > independent of gentoolkit, or part of it ? How about a catalyst target? Start from a stage3 or stage4 or whatever, and end up with a chroot-in-a-tarball? Unpack and chroot in.
(In reply to Joshua Kinard from comment #4) this isn't about creating a tarball, it's about entering a chroot i.e. you don't just run `sudo chroot /some/path`. you have to do a lot more stuff to have a sane environment like unsharing namespaces and mounting paths.
this is mostly done (at least enough for a 0.1 release). i'll start with a new repo/project and see how it goes.
(In reply to SpanKY from comment #6) > this is mostly done (at least enough for a 0.1 release). i'll start with a > new repo/project and see how it goes. I suggest we add it to the install-cd / admin-cd targets.
(In reply to SpanKY from comment #6) > this is mostly done (at least enough for a 0.1 release). i'll start with a > new repo/project and see how it goes. Hello! Do you have public repo already?
hmm no update on this bug? it's really pain in arse to renter all mount commands everytime for chroot; making a gentoo-chroot is that hard?
We actually recently added arch-chroot (and genfstab) to install media.
is it meant for general use? I wondered about why the script is not mentioned in the handbook (and, then, likely not being used by most people) and it seems it had some issues in the past: https://wiki.gentoo.org/wiki/Handbook_Talk:AMD64/Installation/Base#Add_warning_about_arch-chroot Maybe the issues were fixed and can finally be mentioned (In reply to Morteza from comment #9) > hmm no update on this bug? it's really pain in arse to renter all mount > commands > everytime for chroot; making a gentoo-chroot is that hard? I don't remember why I opened this back in the days ;), but I agree that one of the things that bothered me last time I installed Gentoo was needing to open the browser, visit the handbook page and copying and pasting each command to redo the chroot (I was having some stability issues on those systems due to a graphics driver bug that made be need to reboot and re-enter chroot multiple times) Thanks