Filesystem list, init.rc and init.mapphone_cdma.rc pastebins - Motorola Droid 3

Pastebins of rooted Droid 3:
Filesystem List (some of the dynamic mounts have been removed):
http://pastebin.com/HEtYBmuz
init.rc:
http://pastebin.com/e6TieanR
init.mapphone_cdma.rc:
http://pastebin.com/Qerc64E5

Related

Which partition is equal to /recovery in other android devices?

I am new to Android, want to customize the system follow the tutorials, but found the Note is different to other Android phones:
for other phone, there will be a /proc/mtd and list all the partitions with mount point, but on Note I can only found /proc/fs, with 3 folders: ext4 jbd2 nfsd
and the mount table is like this:
rootfs on / type rootfs (ro,relatime)
...
/dev/block/mmcblk0p9 on /system type ext4
/dev/block/mmcblk0p7 on /cache type ext4
/dev/block/mmcblk0p1 on /efs type ext4
for other devices, e.g., HTC Wildfire, the partition will like below:
mtd1: recovery
mtd3: system"
...
I downloaded the CF-Root flasher, by Chainfire, found basiclly it's flashing a zImage into /dev/block/mmcblk0p5. I mount the partition before flash and seems there is only some picture files there. how can we know the machine will boot to this partition in recovery mode?
nobody knows? so far what I get seems that the phone do not use the /recovery partition, but use same kernel to handle the recovery state. during boot it will search for /system/etc/install-recovery.sh, maybe that will trigger the recovery process?
The Note, like many other Samsung phones, does not use or follow the mtd layout - at all.
Indeed there is a single kernel for both normal boot and recovery. Normal boot uses init.rc script, recovery boot uses recovery.rc script.
There is a "spare" partition that is both called recovery and available, but it isn't used.

Boot-Time Auto-SuperLog! [12 Apr 2013]

Boot-Time Auto-Superlog! [12 Apr 2013]
USERS --- TESTERS --- DEVS​Plumb the depths of Middle Droid with Auto-Superlog!​
So…
Your device doesn't finish booting
It reboots on its own (and you may not know it)
An application or feature crashes (and you may not know it)
Generally speaking, any manually-launched app or tool could miss key events leading to random reboot or application crash.
Problem addressed with Auto-Superlog!​
cm10-auto-superlog-v1.0.zip (3MB): http://www.mediafire.com/?cf5f9rq4z7p6gep
This flashable zip is tested working on my Atrix running CWM Recovery 5.0.2.0 and CM10 SuperLite. It should also work on epinter’s CM10 4.1.x builds and on close relatives. Not sure about 4.2.x yet.
In this exciting age of alpha-beta ROM testing, my lightweight Auto-Superlog, presently built on epinter’s versatile CM10 boot image (for demo purposes), can help just about anyone, whether end-user, tester or developer!
In fact it is already helping me track down abnormal battery drain and shutdown problems!
Alternatively instead of flashing the boot-time version, you can extract “auto-superlog.sh” from the flashable zip and manually execute it at run time.
Features
Automatically launches at boot-time under “class_start core” --- just after ROM filesystems are mounted, thus maximizing the likelihood of capturing key events, even if phone does not finish booting
Comprehensive log set includes: system build properties (getprop), kernel configuration file (from /proc/config.gz), kernel dmesg and system logcat --- all in sync, all in ASCII text format, and all stored in a single gzipped, time-stamped tar file on $EXTERNAL_STORAGE/auto-superlog for easy access and analysis.
Android events are quietly, nimbly and continuously streamed via kernel “dmesg” and system “logcat” commands. The dmesg log is pushed at 2-second intervals (default) with a 1MB ring buffer which is cleared on each pass. Logcat is configured to log “main” and “system” events with a generous 10MB buffer to help in discerning error trends.
Access real-time dmesg and logcat output right on your device by tapping the /data/auto-superlog directory using a (root) file explorer.
Log file contents are time stamped using absolute time ([YYYY-]MM-DD HH:MM:SS), enabling users to correlate Android events with the outside world
Filename timestamps show when your system was rebooted
Self-cleaning feature: On reboot, your most recent superlog is gzipped and archived to $EXTERNAL_STORAGE and then is removed from /data/auto-superlog so only your most recent superlog remains on the /data partition.
Shell script: auto-superlog.sh is stored under /system/bin, enabling users to extract and execute it at run-time and/or customize.
How to kill dmesg and logcat? Use the ps and grep commands: http://stackoverflow.com/questions/3117095/stopping-an-android-app-from-console (It’s a sheepish way of saying “mechanization of this feature is still in work” lol)
Instructions
Nandroid Backup current ROM (security blanket)
Flash zip if running epinter CM10 4.1.x or close relative (e.g. SuperLite)
Reboot and relax.
…OR, if you don’t want to flash the zip, but still want the run-time features of auto-superlog, simply extract /system/bin/auto-superlog.sh from zip and do this…
copy auto-superlog.sh to /system/bin (Tip: mount /system/bin as read-write (rw), then revert to ro when done)
chmod 0755 /system/bin/auto-superlog.sh
sh /system/bin/auto-superlog.sh (using Script Manager or other tool, as root)
Click to expand...
Click to collapse
After launching the script, just tap the Home button to resume other activity as the loggers are now running in background. Then you will have real-time streaming dmesg and logcat (as well as getprop and kernel config) at your fingertips --- literally.
The advantage of flashing the zip (if it’s compatible with your ROM) is that you are more likely to capture key events leading to a failed boot, random reboot or application crash.
Screenshots
​
Boot Image Source Code
This is the only change I made to CM10 boot.img...
Code:
ramdisk/init.olympus.rc ...
# sendust7 (12 Apr 2013)
service auto-superlog /system/bin/sh /system/bin/auto-superlog.sh
class core
# class main
# class late_start
user root
group system
# disabled
oneshot
# sendust7 (12 Apr 2013)
Documentation
dmesg: http://unixhelp.ed.ac.uk/CGI/man-cgi?dmesg+8
logcat: http://developer.android.com/tools/debugging/debugging-log.html#outputFormat
Android Encryption: http://source.android.com/tech/encryption/android_crypto_implementation.html
from Android Encryption…"This magic was accomplished by requiring all services to be in 1 of 3 groups: core, main and late_start. Core services are never shut down after starting. main services are shutdown and then restarted after the disk password is entered. late_start services are not started until after /data has been decrypted and mounted.”
Click to expand...
Click to collapse
Thoughts and Ideas: This has been a fun project so far. Time permitting, I may be able to service bug fixes and add more goodies like event filtering.
Disclaimer: Standard disclaimers apply.
Credits:Emerson Pinter (CM10 for Atrix 4g), Cyanogenmod Team
Very nice!
The OS considers the internal SD as EXTERNAL_STORAGE in assigning the env variable which is perhaps the reason you should too:
Booted without external sd mounted:
Code:
[email protected]:/ $ echo $EXTERNAL_STORAGE
/storage/sdcard0
Booted with external sd mounted:
Code:
[email protected]:/ $ echo $EXTERNAL_STORAGE
/storage/sdcard0
Possibly just tweak this part of your script:
Before
Code:
/system/bin/mount -t vfat /dev/block/mmcblk1p1 $EXTERNAL_STORAGE
After
Code:
/system/bin/mount -t vfat /dev/block/mmcblk0p18 $EXTERNAL_STORAGE
This then sends the archive to a location that will always exist (sdcard0).
I mention as I don't always have external SD mounted.
Sent from my MB860 using Tapatalk 2
Thanks sendust7
Good job !

