[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

chroot PATH for debootstrap



I followed the procedure in https://www.debian.org/releases/stable/amd64/apds03.html.en
to set up a "jessie" inside a spare LV and boot partition. Overall this was a great experience
but there was one small problem.

The host system (Fedora 23) doesn't have anything in /sbin and /bin, so these two are not on
my path. Halfway through the

	/usr/sbin/debootstrap --arch amd64 jessie /mnt/debian http://ftp.ch.debian.org/debian/

it tries to do a chroot; this failed with something like  "mount: command not found".
It looks like the chroot inherits PATH from the calling process.
I had to do 

   PATH="/sbin:/usr/sbin:/bin:/usr/bin:$PATH" /usr/sbin/debootstrap ...

to make it work.

As the path in the host and the chroot are really unrelated, maybe debootstrap should set an
explicit path? If not, the document could be changed to include the PATH=... setting in all
examples.

Roman

Background: This is my first Debian experience. I am a veteran of 20 years with linux, back to
the days of early Redhat releases (now named "Fedora"). But with the KDE5 crap they put into
Fedora 23, I finally had to look for alternatives. I eventually decided to give Debian a try,
and set up the system with debootstrap inside a running Fedora 23 workstation.
Once in the chroot, I continued to add X11, KDE, and the Nvidia drives (required for the
Quadro K2200, as the nouveau drivers don't work with its Displayport output).

I added a menu entry for the new system in my grub.cfg and rebooted.
This new installation came up and went right to the KDM login prompt
on my first attempt!
Amazing, I've never had such a good linux experience before. You guys rock!
Forget all the installers and live systems on an USB stick. I am deeply impressed.

I am looking forward to a great experience with Debian.


Reply to: