[Q] CyanogenMod 6.3.0 link2sd - Milestone XT720 General

Anyone get link2sd working with the latest CyanogenMod 6.3.0 from Moize yet?
Tried reformatting, keep running into the Mount script error.
"Mount script cannot be created.
mount: mounting/dev/block/vold/179:2 on /data/sdext2 failed: No such device"
For quick reference, it was working on Khalpower's EpicSteelBlue rom. I can't seem to get SU to run in adb shell either...
Any workarounds would be appreciated!
(I don't have enough posts to post in the main development thread yet.)

Can you run these commands (either in adb shell or terminal):
Code:
su
fdisk -l /dev/block/mmcblk0 > /sdcard/fdisk.txt
and then post the contents of /sdcard/fdisk.txt ?

I will try as soon as I get back home.
Restored my backup since I need to be heading out for now.

Back. Here are the contents of fdisk.txt.
Code:
Disk /dev/block/mmcblk0: 16.5 GB, 16574840832 bytes
255 heads, 63 sectors/track, 2015 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 1 1689 13566861 b Win95 FAT32
/dev/block/mmcblk0p2 1690 1885 1574370 83 Linux
/dev/block/mmcblk0p3 1886 2015 1044225 82 Linux swap
The native app2ext works, but I can't enable link2sd for some reason.

Raydonn said:
Back. Here are the contents of fdisk.txt.
Code:
Disk /dev/block/mmcblk0: 16.5 GB, 16574840832 bytes
255 heads, 63 sectors/track, 2015 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 1 1689 13566861 b Win95 FAT32
/dev/block/mmcblk0p2 1690 1885 1574370 83 Linux
/dev/block/mmcblk0p3 1886 2015 1044225 82 Linux swap
The native app2ext works, but I can't enable link2sd for some reason.
Click to expand...
Click to collapse
Can you try making an empty /sd-ext/link2sd directory and reboot? Or have you done that already?

Mioze7Ae said:
Can you try making an empty /sd-ext/link2sd directory and reboot? Or have you done that already?
Click to expand...
Click to collapse
I've tried that.
Link2sd won't recognize it for some reason on this rom.

I found some bugs in the link2sd init.d script. A hotfix can be found here:
http://forum.xda-developers.com/showpost.php?p=16757523&postcount=408

Thanks, link2sd is working now.
But there seems to be another problem I'm running into. I can't seem to get the system to mount anything but ext2.
So ext2? Link2sd and root explorer sees the sd-ext fine and reports the size, etc.
ext3 and ext 4? Unable to mount.
Perhaps there's something I'm overlooking, but I've reformatted the SD card several times now to no avail.

Try to manualy mount like:
mount /dev/block/mmcblk0p2 /sd-ext -t ext4(3) and reboot.

fjfalcon said:
Try to manualy mount like:
mount /dev/block/mmcblk0p2 /sd-ext -t ext4(3) and reboot.
Click to expand...
Click to collapse
Hmm, tried that.
Getting the error message
"mounting /dev/block/mmcblk0p2 on /sd-ext failed: No such device" for ext3.
"mounting /dev/block/mmcblk0p2 on /sd-ext failed: Invalid argument" for ext4.

ls /system/lib | grep ext
show input...

fjfalcon said:
ls /system/lib | grep ext
show input...
Click to expand...
Click to collapse
Code:
libext2_blkid.so
libext2_com_err.so
libext2_e2p.so
libext2_profile.so
libext2_uuid.so
libext2fs.so

Are you sure that u usyng cm 6.3.0?
Cause it has already build-in modules for ext4.
http://www.multiupload.com/VHPFIMOJTR
apply that update again, you don't need to make any wipes.(or just wipe cache...)

Hmm, tried updating/installing again.
Still no luck. Same results.
Does it matter that I skipped 6.1.2 and went straight to 6.3.0? Although that doesn't make much sense since you said 6.3.0 included the modules for ext4.
I also see ext2.ko, ext3.ko, ext4.ko in system/lib/modules so I assume it's all there.

Small update.
I don't know why, but link2sd is working now and apparently with ext4.
Maybe it's because I installed cm6.1.2 and then applied cm6.3.0 overtop it? I didn't factory wipe though, but it still works.
Or maybe it's because I used the new OR to update my ext2 to ext4 instead of fresh formatting it to ext4?
Or maybe the latest version of link2sd fixed ext4 support? I don't know.
But anyhow, thanks for all the help and the great ROM.

Raydonn said:
Or maybe it's because I used the new OR to update my ext2 to ext4 instead of fresh formatting it to ext4?
Click to expand...
Click to collapse
Probably this one. The ext4 update in the OR uses known-working ext4 options. I think there are some features that desktops turn on by default when formatting ext4 that don't work with our kernel. My guess is it's largefile support, but I haven't tested tested that hunch.

Related

Flashable Filesystem Check and Repair Tool

This flashable script will try to check and fix filesystem errors in your ext and fat32 partitions. The repair on fat32 may not be robust, but at least you will be alerted to any potential issues and can then run a dosfsck/chkdsk to fix issues,
This was created for my SuperNova Rom which uses Data2sd, but can be used for any Rom which uses an ext4 partition.
Potential candidates are phones with new issues of Force closes appearing, which usually signify a partition corruption..
Report on the file system check and repair will be output to /sdcard/repairlog.txt
This could be a "must-have" tool for every sdcard.
[*]Version History
FixFS 21-Sept-11
Initial script
FixFS 0.2 22-Sept-11
More checkpoints in logic
Verbose output
Any followups....
Nice one. If I had a partition to check, I'd definitely use this!
rootSU said:
Nice one. If I had a partition to check, I'd definitely use this!
Click to expand...
Click to collapse
Ha ha..
===================================
DROIDZONE'S FILESYSTEM FIXER SCRIPT
===================================
Script started at Thu Sep 22 00:36:27 GMT 2011
Ext4 file system found...
e2fsck running
One or more errors were found in your ext4 partition
e2fsck has encountered technical errors and cannot continue. Script will ABORT
Sdcard found..
Attempting to unmount sdcard
DosFsck running...
One or more errors were found in your Fat32 partition
dosfsck has encountered technical errors and cannot continue. Script will ABORT
Script has completed operations
-----
Above is my result of your awsome tool(thank you so much), seems some errors occured or found problems on my sd, but not fixed during the patch's on.
Would you give me a tip for the next step?
Sent from my HTC Desire using XDA App
You will have to do a manual e2fsck from the shell, since that usually means it is waiting for user intervention due to some errors. Though the automatic options I specified should correct minor issues, some seem to still need intervention
Sent from my HTC Desire using Tapatalk
nice work as per usual matey
ran it once through ROM Manager and your screen in recovery was only visible for a split second, so I checked the repairlog and read this:
===================================
DROIDZONE'S FILESYSTEM FIXER SCRIPT
===================================
Script started at Thu Sep 22 00:43:51 GMT 2011
Ext4 file system found...
e2fsck running
One or more errors were found in your ext4 partition
e2fsck has encountered technical errors and cannot continue. Script will ABORT
Sdcard found..
Attempting to unmount sdcard
DosFsck running...
One or more errors were found in your Fat32 partition
dosfsck has encountered technical errors and cannot continue. Script will ABORT
Script has completed operations
===================================
When I got home I checked the SD card through windows (no errors) then your script through Max's 4EXT app and no split second reading this time, it read:
===================================
DROIDZONE'S FILESYSTEM FIXER SCRIPT
===================================
Script started at Thu Sep 22 04:57:43 GMT 2011
Ext4 file system found...
e2fsck running
Your ext4 file system was checked and was clean..No repair was necessary.
Sdcard found..
Attempting to unmount sdcard
DosFsck running...
Your Fat32 file system was checked and was clean..No repair was necessary.
Script has completed operations
So a very big thank you to you and Max
Great tool! Thanks very much, have been looking for something like this for ages.
Hi Droidzone,
something goes wrong for me, i explain it with log below:
recovery.log
Code:
-- Installing: /sdcard/FixFS.zip
mtd: successfully wrote block at 0
I:Set boot command "boot-recovery"
Finding update package...
I:Update location: /sdcard/FixFS.zip
Opening update package...
Installing update...
about to run program [/tmp/pre.sh] with 1 args
===================================
DROIDZONE'S FILESYSTEM FIXER SCRIPT
===================================
Script started at Thu Sep 22 10:38:42 GMT 2011
Ext4 file system found...
e2fsck running
/tmp/pre.sh: line 56: /tmp/e2fsck: not found
One or more errors were found in your ext4 partition
e2fsck has encountered technical errors and cannot continue. Script will ABORT
Sdcard found..
Attempting to unmount sdcard
umount: can't umount /sdcard: Device or resource busy
DosFsck running...
/tmp/pre.sh: line 86: /tmp/fsck_msdos: not found
One or more errors were found in your Fat32 partition
dosfsck has encountered technical errors and cannot continue. Script will ABORT
Script has completed operations
The log file has been copied to sdcard_repairlog.txt
script result was [|______________________________________________|]
minzip: Extracted file "/tmp/e2fsck"
minzip: Extracted file "/tmp/fsck_msdos"
minzip: Extracted file "/tmp/pre.sh"
________________________________________________
| |
| PARTITION CHECK & REPAIR TOOL |
| ================================== |
| - DROIDZONE - |
| |
| This is an On-Demand Partition Fix tool. |
| If you find too many force closes or freezes |
| on your phone, it may be the first indication|
| of increasing corruption on your ext4 partit-|
| ion. Running this tool will fix most of them.|
| |
| |
| [*]Checking and Fixing File system... |
| [*]Checking Fat32 File system... |
| [*]Checking ext4 File system... |
| [*]Done |
| [*]Repair log in sdcard/repairlog.txt |
|______________________________________________|
Install from sdcard complete.
So, without reboot i connected my adb shell and i'd try manually (with /sdcard alredy unmounted)
Code:
/tmp # ls -ail
ls -ail
213 drwxr-xr-x 2 root root 0 Sep 22 10:38 .
1 drwxr-xr-x 19 root root 0 Sep 22 10:03 ..
722 -rw-rw-rw- 1 root root 10 Sep 22 10:04 4ext_version
721 -rw-rw-rw- 1 root root 3 Sep 22 10:04 batt_level
756 -rwxrwxrwx 1 root root 111492 Aug 1 2008 e2fsck
730 -rw-rw-rw- 1 root root 5 Sep 22 10:04 free_space
757 -rwxr-xr-x 1 root root 22640 Aug 1 2008 fsck_msdos
758 -rwx------ 1 root root 2490 Aug 1 2008 pre.sh
692 -rw-rw-rw- 1 root root 8502 Sep 22 10:49 recovery.log
715 -rw-rw-rw- 1 root root 72 Sep 22 10:03 sd_fstypes
764 -rwxr-xr-x 1 root root 255904 Sep 22 10:38 update_binary
/tmp # /tmp/e2fsck -af /dev/block/mmcblk0p2
/tmp/e2fsck -af /dev/block/mmcblk0p2
/sbin/sh: /tmp/e2fsck: not found
/tmp # /tmp/fsck_msdos -pf /dev/block/mmcblk0p1
/tmp/fsck_msdos -pf /dev/block/mmcblk0p1
/sbin/sh: /tmp/fsck_msdos: not found
/tmp # pre.sh
pre.sh
/sbin/sh: pre.sh: not found
/tmp # ./pre.sh
./pre.sh
===================================
DROIDZONE'S FILESYSTEM FIXER SCRIPT
===================================
Script started at Thu Sep 22 10:58:36 GMT 2011
Ext4 file system found...
e2fsck running
./pre.sh: line 56: /tmp/e2fsck: not found
One or more errors were found in your ext4 partition
e2fsck has encountered technical errors and cannot continue. Script will ABORT
Sdcard found..
Attempting to unmount sdcard
umount: can't umount /sdcard: Invalid argument
umount: can't forcibly umount /sdcard: Invalid argument
DosFsck running...
./pre.sh: line 86: /tmp/fsck_msdos: not found
One or more errors were found in your Fat32 partition
dosfsck has encountered technical errors and cannot continue. Script will ABORT
Script has completed operations
The log file has been copied to sdcard_repairlog.txt
/tmp # ./tmp/fsck_msdos -pf /dev/block/mmcblk0p1
./tmp/fsck_msdos -pf /dev/block/mmcblk0p1
/sbin/sh: ./tmp/fsck_msdos: not found
i can't understand why ./pre.sh: line 56: /tmp/e2fsck: not found
recovery is kidding me!?
anyway all seems ok using e2fsck built in recovery 4EXT 2.1.3RC4 (i used verbose option):
Code:
~ # e2fsck -afv /dev/block/mmcblk0p2
e2fsck -afv /dev/block/mmcblk0p2
730 inodes used (0.56%)
25 non-contiguous files (3.4%)
1 non-contiguous directory (0.1%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 720
259347 blocks used (49.47%)
0 bad blocks
0 large files
707 regular files
14 directories
0 character device files
0 block device files
0 fifos
0 links
0 symbolic links (0 fast symbolic links)
0 sockets
--------
721 files
Weird indeed that the files in /tmp cant be accessed. Anyway, I'll add code to abort script if the binaries cant be found..it doesnt look good with the script saying everything's working.. I didnt add verbose early because of the output (confuses newbies?), but I'll add it too.
Edit: Forgot to mention that I use 4ext too, and no such issues here.
Droidzone said:
Weird indeed that the files in /tmp cant be accessed
Click to expand...
Click to collapse
nope, file can be accessed! with cat /tmp/e2fsck i see correct output
Droidzone said:
I'll add code to abort script if the binaries cant be found..it doesnt look good with the script saying everything's working..
Click to expand...
Click to collapse
+1 lol
did you try with 4EXT 2.1.3RC4 too?
Droidzone said:
You will have to do a manual e2fsck from the shell, since that usually means it is waiting for user intervention due to some errors. Though the automatic options I specified should correct minor issues, some seem to still need intervention
Sent from my HTC Desire using Tapatalk
Click to expand...
Click to collapse
Really appreciate for your kind explanation ^^;
Then, could somebody inform me how to to do a manual e2fsck from the shell or any links shows relative information? I've already questioned it at Q & A, but so far nobody has answered...
limscap1 said:
Really appreciate for your kind explanation ^^;
Then, could somebody inform me how to to do a manual e2fsck from the shell or any links shows relative information? I've already questioned it at Q & A, but so far nobody has answered...
Click to expand...
Click to collapse
It was there in Ultrakiller's quote.
Code:
e2fsck -afv /dev/block/mmcblk0p2
The command is found in /system/bin usually..My flasher also copies that file to /tmp. So:
Code:
chmod 755 /tmp/e2fsck
/tmp/e2fsck -afv /dev/block/mmcblk0p2
I would be linked in first post, for all that users who can't use the droidzone's script.
Reboot in Recovery, and connect adb shell.
EXT4 REPAIR/CHECK
Code:
e2fsck -afv /dev/block/mmcblk0p2
e2fsck will check and repair ext4 partition if needed.
an example:
Code:
e2fsck -afv /dev/block/mmcblk0p2
730 inodes used (0.56%)
25 non-contiguous files (3.4%)
1 non-contiguous directory (0.1%)
# of inodes with ind/dind/tind blocks: 0/0/0
Extent depth histogram: 720
259347 blocks used (49.47%)
0 bad blocks
0 large files
707 regular files
14 directories
0 character device files
0 block device files
0 fifos
0 links
0 symbolic links (0 fast symbolic links)
0 sockets
--------
721 files
FAT32 REPAIR/CHECK
mount usb partition on pc using recovery menu.
Once connected usb cable and opened cmd on pc type:
Code:
chkdsk /R f:\
in my case fat32 partition is f:
chkdsk can take a while (around 20min)
an example of output here (sorry, italian OS, anyway in my case no errors found)
Code:
Il file system è di tipo FAT32.
Numero di serie del volume: B996-8582
Verifica dei file e delle cartelle in corso...
Verifica dei file e delle cartelle completata.
Verifica dello spazio disponibile in corso...
Verifica dello spazio disponibile completata.
Verifica del file system effettuata. Nessun problema rilevato.
13.525.072 KB di spazio totale su disco.
2.408 KB in 295 cartelle.
6.963.592 KB in 1.891 file.
6.559.064 KB disponibili.
8.192 byte in ogni unità di allocazione.
1.690.634 unità totali di allocazione su disco.
819.883 unità di allocazione disponibili su disco.
If i helped someone please hit thanks button!
First of all, thanks Droidzone for your work
I have run the tool and had this
e2fsck running
One or more errors were found in your ext4 partition
e2fsck has encountered technical errors and cannot continue. Script will ABORT
Sdcard found..
Attempting to unmount sdcard
DosFsck running...
One or more errors were found in your Fat32 partition
dosfsck has encountered technical errors and cannot continue. Script will ABORT
Script has completed operations
-----
Click to expand...
Click to collapse
When running e2fsck from adb doesn't find anything wrong:
(sorry can't copy/paste, I have attached an image)
And if I run a script (founded in a MIUI rom, a didn't remember what version) from gscript, called check sd it says:
Will be Check your SD Card from kernel message:
===============================================
[ 19.726623] mmcblk0: mmc1:b368 USD 7.46 GiB
[ 19.727478] mmcblk0: p1 p2 p3
[ 20.836303] EXT4-fs (mmcblk0p2): mounted filesystem without journal. Opts: noauto_da_alloc,data=ordered,commit=15,barrier=1,nouser_xattr,errors=continue
[ 24.104003] EXT4-fs (mmcblk0p2): mounted filesystem without journal. Opts: noauto_da_alloc,data=ordered,commit=15,barrier=1,nouser_xattr,errors=continue
[ 24.484558] EXT4-fs (mmcblk0p3): mounted filesystem without journal. Opts: noauto_da_alloc,data=ordered,commit=15,barrier=1,nouser_xattr,errors=continue
[ 26.537750] EXT4-fs (mmcblk0p3): mounted filesystem without journal. Opts: noauto_da_alloc,data=ordered,commit=15,barrier=1,nouser_xattr,errors=continue
===============================================
If you found error between two lines, then your SD card is broken.
Click to expand...
Click to collapse
The commands on that script are:
mkdir /sdcard/gscript/resources>/dev/null
clear
echo "echo Will be Check your SD Card from kernel message:" > /sdcard/gscript/resources/temp.sh
echo "echo ===============================================" >> /sdcard/gscript/resources/temp.sh
echo "dmesg|grep mmcblk0" >> /sdcard/gscript/resources/temp.sh
echo "echo ===============================================" >> /sdcard/gscript/resources/temp.sh
echo "echo If you found error between two lines, then your SD card is broken." >>/sdcard/gscript/resources/temp.sh
su</sdcard/gscript/resources/temp.sh
rm /sdcard/gscript/resources/temp.sh
Click to expand...
Click to collapse
If someone can help, I'll be really grateful. I have also tried repartitioning the whole SD card with gparted, but the problem still appears. I'm using Alex-V ROM d2ext with default kernel (snq-)
Thanks in advance
blackhawk_LA said:
First of all, thanks Droidzone for your work
I have run the tool and had this
When running e2fsck from adb doesn't find anything wrong:
(sorry can't copy/paste, I have attached an image)
And if I run a script (founded in a MIUI rom, a didn't remember what version) from gscript, called check sd it says:
The commands on that script are:
If someone can help, I'll be really grateful. I have also tried repartitioning the whole SD card with gparted, but the problem still appears. I'm using Alex-V ROM d2ext with default kernel (snq-)
Thanks in advance
Click to expand...
Click to collapse
That check in Miui seems to be at the kernel level..However imho I dont see an error...that line just seems to be the kernel output saying what ext4 options have been used for the mount (should be present for everyone ). Do you see any actual issues while using the card?
I haven't see any big issues, just noticed that the sdext restore from a nandroid seemed to take too much time (7-8 minutes for just 300mb) and that's why i used your tool and have a look at this post.
But everything is working fine (or it seems so), just wanted to know if my files could be starting to get corrupted or something.
Thanks
As far as my script is concerned..it depends on error code from e2fsck to report file system state. That particular error code means that a standard error level was not returned, so only a command line manual e2fsck will show exactly what was the system response. See Post #14 for how to do that.
Mmm this is what I did, I think. See the attached image in my other message; it seems there was no erros (0 bad blocks)
Hi, got an error in clockwork recovery : error in fixfsv0.2.zip ( status 0 ) installation aborted ..
any clues ?

A2SD, partitioning and Nand Switching (internal to external) for Optimus 3D

Please someone more experienced than me check the prosedure!!! Till I remove this line go with extreme caution
I have an enormous amount of applications inherited from the partition-able optimus 2x. I got optimus 3D as an upgrade but I couldn’t intall not even half of them. So I was trying to find ways to repartition /data as I had done with optimus 2x but with no success.
Then I got an idea... why not A2SD style? So it begins
Disclaimer: Have in mind that I’ve done nasty stuff which could brick the phone badly. I take no responsibility for breaking your phone even if you follow my guide perfectly. I am no developer and I can make mistakes so please don’t continue if you don’t understand what I am telling you to do. Also be careful since I dont know how future lg updates will react
My composition is: Thiaiz Rom V0.1, clockworkmod touch, rooted ofc and I have installed most drivers found on this forum for o3d.
Before you begin get a backup of your internal memory, sd card, titanium backup and nand backup to a pc. You WILL loose internal memory data. The rest just to be safe....
Drawbacks: Your internal memory will be around 2-3gbs smaller and wont be able to be mounted to the pc. You could brick your phone.
While all these can be done with a cwm zip script I did it manually. Also since my phone works fine know and my time is short I dont really want to go to the reformating coping restoring backups again. This means that while I write this guide I dont actually run these command only checking them if they are correct.
Lets start.
First shutdown your phone. Open it to recovery by pressing down button and power for 7-8 seconds. Release when you see LG logo. While in recovery connect your device with the pc with a usb cable. Open command prompt on your windows pc and do a
adb shell
Now you are probably ready to send commands. If not use a guide like this http://www.addictivetips.com/mobile/what-is-adb-and-how-to-install-it-android/
at the shell do a
Code:
# cd /dev/block
#ls
you will see all your partitions. mmcblk0 is the internal memory and mmcblk1 is the sd card.
Code:
# parted mmcblk0
(parted) print
now you see the partitions
You should see something like this
Code:
Number Start End Size File system Name Flags
1 131kB 262kB 131kB x-loader
2 262kB 393kB 131kB nv1
3 393kB 524kB 131kB nv2
4 524kB 1049kB 524kB u-boot
5 1049kB 11.5MB 10.5MB kernel
6 11.5MB 22.0MB 10.5MB recovery
7 22.0MB 651MB 629MB ext3 system
8 651MB 1725MB 1074MB ext3 userdata
9 1725MB 1859MB 134MB fsswap
10 1859MB 1926MB 67.1MB ext3 cache
11 1926MB 1928MB 2097kB ext3 lgdrm
12 1928MB 1929MB 1049kB divxkey
13 1929MB 1950MB 21.0MB fota
14 1950MB 1955MB 4194kB ext3 misc
15 1955MB 7944MB 5989MB fat32 msftres
we are going to work on partition 15 starting by deleting it. Be very carefull here what you delete
Code:
(parted) rm 15
now we want to create 2 more partitions. The 1955-4944 and 4944-7944 will give you around 3gb for apps and 3gb for internal memory. Tweak it at your needs but always follow the numbers. I meant if your print gave you this output
Code:
15 1955MB 7945MB 2989MB fat32
use 7945 and not 7944
Code:
(parted) mkpartfs primary fat32 1955 4944
(parted) mkpartfs primary ext2 4944 7944
now the command print should give you two more partitions
Code:
15 1955MB 4944MB 2989MB fat32 msftres
16 4944MB 7944MB 3000MB ext2
quit parted to update the ext2 to ext3
Code:
(parted) quit
#mke2fs /dev/block/mmcblk0p16
#tune2fs -j /dev/block/mmcblk0p16
Now our phone is ready for A2SD. Reboot the phone.
After finish rebooting continue via adb or terminal (I used terminal because I was in a 3 hours trip with bus ) and es file explorer with root and rw options on
we need to tweak /etc/vold.fstab to change the mount points. You can change it with es file explorer
My file is:
Code:
dev_mount sdcard /mnt/sdcard auto /devices/platform/mmci-omap-hs.0/mmc_host/mmc1
dev_mount extsdcard /mnt/sdcard/_ExternalSD 15 /devices/platform/mmci-omap-hs.1/mmc_host/mmc0
then we need to create the mount point for our new partition. I did it at /mnt/a2sd but you can do it anyware including the standard /system/sd
Code:
#mkdir /mnt/a2sd
#mkdir /mnt/emmc
now we need to mout our new partition everytime the system starts. I opened /etc/init.d/thiaizSDbooster and added few lines
Code:
mkdir /mnt/a2sd
mount -w /dev/block/mmcblk0p16 /mnt/a2sd
mkdir /mnt/emmc
mount -w /dev/block/mmcblk0p15 /mnt/emmc
ln -s /mnt/a2sd/data/app /data/app
ln -s /mnt/a2sd/data/data /data/data
dont forget to make the correct permitions again after the edit
now you need to mount the new partition to your mount point
Code:
#mount -w /dev/block/mmcblk0p16 /mnt/a2sd
and copy the data files you will link there
Code:
#cp -a /data /mnt/a2sd
now careful youll delete the /data/app and /data/data from /data
Code:
#rm -r /data/app
#rm -r /data/data
and create the links
Code:
#ln -s /mnt/a2sd/data/app /data/app
#ln -s /mnt/a2sd/data/data /data/data
Reboot the phone and you are ready to go!
To mount the sd card to the pc you will need an app from market https://market.android.com/details?id=com.rafoid.multimountsdcard.widget.free
Look atached images for what you get
want to give it a try but I need to know if there is a way to revert back if anything goes wrong. Will a restore of a previous backup return things to normal?or flashing a kdz? thanx anyway.any try to improve our phones is worth praize...
jimakos29 said:
want to give it a try but I need to know if there is a way to revert back if anything goes wrong. Will a restore of a previous backup return things to normal?or flashing a kdz? thanx anyway.any try to improve our phones is worth praize...
Click to expand...
Click to collapse
Make a nand back-up in another sd card, if you re lucky and can still boot upto recovery then you can restore or you can boot to download mode. Last resort will be to flash a bin or kdz file then restore your nand back up.
I bricked my phone 5 times in one month 2 times in 1 day. I still figured how to restore, just relax and think before you do crazy stuff, all the answers are in XDA.
---------- Post added at 04:44 AM ---------- Previous post was at 03:49 AM ----------
@orlox tested it and gives me phone memory damage, forgot to pull the logs and do some ss, well anyways I won't be doing this one, I was setting up for the s2e and link2sd stuff -- that one is not that risky.
mtvtitan said:
tested it and gives me phone memory damage, forgot to pull the logs and do some ss, well anyways I won't be doing this one, I was setting up for the s2e and link2sd stuff -- that one is not that risky.
Click to expand...
Click to collapse
The "damage part" is because you probably didnt change the vold file. Its not something to worry. After you tell vold what partition to mount (15) it will be ok
orlox said:
The "damage part" is because you probably didnt change the vold file. Its not something to worry. After you tell vold what partition to mount (15) it will be ok
Click to expand...
Click to collapse
I figured that one...
have you finished the guide? all ok?
orlox said:
have you finished the guide? all ok?
Click to expand...
Click to collapse
not yet, got other stuff in hand... i'll try to report tom* its already 2am here and have work at 4am -- cooked.
I made a mistake somewhere and am stuck. Can't sleep now, I'll have to figure this thing thorough.
---------- Post added at 07:20 AM ---------- Previous post was at 07:12 AM ----------
btw you can try this --> install link2sd let it install the script needed to mount 2nd sd part, then edit it (init.d folder)
--> add this before mounting sdext2
sleep 2
mkdir /sd-ext
sleep 2
--> then after mounting sdext2 insert this
sleep 2
mount -o bind /data/sdext2 /sd-ext
-----------------------------------------
install s2e
move dl cache (dont move any apps, let link2sd do that)
reboot.
----------------------------------------------
works with thiaz boot image only
the risk is low and would not probably brick your phone but try it at your own risk (disclaimer) --> this is generic, do your mods.
any problems will discuss after I unbrick my phone lol.
Generic scripts are not working well. I was trying with dark tremors first. I think manual is safer. Also Someone may want to partition sd instead of nand. Its safer but I think its a waste of space.
The good thing is that parted works so we don't need a tool like nvflash. Also /data had a limit at 2GB I think. With a2sd there is no limit.

Boot loop Unresolvable? Hardware problem?

Hey all, new to xda. Hope I'm not asking stupid questions.
My friend gave me a Galaxy S to fix. Model: GT-I9003.
It has a boot loop problem, cycling the Samsung introduction animation (and sound first time round). The recovery mode didn't work to start with - also trapped in a boot loop.
I followed the instructions here (using Odin3 v1.85) and flashed XXKPE. It seemed to all work fine, but the boot loop remained. I booted it into recovery mode and the following error messages appear.
E:failed to mount /data (No such file or directory)
Click to expand...
Click to collapse
and under -- Wiping data...
E:format_volume: rfs format failed on /dev/block/mmcblk0p3
Click to expand...
Click to collapse
then
Data wipe failed.
Click to expand...
Click to collapse
From my research I believe it's a corrupted internal SD-Card and is fixed via parted? Could anyone go into more detail on how I would do this?
Many thanks.
I am facing a similar problem on my Galaxy SL... Need a solution too... I would appreciate any help...
Data partition has been corrupted, try flashing userdata.rfs with heimdall. A friend of mine had an stock/untouched phone and this happened to it, even with the corrupted partition i was able to boot cyanogenmod, and tried a lot of things, but nothing worked, it was on warranty, so i flashed back the original firmware and he took it to the service center.
If you want to try do this:
Flash bam kernel PDA_BCK_CF-root_universal_beta14fix.tar (http://forum.xda-developers.com/showthread.php?t=1355675)
Then from CWM flash cyanogenmod (i used cm7, but you can try with cm9)
after that the phone should boot into cyanogemod and give an error on the notification bar
extract the 6 files off the zip i attached and copy them to /xbin
from terminal emulator or adb shell run this for the 6 files:
Code:
chmod 0755 <file>
then run:
Code:
parted /dev/block/mmcblk0 mkfs ext2
When it asks for the partition number, enter 3
finally reboot, and if it worked you can flash a stock rom again, thats it, good luck
My phone boots up, but there are random reboots. Tried a lot of stock and custom ROMs... Nothing works... Warranty expired last week...
Thanks for your time. I appreciate it.
bruisedcrow said:
Thanks for your time. I appreciate it.
Sorry, I'm very new at this - my first hour doing this kind of thing. Could you explain the procedure in more detail - I would like to learn (make the best of a bad situation).
Am I right to say that the Bam Custom Kernel gives super-root level privileges? Allowing the CWM to fiddle with partions?
I've downloaded the normalboot.img for BCK. How do I flash this to my device? Could you link me to a tutorial?
EDIT: Alternatively could you point me to all the prerequisites I need to properly understand the problem and the methods required to fix it?
Click to expand...
Click to collapse
I tried that... My phone was booting up...
I have Android SDK on my PC... It includes some tools like ADB.
If your phone is rooted, you can use ADB to do things, like formatting...
Connected my phone. Booted into recovery. From Command Prompt, I went to ADB folder, then typed "adb shell". Then, typed in the parted command, and followed steps. Successfully done...
But the problem continues...
I have found many other users have faced this problem -- http://forum.xda-developers.com/showthread.php?t=1736118
I am disappointed. My phone is no longer in warranty... I am too late...
it is possible that using cyanogenmod and S2E (simple2ext) will work as a workaround until you send it to service center.
grab a copy of s2e and push it to /system/app/
Repartition your External-SD using the same method used for phones with low storage capacity, warning: it will erase all the data in it, so make backups
Start s2e and mark to move:
App and Private app
Applications data
Dalvik and download cache
This makes another partition, and it does not fix data, but at least you should be able to install apps.
I face this problem too. Please someone give us the solution.
Update: I flashed BAM Custom Kernel and put it in recovery mode. Attached it to the computer, but I'm stuck at this error message.
Thanks again.
More information
EDIT: There doesn't seem to be a /data partition at all! I feel I'm getting closer to fixing this.
There are 2 storages chips on this phone, one is mmc and the other is onenand.
I think the mmc chip is dead... it contains both /data and internal-SD, the onenand still works, it contains (system cache and dbdata), you can still use the phone with cyanogenmod if you mount everything that should go on /data on a partition in the external-SD, (the method i described with s2e). However there are some drawbacks, the SD needs to be class 6 or above to maintain the system speed, and the life of the sd is going to be reduced because of the more intensive use.
alfrix said:
There are 2 storages chips on this phone, one is mmc and the other is onenand.
I think the mmc chip is dead... it contains both /data and internal-SD, the onenand still works, it contains (system cache and dbdata), you can still use the phone with cyanogenmod if you mount everything that should go on /data on a partition in the external-SD, (the method i described with s2e). However there are some drawbacks, the SD needs to be class 6 or above to maintain the system speed, and the life of the sd is going to be reduced because of the more intensive use.
Click to expand...
Click to collapse
Thanks. Is there a way to replace the mmc chip without sending it to Samsung?
I've flashed XXFPE then Bam Custom Kernel then when I try install cm7 from CWM it gives:
Checking state of RFS/EXT4...
assert failed: run_program("/tmp/updater.sh") == 0
E: Error in /emmc/update-cm-7.1.0-GalaxySL-Kang-singed.zip
(Status 7)
Installation aborted.
Trying with MIUI instead.
EDIT: MIUI does this too.
How do I get around this? Can't I flash cm7 via Odin like the stock roms?
bruisedcrow said:
Thanks. Is there a way to replace the mmc chip without sending it to Samsung?
I've flashed XXFPE then Bam Custom Kernel then when I try install cm7 from CWM it gives:
Checking state of RFS/EXT4...
assert failed: run_program("/tmp/updater.sh") == 0
E: Error in /emmc/update-cm-7.1.0-GalaxySL-Kang-singed.zip
(Status 7)
Installation aborted.
Trying with MIUI instead.
EDIT: MIUI does this too.
How do I get around this? Can't I flash cm7 via Odin like the stock roms?
Click to expand...
Click to collapse
I think that the problem is when /tmp/updater.sh tries to mount /emmc your internal memory (EDIT: I've just noticed you tried with CM7, so, if I remember correctly, /emmc is the external memory, but I think that the problem is always the impossibility to mount the internal memory.) to backup your /efs directory. Because of the not avaible internal memory (/emmc) it simply exits and aborts the installation.
A simple change in updater.sh will allow you to install CyanogenMod, but wait for a confirmation from alfrix, maybe there's something more.
Anyway here there's a thread of a user with the same problem, he solved this by using the external SD as internal SD, as alfrix suggested.
strange, before touching anything try with the release i used that time (14.12.2011), if it doesn't work, then edit the updater.sh and remove
Code:
if ! /tmp/busybox mount -t ext4 /dev/block/mmcblk0p3 /data ; then
/tmp/busybox umount /data
/tmp/make_ext4fs -b 4096 -g 32768 -i 8192 -I 256 -a /data /dev/block/mmcblk0p3
fi
EDIT: is there any mmcblk on /dev/block?
Code:
ls /dev/block/
Weird the has mmcblk0 reappeared.
Code:
~ # ls /dev/block
ls /dev/block
bml0!c bml6 loop6 ram13 ram9 stl6 tfsr2
bml1 bml7 loop7 ram14 stl1 stl7 tfsr3
bml10 bml8 mmcblk0 ram15 stl10 stl8 tfsr4
bml11 bml9 mmcblk0p1 ram2 stl11 stl9 tfsr5
bml12 loop0 platform ram3 stl12 tfsr0!c tfsr6
bml13 loop1 ram0 ram4 stl13 tfsr1 tfsr7
bml2 loop2 ram1 ram5 stl2 tfsr10 tfsr8
bml3 loop3 ram10 ram6 stl3 tfsr11 tfsr9
bml4 loop4 ram11 ram7 stl4 tfsr12
bml5 loop5 ram12 ram8 stl5 tfsr13
So I tried
Code:
C:\Users\Bruised>adb shell
~ # /sbin/parted /dev/block/mmcblk0 mkfs ext2
/sbin/parted /dev/block/mmcblk0 mkfs ext2
Warning: The existing file system will be destroyed and all data on the
partition will be lost. Do you want to continue?
/sbin/parted: invalid token: ext2
Yes/No? y
y
y
Partition number? 3
3
3
Error: Partition doesn't exist.
~ #
That mmcblk is you externalSD its 0 because the internal is missing/broken and it has only 1 partition, because you didn't do the Repartition yet.
Sent from my GT-I9003 using xda app-developers app
alfrix said:
That mmcblk is you externalSD its 0 because the internal is missing/broken and it has only 1 partition, because you didn't do the Repartition yet.
Sent from my GT-I9003 using xda app-developers app
Click to expand...
Click to collapse
What should I try next? 14.12.2011 download link is down.
try with this:
https://dl.dropbox.com/u/5013311/test_for_broken_mmc_cm-9-20120626-UNOFFICIAL-galaxysl.zip
alfrix said:
try with this:
https://dl.dropbox.com/u/5013311/test_for_broken_mmc_cm-9-20120626-UNOFFICIAL-galaxysl.zip
Click to expand...
Click to collapse
It installs it.
Code:
Checking state of RFS/EXT4...
Install from sdcard complete.
After I reboot CM9 boot screen loads then I get "Encryption unsuccessful" as shown here
After rebooting I get
Code:
CWM-based Recovery v5.5.0.4
Formatting /data...
E:format_volume: make_extf4fs failed on /dev/block/mmcblk0p3
Formatting /cache...
Data wipe failed.
Heres the log file from the sdcard:
Code:
+ /tmp/busybox test -e /sdcard/backup/efs/nv_data.bin
+ /tmp/busybox mount -t ext4 /dev/block/stl9 /system
+ /tmp/busybox mount -t ext4 /dev/block/stl10 /dbdata
+ /tmp/busybox mount -t ext4 /dev/block/stl11 /cache
+ /tmp/busybox umount -l /system
+ /tmp/busybox umount -l /cache
+ /tmp/busybox umount -l /data
umount: can't forcibly umount /data: Invalid argument
+ /tmp/busybox umount -l /dbdata
+ /tmp/busybox umount -l /efs
umount: can't forcibly umount /efs: Invalid argument
+ exit 0

[Q] Adb shell/terminal

what exactly does adb shell mount do?
Edit: When I input
mount -t ext4 /dev/block/mmcblk0p25 /data
I get the output
mount: Invalid argument
Edit: I made a new ext2 filesystem in mmcblk0p25, how can I mount it?
Syreth said:
what exactly does adb shell mount do?
Click to expand...
Click to collapse
It allows you to mount partions on your phone such as /system so you can edit stuff in that partion (that's why I read)
A_Bunny said:
It allows you to mount partions on your phone such as /system so you can edit stuff in that partion (that's why I read)
Click to expand...
Click to collapse
I tried to mount -t ext4 dev/block/mmcblk0p25 /data and I got mount: Invalid arguement...
probably you should check your filesystem mmcblk0p25
>if it doesnt exist, create one using mkfs
>if it is corrupted, check & repair it using fsck
samsungrockz said:
probably you should check your filesystem mmcblk0p25
>if it doesnt exist, create one using mkfs
>if it is corrupted, check & repair it using fsck
Click to expand...
Click to collapse
I don't have those commands..
Nevermind, I have e2fsck, but e2fsck -pcfv /dev/block/mmcblk0p25 gives the output
e2fsck -pcfv /dev/block/mmcblk0p25
e2fsck: Bad magic number in super-block while trying to open /dev/block/mmcblk0p
25
/dev/block/mmcblk0p25:
The superblock could not be read or does not describe a correct ext2
filesystem. If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
e2fsck -b 8193 <device>.
EDIT

ZP980 unbrick/study of partition table

Hi to all, I hope to be posting in the right section...otherwise...punish me plz
It's a long story, so i hope that someone has time and want to put some effort to help me understand what i'm doing wrong.
By the way i work in IT field and have some knowledge about linux (let's say 5 on 10) but not so many on how android really works, but i'm confortable with custom recovery and roms, i'm still using an s4 mini (GT-I9195) with mine android 9 custom rom and i'm super happy with it.
Now that presentation are done , here is the matter.
I've found an old zp980 32GB (NOT the "plus one") that some years ago i've rooted it flashed with recovery and custom rom. all was working, but at some point i started playing with fdisk and parted and i messed up things.
Honestly i don't remember what exactly i was doing, but now the status of the phone is:
System not booting
I can enter into Recovery (custom TWRP by dezmen3 v2.4.4.0)
I can connect to adb into recovery
I cannot flash rom trough recovery due the actual system partition (589 MB)
I cannot flash the original rom trough SP flash tool due "SFT enable dram failed (4032)" error
The partitions actually are (what i can see from recovery):
System (589 MB)
Data (54MB)
Boot (6 MB)
Recovery (6MB)
Cache (4 MB)
uboot(0 MB)
nvram (5 MB)
Free space: 27412 MB
Actually, I've tried to reformat the memory using SP flah tool, but i got the same error "SFT enable dram failed (4032)", all drivers are ok, i can see COM port in deivce manager tried win 10 and even win 7.
SP tool ver. used v5 1720 more updated version tells me that the brick i'm tringo to flash in not supported anymore xD
Here a dump of fdisk -ul /dev/block/mmcblk0 from adb shell
Bash:
Device Boot Start End Blocks Id System
/dev/block/mmcblk0p1 1024 1022 2147483647+ 5 Extended
Partition 1 does not end on cylinder boundary
/dev/block/mmcblk0p2 26624 47103 10240 83 Linux
Partition 2 does not end on cylinder boundary
/dev/block/mmcblk0p3 47104 67583 10240 83 Linux
Partition 3 does not end on cylinder boundary
/dev/block/mmcblk0p4 93184 105471 6144 83 Linux
Partition 4 does not end on cylinder boundary
/dev/block/mmcblk0p5 134144 1465343 665600 83 Linux
/dev/block/mmcblk0p6 4869120 1022 2145049599+ 83 Linux
if i make a print from parted (pushed with adb) I get:
Error: Can't have a partition outside the disk!
Before i was also having an error saying that there was an extended partition into a logical one (don't ask me how I do it), but i removed it
So, now....what to to to rescue this device?
by the way honestly except for the instinct of "recover things that doesn't work" my main purpose is understand:
What I've messed on the partitions
Why sp flash tool can't reformat/flash the memory (i haven't tried to manually modify it again)
no brave person hat want to help me to brick it in a bad way?
EDIT NEW INFO
i've understtod that the problem was caused by
/dev/block/mmcblk0p1
and
/dev/block/mmcblk0p6
start and end were inverted , them were overflowing.
Now i used fdisk to remove part 1 (the extended), so i've lost also 5 and 6 (system and cache) and i have recreated them using 1 GB for each and using correct sector order.
now SD and try to flash a ....random compatible rom....see u later for info.
Cross your finger for me xD
flash failed it cant mount system and emmc.....
and now
~ # cat /etc/fstab
/cache ext4 rw
/data ext4 rw
/emmc vfat rw
/system ext4 rw
/sdcard vfat rw
/sd-ext auto rw
if someone has a zp980/c2 working can please post me the result of
cat /etc/fstab
from adb shell??
and a fdisk -ul?

Categories

Resources