swap on jb

OK I got swap to work on my bionic, first make a swap file:
dd if=/dev/zero of=/data/cache bs=1024 count=568924
Or how ever many bytes you want it 568924 is over 500mb then with busybox use mkswap
busybox mkswap /cache/swap
Now copy the uuid that busy box has generated from mkswap and paste that uuid in /etc/fstab like below with none swap defaults 0 0
UUID-dhd53bg-75fhvf-this-is-the-uuid none swap defaults 0 0
Now try swapon /cache/swap.
If that fails you will need to download a custom ubuntu.IMG from here: http://www.4shared.com/zip/NKq5ucvZ/ubuntu.html
And a mounting script from zip below copy contents of zip to system/xbin/linux and system/xbin/linux.sh
chmod 755 /system/xbin/linux
chmod 755 /system/xbin/linux.sh
Then if you have the Ubuntu.IMG on sdcard-ext run in your terminal
linux
you should then be at [email protected] host of your Linux chroot try the procedure from above inside your [email protected] host and copy the uuid into the chrooted /etc/fstab and in your system/etc/fstab then try swapon /cache/swap. fstab should be 0644 permissions
If you get the Ubuntu.IMG and the scripts from below you now have a full Ubuntu desktop you can vnc into just type in the terminal :
[email protected]#./root/init.sh
the root/init.sh will start vncserver and gdm gnome will have flash 10.1 and Firefox Ubuntu app center all of which work great
Vncserver is
localhost
User is
localhost
Domain is localdomain
password is ubuntu
vnc port is
5901
http://www.4shared.com/zip/SGolTsWZ/linuxmount.html
Here isthe link http://sourceforge.net/projects/droidbionic.motorola/files/droidbionic/9.8.2O-72_VZW-22/ to the bionic jellybean kernel source if someone wants to build it from source and add swap/zram support or overclocking to add swap edit the config.gz CONFIG_SWAP=y
CONFIG_SWAP_PREFETCH=y
You don't need to add prefetch just supposed to help speed like readahead on sdcard.
If you get and use the ubuntu.img the scripts provided mount rw and kexec your kernel so if you know what your doing you could modify the kernel from inside your chrooted ubuntu or create and use modules for that kernel. You would have to build from source and have the jellybean kernel compiled but it is possible to do all of that from inside your chroot you would also probably need a 64GB sdcard and formatted to ext3 and modify the mount script to mount the ext3 not the .IMG if you want help with this I will provide the mounting script to change from .IMG to ext3 partition just message me

