Hi,
I modified some in live-initramfs to make it work with
fetch=tftp://$IP/@FILE
And about fixes:
1. Make the shared libraries in /root/lib and /root/usr/lib can be
accessed in initramfs
2. In upstart, to run it is using "exec", not "respawn".
For example, in /etc/event.d/tty1, it's:
exec /sbin/getty 38400 tty1

Another minor fix is about using udevsettle or "udevadm settle" in
scripts/live-helpers.

Hope this helps.
My 2 cents.

Regards,
Steven.

-- 
Steven Shiau <steven _at_ nchc org tw> <steven _at_ stevenshiau org>
National Center for High-performance Computing, Taiwan. http://www.nchc.org.tw
Public Key Server PGP Key ID: 1024D/9762755A
Fingerprint: A2A1 08B7 C22C 3D06 34DB  F4BC 08B3 E3D7 9762 755A

--- live-initramfs-1.136.3.orig/scripts/live
+++ live-initramfs-1.136.3/scripts/live
@@ -3,6 +3,7 @@
 # set -e
 
 export PATH="/root/usr/bin:/root/usr/sbin:/root/bin:/root/sbin:/usr/bin:/usr/sbin:/bin:/sbin"
+export LD_LIBRARY_PATH="$LD_LIBRARY_PATH:/root/lib:/root/usr/lib"
 
 echo "/root/lib" >> /etc/ld.so.conf
 echo "/root/usr/lib" >> /etc/ld.so.conf
@@ -720,8 +721,17 @@
 					if [ "${webfile}" = "FETCH" ]
 					then
 						[ "${quiet}" != "y" ] &&
+						case "$url" in
+						  tftp*)
+						        ip="$(dirname $url | sed -e "s|tftp://||g")"
+							log_begin_msg "Trying tftp -g -b 10240 -r $(basename ${url})  -l ${dest}/$(basename ${url}) $ip"
+							tftp -g -b 10240 -r $(basename ${url})  -l ${dest}/$(basename ${url}) $ip
+							;;
+						  *)
 							log_begin_msg "Trying wget ${url} -O ${dest}/$(basename ${url})"
-						wget "${url}" -O "${dest}/$(basename ${url})"
+							wget "${url}" -O "${dest}/$(basename ${url})"
+							;;
+						esac
 					else
 						[ "${quiet}" != "y" ] &&
 							log_begin_msg "Trying to mount ${url} on ${dest}/$(basename ${url})"
--- live-initramfs-1.136.3.orig/scripts/live-bottom/25configure_init
+++ live-initramfs-1.136.3/scripts/live-bottom/25configure_init
@@ -79,7 +79,8 @@
 			then
 				for f in /root/etc/event.d/tty*
 				do
-					sed -i -e "s|^respawn.*|respawn /bin/login -f ${USERNAME} </dev/$(basename ${f}) > /dev/$(basename ${f}) 2>\&1|" ${f}
+					#sed -i -e "s|^respawn.*|respawn /bin/login -f ${USERNAME} </dev/$(basename ${f}) > /dev/$(basename ${f}) 2>\&1|" ${f}
+					sed -i -e "s|^exec.*|exec /bin/login -f $USERNAME </dev/$(basename $f) > /dev/$(basename $f) 2>\&1|" $f
 				done
 			fi
 		fi
--- live-initramfs-1.136.3.orig/scripts/live-helpers
+++ live-initramfs-1.136.3/scripts/live-helpers
@@ -167,7 +167,14 @@
 	local readonly=${6}
 
 	modprobe -q -b "${module}"
-	udevsettle
+	if [ -x /sbin/udevadm ]
+	then
+		# lenny
+		udevadm settle
+	else
+		# etch
+		udevsettle
+	fi
 
 	for loopdev in ${pattern}
 	do
_______________________________________________
debian-live-devel mailing list
debian-live-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/mailman/listinfo/debian-live-devel

Reply via email to