Sample Header Ad - 728x90

init process failed to find device default fstab

1 vote
0 answers
36 views
I trying to customize initramfs in stock Android Studio android-28 https://dl.google.com/android/repository/sys-img/android/x86_64-28_r04.zip I want to substitute SYSTEM partition to partition on sdcard. Unpacked ramdisk.img, put there /fstab.ranchu, /vendor/etc/fstab.ranchu and packed it back to ramdisk.img. The problem is that init does not see those files and loads in emulator as usual. >[ 1.196779] init: init first stage started!
>[ 1.197577] init: Using Android DT directory /sys/bus/platform/devices/ANDR0001:00/properties/android/
>[ 1.199700] init: [libfs_mgr]fs_mgr_read_fstab_default(): failed to find device default fstab
Full emulator init process https://pastebin.com/uXSY1CtS
I tried to build init program from stock.
repo init --depth=1 -u
https://android.googlesource.com/platform/manifest  -b android-10.0.0_r45
repo sync  --force-sync --no-clone-bundle --no-tags
source build/envsetup.sh
lunch aosp_x86_64-eng
cd system/core/init;     mm
I put init program back to ramdisk.img and got previous behavior. Here https://android.stackexchange.com/questions/217177/what-is-default-fstab-file-in-android written that fstab is in the proper place. And here is pease of code https://android.googlesource.com/platform/system/core/+/refs/tags/android-10.0.0_r3/fs_mgr/fs_mgr_fstab.cpp#445 about responsible fstab paths. **Edit:** i missed that Kernel command line: has skip_initramfs parameter according to https://pastebin.com/uXSY1CtS . So everything i tried to change in ramdisk.img was evoided. When i give special parameters to like that:
./emulator -avd test28 -no-cache -show-kernel -qemu -append "init=/init root=/dev/vda1"
It didn't solve the problem. Kernel still loads directly from root disk, ignoring ramdisk.img.
Asked by Сергей Мельчаков (11 rep)
Jul 5, 2025, 06:22 PM
Last activity: Jul 6, 2025, 04:12 PM