How to mount deprecated external_sd on Milaq's CM-11 KitKat rom

I'm still on 10.2 so I haven't tried this but give it a shot.
Milaq removed the mount configuration from fstab.tenderloin, init.tenderloin.rc, storagelist.xml, and recovery.fstab
if you look here on github.com/milaq/android_device_hp_tenderloin you can see the changes made if you click on "storage: prep webos-less setup"
removed from fstab.tenderloin:
-/devices/virtual/block/dm-6 auto vfats defaults voldmanaged=sdcard1:auto,nonremovable,noemulatedsd
removed from init.tenderloin.rc:
- mkdir /storage/sdcard1 0700 root root
- mkdir /mnt/media_rw/sdcard1 0700 media_rw media_rw
- export SECONDARY_STORAGE /storage/sdcard1
- symlink /storage/sdcard1 /mnt/external_sd
- symlink /storage/sdcard1 /external_sd
-service fuse_sdcard1 /system/bin/sdcard -u 1023 -g 1023 -d /mnt/media_rw/sdcard1 /storage/sdcard1
- class late_start
- disabled
removed from storagelist.xml:
- <storage android:mountPoint="/storage/sdcard0"
- <!-- internal sdcard partition -->
- <storage android:mountPoint="/storage/sdcard1"
- android:storageDescription="@string/storage_sd_card"
- androidrimary="false"
- android:removable="false"
- android:allowMassStorage="true" />
removed from recovery.fstab:
-/devices/virtual/block/dm-6 /external_sd vfat defaults voldmanaged=sdcard:auto,nonremovable
Larry
No easy solution
The files modified are packed into the boot.img file of the ROM. Therefore there is no easy way to provide a zip to flash and overwrite/update these files after flashing a new ROM.
I had entered the following into the terminal app and was able to get read/write access to the webos media folder:
su
busybox mount /dev/mapper/store-media /data/media/legacy
You should see the .palm folder and other files in /data/media/legacy from within android.
Instead I recommend deleting all files from LOST.DIR (recycle bin) in WebOS and then using Tailor to resize the /media partition down to 400mb and add the remaining space to /data as milaq suggested. This should negate the need to access it from android.
Jim
laspero said:
I'm still on 10.2 so I haven't tried this but give it a shot.
Milaq removed the mount configuration from fstab.tenderloin, init.tenderloin.rc, storagelist.xml, and recovery.fstab
if you look here on github.com/milaq/android_device_hp_tenderloin you can see the changes made if you click on "storage: prep webos-less setup"
removed from fstab.tenderloin:
-/devices/virtual/block/dm-6 auto vfats defaults voldmanaged=sdcard1:auto,nonremovable,noemulatedsd
removed from init.tenderloin.rc:
- mkdir /storage/sdcard1 0700 root root
- mkdir /mnt/media_rw/sdcard1 0700 media_rw media_rw
- export SECONDARY_STORAGE /storage/sdcard1
- symlink /storage/sdcard1 /mnt/external_sd
- symlink /storage/sdcard1 /external_sd
-service fuse_sdcard1 /system/bin/sdcard -u 1023 -g 1023 -d /mnt/media_rw/sdcard1 /storage/sdcard1
- class late_start
- disabled
removed from storagelist.xml:
- <storage android:mountPoint="/storage/sdcard0"
- <!-- internal sdcard partition -->
- <storage android:mountPoint="/storage/sdcard1"
- android:storageDescription="@string/storage_sd_card"
- androidrimary="false"
- android:removable="false"
- android:allowMassStorage="true" />
removed from recovery.fstab:
-/devices/virtual/block/dm-6 /external_sd vfat defaults voldmanaged=sdcard:auto,nonremovable
Larry
Click to expand...
Click to collapse
zoser42 said:
The files modified are packed into the boot.img file of the ROM. Therefore there is no easy way to provide a zip to flash and overwrite/update these files after flashing a new ROM.
I had entered the following into the terminal app and was able to get read/write access to the webos media folder:
su
busybox mount /dev/mapper/store-media /data/media/legacy
You should see the .palm folder and other files in /data/media/legacy from within android.
Instead I recommend deleting all files from LOST.DIR (recycle bin) in WebOS and then using Tailor to resize the /media partition down to 400mb and add the remaining space to /data as milaq suggested. This should negate the need to access it from android.
Jim
Click to expand...
Click to collapse
Excellent Job. You are right, I see no reason do continue using this partition. I was just wondering how it could be done.
could also use the native command
mount -t vfat /dev/mapper/store-media /data/media/legacy
laspero said:
Excellent Job. You are right, I see no reason do continue using this partition. I was just wondering how it could be done.
could also use the native command
mount -t vfat /dev/mapper/store-media /data/media/legacy
Click to expand...
Click to collapse
Thanks for the comments and creating the thread. I suggested creating a thread with someone else on milaq's thread since I thought it was off topic. I was using the native mount syntax early in my efforts but it was the last two parameters that were the problem.
Perhaps someone might try copying the boot.img from and earlier rom into a current rom but I have no idea if it is mostly the same or different every build. I wasn't willing to risk it but someone else may weigh in on that one. I think the changes should be in the ramcache part of boot.img.
I'm not saying it's impossible in a flashable zip but would demand a lot of time to a solution I have no intention of using.
---------- Post added at 04:50 PM ---------- Previous post was at 04:27 PM ----------
zoser42 said:
Thanks for the comments and creating the thread. I suggested creating a thread with someone else on milaq's thread since I thought it was off topic. I was using the native mount syntax early in my efforts but it was the last two parameters that were the problem.
Perhaps someone might try copying the boot.img from and earlier rom into a current rom but I have no idea if it is mostly the same or different every build. I wasn't willing to risk it but someone else may weigh in on that one. I think the changes should be in the ramcache part of boot.img.
I'm not saying it's impossible in a flashable zip but would demand a lot of time to a solution I have no intention of using.
Click to expand...
Click to collapse
It occurred to me that a "mini" build could be created that only changed the appropriate files but it would have to be kept up to date and runs counter to what milaq is trying to accomplish. I saw that some apps were even storing their data in the sdcard1(webos) folder so it was confusing android as it was. Also, I meant ramdisk and not ramcache in my previous post. My bad.
btw I branched miliq's build code and got to step 9 of 10 of cm's build instructions before running into trouble, just for the knowledge of what goes into it.

Can't use sdcard0 with cwm-6.0.4.7 on mini2

Hi,
i'm a new user and I can't add post to correct thread so I try to begin a new thread here.
I installed cwm 6.0.4.7-jena on my phone and all install process is been completed correctly but on reboot from cwn shell / menu I can't mount sdcard0.
This error from recovery.log file:
Code:
I:Checking for extendedcommand...
I:Skipping execution of extendedcommand, file not found...
I:Volume /storage/sdcard0 is not idle, current state is 2
Error mounting /storage/sdcard0!
File recovery.fstab it seems correct:
Code:
# cat /etc//recovery.fstab
# Android fstab file.
# The filesystem that contains the filesystem checker binary (typically /system) cannot
# specify MF_CHECK, and must come before any filesystems that do specify MF_CHECK
#<src> <mnt_point> <type> <mnt_flags and options> <fs_mgr_flags>
/dev/block/mmcblk0p8 /boot emmc defaults defaults
/dev/block/mmcblk0p12 /recovery emmc defaults defaults
/dev/block/mmcblk0p16 /system ext4 ro,barrier=1 wait
/dev/block/mmcblk0p18 /data ext4 nosuid,nodev,noauto_da_alloc,barrier=1 wait,check,encryptable=footer,length=-16384
/dev/block/mmcblk0p17 /cache ext4 nosuid,nodev,barrier=1 wait,check
# vold managed volumes
/devices/platform/msm_sdcc.3/mmc_host auto vfat defaults voldmanaged=sdcard0:23,noemulatedsd,nonremovable
/devices/platform/msm_sdcc.1/mmc_host auto auto defaults voldmanaged=sdcard1:auto,noemulatedsd
/devices/platform/msm_hsusb_host.0 auto auto defaults voldmanaged=usbdisk:auto
# zRam (zramsize = 64 megabytes)
/dev/block/zram0 none swap defaults zramsize=67108864
If I use last OmniROM I see that sdcard0 is not usable and this confirm like for cwn that cwn-6.0.4.7 that there is a problem with sdcard0 (internal)
But If I use last cm-10.1 sdcard0 is correctly usable sdcard yet if on cwn it isn't possible mount it.
So probably is there a bug on cwm-6.0.4.7 and omni-4.4.2-20140202-jenad-HOMEMADE.
Could be relative to a wrong partition data ? I try to format it from cwm but I receive error and I can't donwgrade to previous cwm-6.0.3.2 (that it works with sdcard0) because there is a check on status of the sdcard0.
Any suggestions ?
Thanks in advance

Categories

Resources