Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230
Kodi17.6(chroot sid) in stretch, works Great!!
Kodi17.6(chroot sid) in stretch, works Great!!
Im really delighted with Using debpotstrap and Chroot, Ive just installled kodi17.6 in debootstrap container buster/sid under stretch and it works perfect; Now i can take advantage of running sid's applications in stable like if they were native without messing the system.
- Ive testing kodi17.6 (it brings Mesa 17), and last audio/video codecs.
Ive created two debootstrap systems containes raw images;, one with jessie and one with buster, so I can run older and newer versions in stable. They just fill around 500M with empty base installation. Ive created two raw images of 2Gb each one so I can install at least two big applications for buster or jessie.
The followed steps are in resume the way I followed.:
___________________________________________________________
0. Get the debootstrap base installation (Buster example).
debootstrap buster ~/Download_buster http://debian.org
1. Create a raw image to put inside the debootstrap installation
dd if=/dev/zero of=/media/store/buster.img bs=100M count=20 (2Gb Image file)
mkfs.btrfs buster.wine
mount -t btrfs /media/store/buster.img /mnt
cd /mnt && btrfs subvolume create buster (create buster container subvolume)
umount /mnt && mount -t btrfs -o subvol=buster /media/store/buster.img /mnt
rsync -aAXv ~/Download_buster /mnt/buster
2. Add mount point of image debootsrap in fstab.
/media/store/buster.img /media/buster/ btrfs subvol=buster,defaults,noatime,space_cache,autodefrag 0 2
3. Create init snapshot from clean debootstrap installation so we can restore clean installation.
cd /media/buster && btrfs subvolume snapshot ./ init_snap
4. Binding system and chroot to debootstrap installation
imagePATH=/media/buster
echo /run /sys /proc /dev/pts /dev/shm /dev | xargs -n1 |sudo xargs -I{} umount $imagePATH/{} (Unmount all)
echo /dev /dev/shm /dev/pts /proc /sys /run | xargs -n1 |sudo xargs -I{} mount -o bind {} $imagePATH/{} (Mount all)
4.2 Installing kodi17.6 in buster.
4.2.1 Adding temporary (for kodi) sid repository source to sources.list
deb http://deb.debian.org/debian/ buster main contrib non-free
deb http://deb.debian.org/debian/ sid main contrib non-free
4.2.2 Install Kodi 17.6
sudo chroot $imagePATH && apt-get install kodi -t buster
5. Running chroot application; invoke script within chroot (script linux_app.sh).: :
sudo chroot $imagePATH /linux_app.sh $1 &
(running kodi) sudo chroot $imagePATH /linux_app.sh kodi &
6. In chroot, Mount data folders and runn App (script linux_app.sh).:
mount -t btrfs -o subvol=home /dev/sdaX /home
mount -t btrfs -o subvol=kodi /dev/sdaX /media/kodi
su myuser -c $1
sleep 2
su myuser -c "pkill -x $1"
su myuser -c "pkill -x $1 -9"
su myuser -c "exit"
- Ive testing kodi17.6 (it brings Mesa 17), and last audio/video codecs.
Ive created two debootstrap systems containes raw images;, one with jessie and one with buster, so I can run older and newer versions in stable. They just fill around 500M with empty base installation. Ive created two raw images of 2Gb each one so I can install at least two big applications for buster or jessie.
The followed steps are in resume the way I followed.:
___________________________________________________________
0. Get the debootstrap base installation (Buster example).
debootstrap buster ~/Download_buster http://debian.org
1. Create a raw image to put inside the debootstrap installation
dd if=/dev/zero of=/media/store/buster.img bs=100M count=20 (2Gb Image file)
mkfs.btrfs buster.wine
mount -t btrfs /media/store/buster.img /mnt
cd /mnt && btrfs subvolume create buster (create buster container subvolume)
umount /mnt && mount -t btrfs -o subvol=buster /media/store/buster.img /mnt
rsync -aAXv ~/Download_buster /mnt/buster
2. Add mount point of image debootsrap in fstab.
/media/store/buster.img /media/buster/ btrfs subvol=buster,defaults,noatime,space_cache,autodefrag 0 2
3. Create init snapshot from clean debootstrap installation so we can restore clean installation.
cd /media/buster && btrfs subvolume snapshot ./ init_snap
4. Binding system and chroot to debootstrap installation
imagePATH=/media/buster
echo /run /sys /proc /dev/pts /dev/shm /dev | xargs -n1 |sudo xargs -I{} umount $imagePATH/{} (Unmount all)
echo /dev /dev/shm /dev/pts /proc /sys /run | xargs -n1 |sudo xargs -I{} mount -o bind {} $imagePATH/{} (Mount all)
4.2 Installing kodi17.6 in buster.
4.2.1 Adding temporary (for kodi) sid repository source to sources.list
deb http://deb.debian.org/debian/ buster main contrib non-free
deb http://deb.debian.org/debian/ sid main contrib non-free
4.2.2 Install Kodi 17.6
sudo chroot $imagePATH && apt-get install kodi -t buster
5. Running chroot application; invoke script within chroot (script linux_app.sh).: :
sudo chroot $imagePATH /linux_app.sh $1 &
(running kodi) sudo chroot $imagePATH /linux_app.sh kodi &
6. In chroot, Mount data folders and runn App (script linux_app.sh).:
mount -t btrfs -o subvol=home /dev/sdaX /home
mount -t btrfs -o subvol=kodi /dev/sdaX /media/kodi
su myuser -c $1
sleep 2
su myuser -c "pkill -x $1"
su myuser -c "pkill -x $1 -9"
su myuser -c "exit"
Last edited by bester69 on 2017-12-28 13:47, edited 1 time in total.
bester69 wrote:STOP 2030 globalists demons, keep the fight for humanity freedom against NWO...
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 133 times
Re: Kodi17.6(chroot sid) in stretch, works Great!!
That's amazing!bester69 wrote:Now i can take advantage of running sid's applications in stable like if they were native without messing the system.
Have you seen http://forums.debian.net/viewtopic.php?f=16&t=129390?
deadbang
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 133 times
Re: Kodi17.6(chroot sid) in stretch, works Great!!
Just FYI:
And this for the second line:
That calls a single command (`mount`) and lets the shell do all the work; your version calls three extra commands, which is much less efficient.
Also, see https://mywiki.wooledge.org/Quotes
So
Should if fact be:
And maybe this overall structure would be more "correct":
EDIT: added 'run'
Try this instead of the first line:bester69 wrote:4. Binding system and chroot to debootstrap installation
imagePATH=/media/buster
echo /run /sys /proc /dev/pts /dev/shm /dev | xargs -n1 |sudo xargs -I{} umount $imagePATH/{} (Unmount all)
echo /dev /dev/shm /dev/pts /proc /sys /run | xargs -n1 |sudo xargs -I{} mount -o bind {} $imagePATH/{} (Mount all)
Code: Select all
sudo umount -R "${imagePATH}"
Code: Select all
for i in 'proc' 'sys' 'dev' 'dev/pts' 'dev/shm'; do sudo mount --bind /"${i}" "${imagePATH}/${i}"; done
Also, see https://mywiki.wooledge.org/Quotes
So
Code: Select all
imagePATH=/media/buster
Code: Select all
imagePATH='/media/buster'
Code: Select all
imagepath='/media/buster'
sudo umount -R "${imagepath}"
for i in 'run' 'proc' 'sys' 'dev' 'dev/pts' 'dev/shm'; do sudo mount --bind /"${i}" "${imagepath}/${i}"; done
Last edited by Head_on_a_Stick on 2017-12-28 14:37, edited 1 time in total.
deadbang
Re: Kodi17.6(chroot sid) in stretch, works Great!!
hehehe, Its all invented, isnt it? I like to explore my own creativity..Head_on_a_Stick wrote:That's amazing!bester69 wrote:Now i can take advantage of running sid's applications in stable like if they were native without messing the system.
Have you seen http://forums.debian.net/viewtopic.php?f=16&t=129390?
Thanks for your input Head, I didnt know about systemd-nspawn, I will note it down in my notebook, and take it a look eventually.. bit a bit we keep learning linux solutions.
Last edited by bester69 on 2017-12-28 14:24, edited 1 time in total.
bester69 wrote:STOP 2030 globalists demons, keep the fight for humanity freedom against NWO...
Re: Kodi17.6(chroot sid) in stretch, works Great!!
I will keep this learning, thanks.Head_on_a_Stick wrote:Just FYI:
Try this instead of the first line:Code: Select all
sudo umount -R "${imagePATH}"
by the way, your correction are great, and i really apreciate them, but i'll stay in mode easy...
thanks.
bester69 wrote:STOP 2030 globalists demons, keep the fight for humanity freedom against NWO...
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 133 times
Re: Kodi17.6(chroot sid) in stretch, works Great!!
Just used this method in my Alpine Linux system, I see no reason why it won't work in Debian
Running shiny new **** from an Arch Linux chroot
First, download an Arch Linux bootstrap image and unpack it in a working directory (and clean up afterwards):
This unpacks to ~/chroot/root.x86_64 and we now need to un-comment a mirror so that pacman will work:
Next, bind mount the API filesystems and chroot in:
From the chroot shell, we can bootstrap pacman and install our package (denoted by "foo" in this example):
Once that is done, use `exit` (or <Ctrl>+d) to exit the chroot.
Finally, run the application ("foo" in this example) from the Debian host using the `chroot` command, like this (I've added DISPLAY=:0 to allow "foo" access to the graphical desktop):
Most programs won't need the API stuff mounted to run so that should still work once you unbind them.
A new user can be created to run the chroot programs if preferred, it's probably simplest to select the same UID & GID as the host user.
Running shiny new **** from an Arch Linux chroot
First, download an Arch Linux bootstrap image and unpack it in a working directory (and clean up afterwards):
Code: Select all
curl -O https://mirrors.kernel.org/archlinux/iso/latest/archlinux-bootstrap-2018.01.01-x86_64.tar.gz
tar xzf archlinux-bootstrap-2018.01.01-x86_64.tar.gz && rm archlinux-bootstrap-2018.01.01-x86_64.tar.gz
Code: Select all
sed -i '/evowise/s/^#//' root.x86_64/etc/pacman.d/mirrorlist
Code: Select all
for i in proc sys dev run; do sudo mount --rbind /$i root.x86_64/$i; done
sudo chroot root.x86_64 /bin/bash
Code: Select all
pacman-key --init
pacman-key --populate archlinux
pacman -Syu foo
Finally, run the application ("foo" in this example) from the Debian host using the `chroot` command, like this (I've added DISPLAY=:0 to allow "foo" access to the graphical desktop):
Code: Select all
sudo chroot ~/chroot/root.x86_64 /bin/su -c 'DISPLAY=:0 foo'
A new user can be created to run the chroot programs if preferred, it's probably simplest to select the same UID & GID as the host user.
deadbang
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 133 times
Re: Kodi17.6(chroot sid) in stretch, works Great!!
Looks like a lot of workwizard10000 wrote:running Sid
deadbang