[SOLVED] possible chroot script error
hi
I am going batty...I thought I posted this but maybe there is something about me at the moment? any how I created a script based on some TechAdmin posts I could chroot successfully and thought I was on a winner! but in looking at the contents of apt-get my /var/log/apt/term.log ------Can not write log, openpty() failed (/dev/pts not mounted?) ok so to my simple brain I tried this amendment :: Code ::
#!/bin/sh # before anything test we are root if test $(id -u) != 0 ; then echo "you need to be root" exit 0 fi cd /a/09/squashfs-root mount -t proc proc proc/ mount -t sysfs sys sys/ mount -o bind /dev dev/ mount -o bind /dev/pts dev/pts chroot /a/09/squashfs-root by adding the second last line. Where have I gone wrong if you know? thanks for any feedback...if not the chroot still works pretty well regards gordy < Edited by aus9 :: Apr 11, 10, 22:24 > Back to top |
hi
sidux-underground jamesbenedito suggests I mod to (and I have mod to generic) :: Code ::
#!/bin/sh # before anything test we are root if test $(id -u) != 0 ; then echo "you need to be root" exit 0 fi cd /(pathway)/squashfs-root mount --bind /proc proc mount --bind /sys sys mount --bind /dev dev mount --bind /dev/pts dev/pts chroot . Note the trailing dot. so far the log has no chroot errors regards Back to top |
All times are GMT - 8 Hours |