Removed UML redirect
This commit is contained in:
parent
c19eb85cca
commit
6fd70a1e56
|
@ -1,7 +1,6 @@
|
|||
#!/bin/bash -x
|
||||
|
||||
echo "$1" > "$APP/uml_command"
|
||||
mkfifo "$APP/fifo"
|
||||
TEMP="$APP" "$APP/uml/uml" root=/dev/root rw rootflags=/ rootfstype=hostfs init="$APP/uml/init" eth0=slirp,10.0.2.15,"$APP/uml/slirp" mem=${MEM}M quiet app="$APP" < "$APP/fifo"
|
||||
TEMP="$APP" "$APP/uml/uml" root=/dev/root con0=fd:1,fd:1 rw rootflags=/ rootfstype=hostfs init="$APP/uml/init" eth0=slirp,10.0.2.15,"$APP/uml/slirp" mem=${MEM}M quiet app="$APP"
|
||||
rm "$APP/fifo"
|
||||
rm "$APP/uml_command"
|
||||
|
|
|
@ -0,0 +1,35 @@
|
|||
#!/bin/bash -x
|
||||
|
||||
export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
|
||||
mount -t devtmpfs udev /dev
|
||||
mount -t proc proc /proc
|
||||
mount -t sysfs sysfs /sys
|
||||
|
||||
APP="$(sed s/^.*app=// /proc/cmdline)"
|
||||
|
||||
mount --bind "$APP/uml/modules" /lib/modules
|
||||
|
||||
ifconfig eth0 up
|
||||
ifconfig eth0 10.0.2.15
|
||||
route add default dev eth0
|
||||
|
||||
modprobe fuse
|
||||
modprobe ext4
|
||||
modprobe loop
|
||||
mount "$APP/shadow_root.img" "$APP/shadow_root" -t ext4
|
||||
LD_LIBRARY_PATH="$APP/uml" "$APP/uml/unionfs" -o rw,cow "$APP/shadow_root=RW:/=RO" "$APP/shadow_mount"
|
||||
|
||||
mount --bind /proc "$APP/shadow_mount/proc"
|
||||
mount --bind /dev "$APP/shadow_mount/dev"
|
||||
mount --bind /sys "$APP/shadow_mount/sys"
|
||||
|
||||
mkdir "$APP/shadow_mount/app"
|
||||
mount --bind "$APP/root" "$APP/shadow_mount/app"
|
||||
|
||||
chroot "$APP/shadow_mount" bash -c "$(cat "$APP/uml_command")"
|
||||
|
||||
umount "$APP/shadow_mount/dev" "$APP/shadow_mount/proc" "$APP/shadow_mount/sys"
|
||||
umount "$APP/shadow_mount"
|
||||
umount "$APP/shadow_root"
|
||||
mount -o remount,ro,sync /dev/root /
|
||||
halt -f
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue