[HD Mini Android Development] derefas:
problem not in directory..

i think problem in mount blocks

ps: hd2 init

#!/bin/sh
# author: cedesmith
# license: GPL
# if you use my work please clearly and visibly mention it
echo "Init started"

OLD_PATH=$PATH
PATH=/sbin:/bin:/system/sbin:/system/bin:/system/xbin:/system/xbin/bb:/data/local/bin
export PATH

fail() {
echo "$1"
exit 1
}

/bin/mount -o remount,rw / /
mount -t proc proc /proc

mount -t sysfs sys /sys

[COLOR="Red"]mkdir -m 0777 /dev/block
mknod -m 0666 /dev/block/mmcblk0 b 179 0
mknod -m 0666 /dev/block/mmcblk0p1 b 179 1
mknod -m 0666 /dev/block/mmcblk0p2 b 179 2
mknod -m 0666 /dev/block/mmcblk0p3 b 179 3
mknod -m 0666 /dev/block/mmcblk0p4 b 179 4

mkdir -m 0777 /dev/input
mknod -m 0644 /dev/input/event0 c 13 64
mknod -m 0644 /dev/input/event1 c 13 65
mknod -m 0644 /dev/input/event2 c 13 66
mknod -m 0644 /dev/input/event3 c 13 67

mknod -m 0666 /dev/null c 1 3
mknod -m 0444 /dev/zero c 1 5
mknod -m 0644 /dev/ppp0 c 108 0
mknod -m 0644 /dev/smd0 c 253 0
mknod -m 0644 /dev/smd1 c 253 1
[/COLOR]
# wait for sdcard
while [ ! -b /dev/block/mmcblk0 ] ; do
echo "Waiting for SD Card"
sleep 1
done
sleep 1

[COLOR="red"]find /sys/block/mmcblk0/ -type d > /dev/null[/COLOR]

# mount /sdcard for install/update and in case system and data are image files not partitions
# use loop_partition for backward compatibility
sdcard_partition=`grep -o '\bloop_partition=\w*' /proc/cmdline | sed 's/loop_partition=//'`
if [ "$sdcard_partition" = "" ];then
# assume single partition, if found partition 1 use that
sdcard_partition=mmcblk0
#[ -b /dev/block/mmcblk0p1 ] && sdcard_partition=mmcblk0p1
[ -d /sys/block/mmcblk0/mmcblk0p1 ] && sdcard_partition=mmcblk0p1
fi

mkdir -m 0755 /mnt
chown 0:1000 /mnt
mkdir -m 0700 /mnt/sdcard_boot
mount -t vfat -o rw,utf8,fmask=0111,dmask=0000,noatime,nodiratime /dev/block/$sdcard_partition /mnt/sdcard_boot
[ $? -eq 0 ] || echo "Failed to mount the SD card."

# set ANDROID_PATH for install/update and in case system and data are image files not partitions
ANDROID_PATH=`grep -o '\brel_path=\w*' /proc/cmdline | sed 's/rel_path=//'`
[ "$ANDROID_PATH" = "" ] && ANDROID_PATH="/mnt/sdcard_boot/Android" || ANDROID_PATH="/mnt/sdcard_boot/$ANDROID_PATH"
export ANDROID_PATH

cp -a $ANDROID_PATH/system.ext2 /system.ext2

# check for system_partition and data_partition
# if partitions are specified use that else use files on $ANDROID_PATH
system_partition=`grep -o '\bsystem_partition=\w*' /proc/cmdline | sed 's/system_partition=//'`
data_partition=`grep -o '\bdata_partition=\w*' /proc/cmdline | sed 's/data_partition=//'`
if [ "$system_partition" != "" -o "$data_partition" != "" ]; then
#should have both system_partition and data_partition set
[ "$system_partition" = "" ] && fail "system_partition empty while data_partition set"
[ "$data_partition" = "" ] && fail "data_partition empty while system_partition set"
else

mknod -m 0666 /dev/block/loop0 b 7 0
mknod -m 0666 /dev/block/loop1 b 7 1
system_partition="loop0"
data_partition="loop1"

if [ -f /system.ext2 ]; then
losetup /dev/block/loop0 /system.ext2
elif [ -f /system.ext2 ]; then
losetup /dev/block/loop0 /system.ext2
else
fail "system image not found on $ANDROID_PATH "
fi

if [ -f $ANDROID_PATH/data.img ]; then
losetup /dev/block/loop1 $ANDROID_PATH/data.img
elif [ -f $ANDROID_PATH/data.ext2 ]; then
losetup /dev/block/loop1 $ANDROID_PATH/data.ext2
else
fail "data image not found on $ANDROID_PATH "
fi
fi

mount -t ext2 -o noatime,nodiratime /dev/block/$system_partition /system
[ $? -eq 0 ] || fail "Failed to mount /system"
mount -t ext2 -o noatime,nodiratime /dev/block/$data_partition /data
[ $? -eq 0 ] || fail "Failed to mount /data"

# move adbd to xbin to free ram for
[ ! -f /system/xbin/adbd ] && cp -a /sbin/adbd /system/xbin/
rm -f /sbin/adbd
[ -f /system/xbin/adbd ] && ln -s /system/xbin/adbd /sbin/adbd
# move config files to /system to allow edit persist and save ram
[ ! -f /system/init.rc ] && cp -a /init.rc /system/init.rc
[ ! -f /system/init.htcleo.rc ] && cp -a /init.htcleo.rc /system/init.htcleo.rc
[ ! -f /system/bootcomplete.htcleo.rc ] && cp -a /bootcomplete.htcleo.rc /system/bootcomplete.htcleo.rc
[ ! -f /system/shutdown.htcleo.rc ] && cp -a /shutdown.htcleo.rc /system/shutdown.htcleo.rc
[ ! -f /system/default.prop ] && cp -a /default.prop /system/default.prop
rm -f /init.rc /init.htcleo.rc /bootcomplete.htcleo.rc /shutdown.htcleo.rc /default.prop
[ -f /system/init.rc ] && ln -s /system/init.rc /init.rc
[ -f /system/init.htcleo.rc ] && ln -s /system/init.htcleo.rc /init.htcleo.rc
[ -f /system/bootcomplete.htcleo.rc ] && ln -s /system/bootcomplete.htcleo.rc /bootcomplete.htcleo.rc
[ -f /system/shutdown.htcleo.rc ] && ln -s /system/shutdown.htcleo.rc /shutdown.htcleo.rc
[ -f /system/default.prop ] && ln -s /system/default.prop /default.prop

if [ -d "$ANDROID_PATH/update" ] ; then

find "$ANDROID_PATH/update/" -maxdepth 1 -name "uninstall*.sh" -exec sh '{}' \;

find "$ANDROID_PATH/update/" -maxdepth 1 -name "install*.sh" -exec sh '{}' \;
fi

if [ -d $ANDROID_PATH/AndroidApps ] ; then
echo Copying Applications
if [ ! -d /data/app ] ; then
mkdir -m 0771 /data/app
fi

[ ! -d /data/app/tmp_copy_dir ] && mkdir /data/app/tmp_copy_dir
cp $ANDROID_PATH/AndroidApps/* /data/app/tmp_copy_dir/
chown -R 1000:1000 /data/app/tmp_copy_dir/

find /data/app/tmp_copy_dir/ -type f -exec chmod 0644 '{}' \;
find /data/app/tmp_copy_dir/ -type d -exec chmod 0755 '{}' \;
mv /data/app/tmp_copy_dir/* /data/app/
rm -rf /data/app/tmp_copy_dir

rm -rf $ANDROID_PATH/AndroidApps
fi

if [ -d "$ANDROID_PATH/root" ] ; then
echo Updating files
cp -ar $ANDROID_PATH/root/* /

fi

if [ -d "$ANDROID_PATH/update" ] ; then
echo "Executing update scripts"
find "$ANDROID_PATH/update/" -maxdepth 1 -name "update*.sh" -exec sh '{}' \;

fi

find /system -maxdepth 1 -name "init*.sh" -exec sh '{}' \;

if [ ! -d /data/.cache ];then
mkdir -m 0770 /data/.cache
chown 1000:2001 /data/.cache
fi
ln -s /data/.cache /cache

if [ -f /data/data/customized ];then
rm /init.rc
mv /initorig.rc /init.rc
fi

umount /mnt/sdcard_boot
#rm -rf /bin
PATH=$OLD_PATH
export PATH

exec /init.android

the first idea

change loop1 to loop0 in system.ext2

# mount system.ext2
if [ -f $card/system.ext2 ] ; then
echo "Using uncompressed system"
losetup /dev/block/[COLOR="red"]loop1[/COLOR] $card/system.ext2
[ $? -eq 0 ] || fail "Failed to reach system.ext2 on SD Card"
echo "Checking system EXT2" > /proc/printk
/bin/e2fsck -y /dev/block/[COLOR="red"]loop1[/COLOR]
echo "Mount system EXT2" > /proc/printk
/bin/mount -t ext2 -o noatime,nodiratime /dev/block/loop1 /system
[ $? -eq 0 ] || fail "Failed to mount /system"

no.. isn't! problem in init.rc

in external memory line

export EXTERNAL_STORAGE /sdcard to export EXTERNAL_STORAGE /mnt/sdcard

compiling new initrd....

i 'll upload to test when all be done