[Q] Possible Brick? internal SD card seems to be "stuck" as is. WEIRD - G Tablet Q&A, Help & Troubleshooting

Okay guys, so here's a weird one.
My g-tablet was working great. Was running VEGAn-Tab Build, BETA 5.1.1, no reason to update it, because it did everything I needed. I finally had it to where I wanted it, then it all kind of started falling apart. Here's how.
I power it on and notice my home screen got all messed up for some reason (using launcher pro). All of the settings defaulted to the original. I tweaked it back to more or less how I wanted it, and when I had it back to normal, thought nothing better of it. Must have glitched out some how.
Then I notice a bunch of things starting to force close, specfically android market, amazon market, titanium backup, google services framework, launcher pro, etc. Odd thing is it would do it one at a time, but otherwise my tablet would carry on as normal.
I go ahead and restart the tablet, to see if that helps at all, and what do you know, the homescreen is messed up again! I thought launcher pro might have been the culprit, so I un-installed the app and rebooted... And launcher pro is still there.
I go ahead and delete it again and start deleting other apps, restarting the tablet, and no matter what I do, everything stays the same. time for some clockwork mod action. I go into clockwork mod, and try to do the factory reset option, thinking what the hey, I'll try anything right now. Hit it, mourn the loss of my user data, and reboot the system... and again, everything is still the same.
I hook up my tablet to the computer via usb, and it looks like I'm able to at least delete misc. files that way. But when I return to good old Tabatha (my nickname for Gtab) everything is stuck just the way it is.
Needless to say, it feels like I'm stuck in the twilight zone.
I know I should have researched it by now, but I'm going to finally look it up to see if I can recover with NVFlash (I know I know, very noobish of me, using strange roms and not knowing any of the basics).... but I'm increasingly worried I've got some kind of a hardware malfunction on my hands. Could it be the memory? The internal SD card?
Oddly enough, my tablet still functions... I can browse the web, hook it up to my computer, etc etc, but no matter what I do I can't alter the data I already have on my tablet. Can't delete things, can't change settings, update apps, etc. etc. Which makes it pretty much useless for what I wanted to use it for.
I finally realized what this is like. The movie groundhog day, and I'm stuck in the same day, over and over again.
Any help or input that might get me out of this mess would be greatly appreciated.
Phil: "I was in the Virgin Islands once. I met a girl. We ate lobster, drank piña coladas. At sunset, we made love like sea otters. *That* was a pretty good day. Why couldn't I get *that* day over, and over, and over..."

This is now the second time that I've seen this exact same problem. I was in the process of troubleshooting the original one when the user returned his gTablet for replacement. If you can stand the deja vu, read this thread.
Do not nvflash your tablet--nvflash cannot fix SD-card related problems. Read this post for why not.
Instead, do this for me: Reboot the gTablet, then open a Terminal, or, use adb and run this command:
Code:
$ dmesg > /mnt/sdcard/dmesg.txt
Attach that dmesg.txt which will contain messages from the kernel to your next post.
I'll check this thread in the evening.

rajeevvp said:
This is now the second time that I've seen this exact same problem. I was in the process of troubleshooting the original one when the user returned his gTablet for replacement. If you can stand the deja vu, read this thread.
Do not nvflash your tablet--nvflash cannot fix SD-card related problems. Read this post for why not.
Instead, do this for me: Reboot the gTablet, then open a Terminal, or, use adb and run this command:
Code:
$ dmesg > /mnt/sdcard/dmesg.txt
Attach that dmesg.txt which will contain messages from the kernel to your next post.
I'll check this thread in the evening.
Click to expand...
Click to collapse
Thanks for the direction, at least I know it isn't an isolated incident. It's 1:45 AM where I am right now, and I have to wake up for work in about 5 hours... So I probably won't be able to get in depth with the follow up on this stuff untill after work tomorrow night (so long as the wife doesn't hog the computer )
Again thanks for the quick response, I appreciate you pointing me into some sort of direction. Can't wait to try to get this sorted out!

Currently trying to figure out how to get ADB going.... pretty intimidating, but I'm trying. I got the Java JDK installed, installing the SDK, but can't find the "SDK Setup.exe" file or even a USB driver folder in the SDK directory. Got a good resource for getting ADB set up?

Save yourself some trouble. Got to http://www.knoppix.org/ and download the latest Knoppix live CD image.
Burn it, boot it, then use the adb executable from this post. For simple things like just running adb, you don't need the entire Android SDK.
Get me a dmesg while inside ClockworkMod:
Code:
$ [B]sudo ./adb shell dmesg > dmesg.txt[/B]
ADB commands documentation

Thanks, I'll try it out sometime this weekend!

Well, I really screwed myself now. I got the Linux distro loaded but still couldn't figure out how to get ADB to work. For whatever reason, When I boot from the DVD, I can't download the zip from within linux (get errors) and I could not open the ADB command by navigating to where I have it extracted in my hard drive. [Do I need to load the OS onto a flash drive instead?]
So I started messing with some stuff in clockwork mod. I apparently really goofed it, and I got a "Magic Value Mismatch" error everytime I tried to boot it up.
I looked up Magic Value Mismatch, and from there it pointed to using NVFlash to try to fix that problem. So tried that. After I flashed it, I thought for sure I finally had it back to stock, as the intro screen started to show the tap n tap logo... but i basically got stuck in a boot loop, tap n tap, then "n", then tap n tap, then "n", etc, until it dies.
I looked up this issue and apparently the key is to get into clockwork mod and do factory reset, reset cache, and partition the SD card to 2048 and 0, which I did... (per post #4 on this thread: http://www.slatedroid.com/topic/17501-helpstuck-in-bootloop/ ) but still no dice.
Not sure where to go from here, or if I can even get it to interface with ADB in its current state. Looks like I'm done for
Thanks for trying though

On second thought, I may have had a breakthrough, at least in getting ADB to see my tablet!!! Woohoo! It finally sees the device and has a serial number. Was following the device on this thread:
http://www.androidtablets.net/forum/viewsonic-gtablet-technical/5377-adb-g-tab-step-step.html
7. under the "[Google.NTx86]" section, paste the following:
Code:
;NVIDIA Tegra
%SingleAdbInterface% = USB_Install, USB\VID_0955&PID_7000
%CompositeAdbInterface% = USB_Install, USB\VID_0955&PID_7100&MI_01
save the file and exit.
But I have a 64 bit machine, so I finally figured it out and plopped that into the 64 bit portion of the .inf file. DOH!
So now let me see what I can drum up through the previous commands above.... though the parameters have changed now to be sure... Due to my haste things may have taken a turn for the worse.
To recap, now my tablet is stuck in a boot loop after having done NV Flash, after having screwed up some settings in clockwork mod trying to fix a "Magic Value Mismatch" error.

Tried:
$ dmesg > /mnt/sdcard/dmesg.txt
I just run this in the cmd prompt at my platform-tools directory where the adb is correct?
All it says is, "The system cannot find the path specified."
Am I doing something wrong, or is my tablet that messed up?

Okay, this is slightly weird. So I was browsing around in clockwork mod, and lo and behold, the original zip flies for vegan tab are all STILL THERE. So I reloaded them... And My tablet zips back to exactly the way I had it before!
Only this time, so far no force closes. This looks way too good to be true after what I've been through. I'm going to try modifying some files and settings and restart my tablet to see what it does. I'm pretty sure I can't be out of the woods yet. Allthough it is 3:33 AM as this is happening... magic hour. I may be going insane.
EDIT: Nope, was definitely way too good to be true. All my data is as stuck as it was ever was. But at least now I can get into it again. But now we're back to square one. Lemme figure out this dmesg business and get back to you. X(

So I would try issuing the following exactly in the command line at the adb platform tools folder:
$ dmesg > /mnt/sdcard/dmesg.txt
Is that code supposed to be copy and paste in? I don't seem to be getting anything. I can do the following command and get the info to pop into the command interface:
adb shell dmesg
But I can't figure out how to save that to a text file. And you want me to do that while the g tablet is in recovery, correct?
FYI, trying to do it through Windows 7. Would that command only operate in the linux environment via knoppix?
Thanks

titobetlogs said:
I can do the following command and get the info to pop into the command interface:
adb shell dmesg
But I can't figure out how to save that to a text file.
Click to expand...
Click to collapse
Redirect the output to a file:
Code:
C:\SOME\PATH> [B]adb shell dmesg > dmesg.txt[/B]
titobetlogs said:
I got the Linux distro loaded but still couldn't figure out how to get ADB to work. For whatever reason, When I boot from the DVD, I can't download the zip from within linux (get errors) and I could not open the ADB command by navigating to where I have it extracted in my hard drive.
Click to expand...
Click to collapse
I suggested using Knoppix just because it is so easy to use adb in Linux. Broken-down steps for future reference:
1. Download and burn the latest Knoppix Live CD iso image. Check the downloaded file size. The .iso file should be ~700MB in size. Also, test the CD by booting it and then typing at the boot prompt: knoppix testcd
2. Boot Live CD and skip the creation of any partition or file to store user data. After all, we just want to run adb.
3. After Knoppix has booted into the desktop, run a browser, right click on the adb.zip attachment in this post, then select "Save Link As..." and save the zip file into /tmp.
4. Connect the gTablet to the PC via the USB cable.
5. Open a terminal window, then type in it:
Code:
hostpc$ [B]cd /tmp[/B] [I]Change to the dir. where adb.zip was saved[/I]
hostpc$ [B]unzip adb.zip[/B] [I]Unzip zip file[/I]
hostpc$ [B]ls -l adb[/B] [I]Check if the adb program was extracted OK[/I]
-rwx------ 1 rvp rvp 159620 Dec 1 22:23 adb
hostpc$ [B]chmod 555 adb[/B] [I]Make adb executable.[/I]
hostpc$ [B]sudo ./adb shell dmesg > dmesg.txt[/B]
Note 1: do not type in the shell prompt, 'hostpc$'. It is only there to show you what the screen should (roughly) look like.
Note 2: If adb says something like "device not found", just unplug the USB cable from the PC, wait a few moments, then re-plug the cable and re-run the adb command again.
6. Go back into the browser and attach the dmesg.txt file that is there in /tmp. You will have to tell the Noscript plugin to allow scripts from xda-developers to enable attachments. Right click on the page, then select the Noscript menu item, then choose "Temporarily allow xda-developers.com".
I thought for sure I finally had it back to stock, as the intro screen started to show the tap n tap logo... but i basically got stuck in a boot loop, tap n tap, then "n", then tap n tap, then "n", etc, until it dies.
Click to expand...
Click to collapse
I'm not surprised. If the files on the internal SD card cannot be modified then that boot loop behaviour is to be expected. Here's why:
Android requires certain partitions to exist on the system. These partitions can be either on the flash or on SD cards. The partitions are:
/system: This is where the binaries and system apps that come with the firmware are stored. This partition is usually mounted read-only to protect it. On the gTablet, this partition is on the 512MB built-in NAND flash chip.
/cache: As the name indicates, this is the partition used to speed up the execution of the Java apps. Temporary files are also created here. This partition too is on the built-in NAND flash chip.
/data: This is where user-downloaded apps are stored by default, and also where Android stores its system configuration data. This partition, on the gTablet, is on the internal SD card.
/sdcard: This is where user content like media files, books, and the apps moved to SD card are stored. This partition too is on the internal SD card.
The first 3 partitions are critical and Android won't come up without them being present (or, if there are any errors on them). Among these 3, only /system needs to be correctly populated (When you install a ROM, new stuff is copied here). The other 2 partitions, /data and /cache can be empty and the system will boot up fine--with defaults. In fact, when you select "wipe data/factory reset" in CWM, /cache and /data are re-formatted--effectively, wiped clean.
(There are 2 other important partitions on the NAND flash chip, but, these are not mounted because they don't contain a proper filesystem. You have to use special tools to create the contents of these 2 partitions.
The first of these is the "boot" partition. This one and "system" are re-written when you install a new ROM. The "boot" partition holds the Android Linux kernel. If you install a new kernel, only the "boot" partition is rewritten.
The second is the "recovery" partition. This contains a separate, and usually different (and safe), Linux kernel and a mini filesystem image. This is a fail-safe partition. Stock recovery and ClockworkMod sit here.)
In your case, nothing on the internal SD card can be modified, so the stuff in /data will still be from your old ROM. (nvflash also cannot modify SD card contents, as I mentioned before.) When the stock firmware boots up, it will find incompatible stuff in /data. Critical apps will then die. Android will restart them, they will die again. This is your boot loop.
Get me the dmesg output and then we'll run a few tests using CWM, but, judging from your previous posts, I don't think your internal SD card can be fixed. You have 2 options:
1. Return the tablet for a replacement.
2. If you can't return it, I can switch the internal and external SD cards on your ROM so that you can boot and use the system (almost) normally. But, this is a custom solution and you will need to have an external SD card in its slot always. Read through this thread.

Wow, you really know you're stuff! I'll see what I can get you later on in the day with regard to the dmesg, I'm currently still at work.
I had suspected a hardware error... bummer. I'll definitely be interested in seeing if I can just use the external micro sd slot to sub out for the internal sd card. I would at least like this thing to be functional again, though I suppose I'll never be able to try any of the honeycomb roms when those get past alpha. Oh well.
Do you know if this thing takes 32 gb micro sd cards? That would be pretty awesome, I at least wouldn't feel too limited on space.
By the way, thanks for all your help on this, I know I'm a huge noob. I greatly appreciate your patience and taking the time to break everything down for me. I have absolutely zero background in programming or anything computer related, though I do find this stuff extremely fascinating! If I could rewind the clock and study this stuff in school, I would do it in a heartbeat.
Again, thanks so much, can't thank you enough.

titobetlogs said:
I would at least like this thing to be functional again, though I suppose I'll never be able to try any of the honeycomb roms when those get past alpha. Oh well.
Click to expand...
Click to collapse
No, you should be able to run whatever ROM you want. I'll send you an installable zip file, in a few days, which should get you going again on Vegan-Tab, at least. You'll just need to remember to flash this zip file right after you've flashed the ROM (of your choice).
Right now, I don't know if I need one zip file for each kind of ROM in existence for the gTablet, or, if I can use some scripting and do the internal/external SD card switch using just a single installable zip file. I'll look into this on the weekend.
Do you know if this thing takes 32 gb micro sd cards?
Click to expand...
Click to collapse
Yes, it does.
By the way, thanks for all your help on this, I know I'm a huge noob...
Click to expand...
Click to collapse
I was a complete noob to Android myself back in April of this year. I've picked all of this up in just a few months. I'm pretty sure you can do it too, with a bit of poking around in the system. Of course, having a background in Unix/Linux helps a lot.

In your honor, below are some inspiring lyrics from the Karate Kid soundtrack:
You’re the best!
Around!
Nothing’s gonna ever keep you down
You’re the Best!
Around!
Nothing’s gonna ever keep you down
You’re the Best!
Around!
Nothing’s gonna ever keep you dow-ow-ow-ho-how-ho-own
INSPIRING GUITAR SOLO

Dude! you're embarrassing me -- I haven't send you the zip file yet... and, you haven't sent that dmesg output I wanted.

I know I've been stuck at work and family functions every day this week so far. Hopefully I'll get to it soon

Finally got to this! Here you go! Thanks again!

titobetlogs said:
Finally got to this! Here you go!
Click to expand...
Click to collapse
Can't see any problems in that dmesg output. Time for some tests on the internal SD card.
Boot into CWM, then run on PC (on Linux run: sudo ./adb shell):
Code:
C:\SOME\PATH> [B]adb shell[/B]
~ # [B]mount /dev/block/mmcblk3p1 /sdcard[/B] [I] Mount internal SD card partition[/I]
~ # [B]mkdir -p /sdcard/a/b/c[/B] [I]Make a directory tree[/I]
~ # [B]echo test > /sdcard/a/b/c/test.txt[/B] [I]Create a file[/I]
~ # [B]cat /sdcard/a/b/c/test.txt[/B] [I]Read it back again[/I]
test [I]Correct[/I]
~ # [B]echo 3 > /proc/sys/vm/drop_caches[/B] Flush kernel caches
~ # [B]cat /sdcard/a/b/c/test.txt[/B] Read it back again
test Correct
~ # [B]umount /sdcard[/B] [I]Unmount[/I]
~ # [B]mount /dev/block/mmcblk3p1 /sdcard[/B] [I]Remount /sdcard[/I]
~ # [B]cat /sdcard/a/b/c/test.txt[/B] [I]Reread file[/I]
test [I]You should see "test" here[/I]
~ # [B]umount /sdcard[/B]
You should see "test" after the kernel flush and the remount.
Next, reboot the tablet--back into CWM, then run the cat command again. `cat' should output "test", again, if the SD card is OK.

Here's a screen of the commands I entered and what I got back. Did I do anything wrong? Looks like something's a bit off.

Related

[how-to] Root the Slide (MAC OSX FLAVORED)

HOW-TO Root the Slide
(MAC OSX FLAVORED) KAPOWWW!!!!
&
Android SDK on Mac
STEP 1.
Download Android SDK from here.
STEP 2.
Unzip it. Place the folder it creates in your Documents folder and rename it AndroidSDK or SDK. (Something Easy)
SUCCESS!!! Android SDK Installed… //WTF!!??!!
STEP 3.
Download This Package > Slide Root.zip
Place the Contents of "Slide Root.zip" into your Android SDK Tools folder.
(These five files need to be placed DIRECTLY into the AndroidSDK/tools/ folder)
STEP 4.
RENAME Loop.bat to Loop.sh, then right click, open with TEXTEDIT.
Delete it’s contents and replace it with
#!/bin/bash
while [ 1 ]
do
adb devices
done
Save and Close the File.
STEP 5.
On your Slide, GO TO Settings > Application > Development and turn on USB Debugging.
This should save you headaches.
NOW… Power Off the Slide
STEP 6.
OPEN Terminal
(APPLE + SPACE and type Terminal, press enter.)
Now, CD to the SDK/Tools Directory.
It should be where we left it.
/Users/YOURUSERNAME/Documents/AndroidSDK/tools/
Terminal SHOULD open with it already in your USERNAME
Type cd Documents/AndroidSDK/tools/
STEP 7.
Power On the Slide into the Bootloader by Holding Down ( Volume Down + Power Button )
STEP 8.
NOW run your loop file (the one we made earlier)
The Terminal should be all queued up to the Tools folder.
Type in ./loop.sh
(The Terminal should be blowing up with List of Devices Attached over and over)
STEP 9.
Once your loop is running, select Recovery from the bootloader menu.
(Volume UP & DOWN to change selection and POWER to Select)
STEP 10.
When recovery loads, you should Have an Offline Device.
The Slide’s screen will have a picture of a Phone and RED triangle around a !
(Don’t freak out, this is a good thing.)
Hit Ctrl + C to stop your script & see.
If this doesn't happen, Power Off and try again from STEP 7.
STEP 11.
Un-plug your USB cable from your Slide & Plug it back in for it to Detect ADB Correctly!!!
IMPORTANTE!!!
At this point you can adb devices to see if it detects your device and that it is in recovery mode.
Type into Terminal ./adb devices
If it says recovery you are golden and move onto STEP 12 to kick the habit.
If not, rinse and repeat from STEP 7.
STEP 12.
Select Update.zip from the menu. (This will fail, but we already know that! Select it anyway).
STEP 13.
Type into Terminal
./adb push ota.zip /sdcard/update.zip
STEP 14.
Type into Terminal
./adb push slideroot.zip /sdcard
STEP 15.
MUY IMPORTANTE!!!
Have this Command ready in your Terminal before applying update.zip again!!
./adb push update.zip /sdcard
STEP 16.
On your Slide, Hit run update.zip
As soon as you see A Little Bar appear behind the text
Push ENTER to execute the Terminal command
(./adb push update.zip /sdcard )
STEP 17.
If successful, you should see Clockwork Recovery.
If unsuccessful, repeat steps 13-16.
STEP 18.
In Clockworkmod Recovery,
Go to the Partitions menu and Mount System
(It should be at the top and the only one not mounted.)
STEP 19.
Go one level back & select install any zip from sdcard.
Select slideroot.zip & apply update from zip
(This will finish the Root process).
STEP 20.
Reboot your phone & wait for it to load completely.
To confirm that your slide is connected as a device use the command ./adb devices
If this works, you will see it as a device. Your prompt will say something like:
$ ./adb devices
List of devices attached
HT05YUP12710 device
STEP 21.
./adb install Superuser.apk
(If it says it cannot locate directories, make sure you can find your device
using ./adb devices… If things still don't work, my best advice is to start over)
STEP 22.
After Superuser is installed try to use adb to shell to your device.
Type in Terminal
./adb shell
you will get a $
Then type su
On the Slide, Superuser should pop-up asking if you give permission, do so.
In Terminal, your $ should turn into a #. If so, you have root. WOOT!!!​
Original SHOUT OUTS!!!
Special Thanks to:
Paul O'Brien:
Koushik K. Dutta:
&
The Guys using the Incredible OTA Spoofing Method
&
ChiefzReloaded for Huge amount of Suggestion & Brain Storming.
But most of all, you should thank eugene373 for rooting the slide and not sleeping for two days.
His original post is here.
sk8rbebop said:
STEP 14.
Type into Terminal
./adb push slideroot.zip​
Click to expand...
Click to collapse
should it not be:
./adb push slideroot.zip /sdcard
Also...
sk8rbebop said:
STEP 15.
VERY IMPORTANTE!!! ​
Click to expand...
Click to collapse
Should be:
MUY IMPORTANTE!!!
I don't understand the need for a separate post when the only difference between osx and windows is that osx uses a shell script and windows a batch file and osx is discussed in the post about rooting.
nerdcorerising said:
I don't understand the need for a separate post when the only difference between osx and windows is that osx uses a shell script and windows a batch file and osx is discussed in the post about rooting.
Click to expand...
Click to collapse
Five different people asked for it so they got it.
Thanks!
Thanks a bunch for the tutorial! We really do appreciate it. I just had a couple questions about 2 of the steps.
STEP 6.
OPEN Terminal
(APPLE + SPACE and type Terminal, press enter.)
Now, CD to the SDK/Tools Directory.
It should be where we left it.
/Users/YOURUSERNAME/Documents/AndroidSDK/tools/
Terminal SHOULD open with it already in your USERNAME
Type cd Documents/AndroidSDK/tools/
I got lost where it says "Now, CD to the SDK/Tools Directory." I do not really know what the CD means and what I should be typing into Terminal?
Also should my phone already be plugged in to my Mac?
Please let me know and thanks!
Thanks a bunch for this tutorial. I am about to try to ROOT, it should go over smoothly. Now from the ROOT what else have you guys been doing to you're Slide? I know Cyanogen has not said much, that is who I used for my myTouch 3G and my G1.
Click to expand...
Click to collapse
I flashed the Eng Build, then SlideMEROOT2 and then the new radio (you need this). Just follow the how-to's already posted, but remember to type ./ before the commands in Terminal.
Ex. ./adb devices Instead of adb devices.
There were a couple people who were trying to keep their original stock rom, but slidemeroot2 is basically the original rom. Plus, someone posted the original stock backup, so flash away.
-------------------------------------
Sent via the XDA Tapatalk App
this is wrong
#!/bin/bash
while [ 1 ]
do
adb devices
done
it should be
#!/bin/bash
while [ 1 ]
do
./adb devices
done
shadowleo85 said:
this is wrong
#!/bin/bash
while [ 1 ]
do
adb devices
done
it should be
#!/bin/bash
while [ 1 ]
do
./adb devices
done
Click to expand...
Click to collapse
It's no more "wrong" than your code...
The first assumes that you've configured your shell to link the "adb" command to the adb "app" in the sdk/tools directory. Your code assumes that you will be activating the script while "within" that very directory.
The code, IMHO, should read:
Code:
...
[PATH TO SDK/TOOLS/]adb devices
...
And the OS X user should be instructed to insert their own path.
HebrewToYou said:
It's no more "wrong" than your code...
The first assumes that you've configured your shell to link the "adb" command to the adb "app" in the sdk/tools directory. Your code assumes that you will be activating the script while "within" that very directory.
The code, IMHO, should read:
Code:
...
[PATH TO SDK/TOOLS/]adb devices
...
And the OS X user should be instructed to insert their own path.
Click to expand...
Click to collapse
WRONG the code running in the shell is to continuously run adb devices... which to do so correctly would have to be implemented with ./ in front to run correctly on a mac... dont try to correct what is right i will school u
and seeing as he clearly instructs u to place those apps within the tools folder and "cd" to it... means that the user should have those commands ready at hand which is included in the folder...
shadowleo85 said:
this is wrong
#!/bin/bash
while [ 1 ]
do
adb devices
done
it should be
#!/bin/bash
while [ 1 ]
do
./adb devices
done
Click to expand...
Click to collapse
Ur right.. that is the right way..
also for those of u having problems with the loop step where it never sticks... try a different memory card... i was having problems with the stock card... so i tried a different card and it worked perfectly... with no problems
shadowleo85 said:
and seeing as he clearly instructs u to place those apps within the tools folder and "cd" to it... means that the user should have those commands ready at hand which is included in the folder...
Click to expand...
Click to collapse
LOL. Okay, tough guy.
The fact is that the active directory in your terminal is irrelevant to the actual rooting process. If you want to argue about it, have at it. I really don't care.
Yes, in terminal you must type ./adb devices, but within the .sh you can just issue adb devices and it works just fine. It is because you are issuing a command from within a script and OS X understands you better when you use them.
As for the memory card trick everyone is perpetuating, tis but a superstition and whatever floats your boat, while you attempt to get adb to stick. When I rooted mine, it took five to ten tries. Rooting my girlfriend's, on the other hand, took nearly 15-20 min for it to catch.
sk8rbebop said:
Yes, in terminal you must type ./adb devices, but within the .sh you can just issue adb devices and it works just fine. It is because you are issuing a command from within a script and OS X understands you better when you use them.
As for the memory card trick everyone is perpetuating, tis but a superstition and whatever floats your boat, while you attempt to get adb to stick. When I rooted mine, it took five to ten tries. Rooting my girlfriend's, on the other hand, took nearly 15-20 min for it to catch.
Click to expand...
Click to collapse
within the shell command command it has to be ./adb devices or it fails at command line 4 which is the problem i was having until i changed it in the shell and it worked... along with a few others...
and as far as the memory card thats the issue... i tried 5 different memory cards one always worked the others never stuck... it may have something to do with the way the memory card is coded... my 16gb mem card out my hd2 is the only one that worked... not really a superstition
shadowleo85 said:
within the shell command command it has to be ./adb devices or it fails at command line 4 which is the problem i was having until i changed it in the shell and it worked... along with a few others...
and as far as the memory card thats the issue... i tried 5 different memory cards one always worked the others never stuck... it may have something to do with the way the memory card is coded... my 16gb mem card out my hd2 is the only one that worked... not really a superstition
Click to expand...
Click to collapse
The memory card has nothing to do with the rooting process whatsoever. With that said, a lot of the memory cards shipping with the slides are misformated. The first thing I did was backup my card, swap it out with a class 10 16 GB card and set up a 1GB ext4 partition. Then I copied the files back to the FAT partition and all was well.
HebrewToYou said:
The memory card has nothing to do with the rooting process whatsoever. With that said, a lot of the memory cards shipping with the slides are misformated. The first thing I did was backup my card, swap it out with a class 10 16 GB card and set up a 1GB ext4 partition. Then I copied the files back to the FAT partition and all was well.
Click to expand...
Click to collapse
yet with all the cards i tested which are formatted correctly and running perfectly on all my devices... and even tried useing my class 6 8gig with is partitioned for my og mytouch didnt work... dude stop trying to correct me i got this... worry bout ya own lil world
shadowleo85 said:
yet with all the cards i tested which are formatted correctly and running perfectly on all my devices... and even tried useing my class 6 8gig with is partitioned for my og mytouch didnt work... dude stop trying to correct me i got this... worry bout ya own lil world
Click to expand...
Click to collapse
Oy vey. Seriously? The rooting process is a hit or miss operation. Your sdcard doesn't even come into play for a second. You could probably remove the darn thing and be successful.
Please, for heaven's sake, just listen to sk8rbebop, myself or any of the numerous other people saying in no uncertain terms that the sdcard issue is a myth. Don't perpetuate something that is entirely unrooted in reality.
Sheesh...
HebrewToYou said:
Oy vey. Seriously? The rooting process is a hit or miss operation. Your sdcard doesn't even come into play for a second. You could probably remove the darn thing and be successful.
Please, for heaven's sake, just listen to sk8rbebop, myself or any of the numerous other people saying in no uncertain terms that the sdcard issue is a myth. Don't perpetuate something that is entirely unrooted in reality.
Sheesh...
Click to expand...
Click to collapse
how can it be unrooted in reality when in reality it works and im proving that... its mighty funny that it doesnt stick unless this specific memory card is in my device... and u stating that it doesnt come into play is wrong... when u load ur phone into bootloader it does check ur "memory card" for an nbh image which is where i believe the problem lies... it accesses ur memory card just like the og mytouch did to locate a gold card... dont argue with me when it is just another work around that just may work seeing as IM PROVING THAT IT DOES INDEED WORK
shadowleo85 said:
how can it be unrooted in reality when in reality it works and im proving that... its mighty funny that it doesnt stick unless this specific memory card is in my device... and u stating that it doesnt come into play is wrong... when u load ur phone into bootloader it does check ur "memory card" for an nbh image which is where i believe the problem lies... it accesses ur memory card just like the og mytouch did to locate a gold card... dont argue with me when it is just another work around that just may work seeing as IM PROVING THAT IT DOES INDEED WORK
Click to expand...
Click to collapse
Oy vey. Fine, believe what you want. What's *actually* helping you root the device is sticking gum on your nose, turning your baseball cap backwards, rubbing your lucky rabbit foot and reciting the pledge of allegiance. You just haven't realized it yet.
Stay crunchy.
HebrewToYou said:
Oy vey. Fine, believe what you want. What's *actually* helping you root the device is sticking gum on your nose, turning your baseball cap backwards, rubbing your lucky rabbit foot and reciting the pledge of allegiance. You just haven't realized it yet.
Stay crunchy.
Click to expand...
Click to collapse
dude wtf is ur problem... if it can possibly help someone whose having the issue y r u having such an issue with it

[Q] Clockworkmod hanging on backing up system...

I apologize if this has been covered in another thread but I have been doing multiple searches on XDA and in google trying to find a solution but so far no luck. Long time reader of XDA but first time poster.
Details -
I successfully used NVFLASH, loaded Clockworkmod 0.8 and loaded Vega-Ntab gingerbread edition (stable RC1 I believe its called). I have been running this for a month or so with no major issues but I want to test out Vega-Ntab 5.1 and Brilliant Corners. Thinking of going with 5.1 for the hardware acceleration for gaming etc. Oh I also received my new Gtab with bootloader 1.2 and I downgraded that to 1.1 successfully before loading Vega-Ntab gingerbread. I think I can handle loading the new roms etc (may have to switch to 1.2 for Brilliant Corners I believe) but I want to do a full backup before doing so with clockworkmod so I can go back to gingerbread if I decide I liked it the best. But clockworkmod will not do a backup for me. I have tried multiple times and it always freezes/hangs at the same point. On the screen I see
ClockworkMod Recovery v2.5.1.1-bekit-0.8
SD card space free: 9697MB
Backing up boot...
Backing up recovery...
Backing up system... and here it will go no further
I have let it set at that point for hours but nothing changes. I checked the clockworkmod backup folder and it has a folder dated the current date of the backup but the contents is only boot.img and recovery.img and nothing else so I think that confirms it really isnt completing the backup.
I am unsure what the cause or solution to this is. I thought about reloading clockworkmod 0.8 but I don't think I can do this since it's already loaded. I thought about loading a newer version but from what I have read gingerbread and the other 1.1 roms will not work with anything but 0.8. I could just do a melt and repour and just go back to stock level and load 5.1 or Brilliant Corners but then I lose any apps I have loaded. I am not concerned about the majority of them but I have loaded a couple good ones as of late from Amazon that were the free app of the day and I am unsure whether I can "reload" these at a later date without being forced to pay. I have also paid for a couple games but I am assuming I can reload those without issue. I did back up all of the apps I paid for and amazon games that I loaded that I got for free (normally have to pay) with titanium backup. So assuming I can restore these with titanium backup after loading brilliant corners or vegan 5.1 then I guess the only thing that I lose by not being able to do a full backup/restore with clockwork is that if I want to go back to gingerbread then I have to start from scratch for reloading the rom.
So is the problem I am having running the back up successfully a known issue that I just can't seem to find a discussion thread about?
Thanks in advance for any help or advice.
Boot into ClockworkMod Recovery and get me a dmesg output (kernel messages) using adb. See this post for how.
Attach the dmesg.txt to your next post.
thanks for the reply. Unfortunately I am not having any luck getting the dmesg.txt file for you. I downloaded the iso image for Knoppix 6 but when I boot off the disc it starts processing everything but then it gives an error "the file /mnt-system/knoppix/knoppix is broken. then after about 30 secs it gives the following
/sbin/init: line 76: syntax error near unexpected token '/usr/share/fonts/type1/gsfonts/a010013l.pfb'
/sbin/init: line 76: '/URWGothicL-Book (usr/share/fonts/type1/gsfonts/a010013l.pfb);
I will try and download the iso from a different site and burn another disc.
I also tried a different route and loaded SDK manager to get to ADB by that route. I am running windows 7 if that makes a difference. I am not 100% sure when I am supposed to run the adb command line you listed. Do I have my gtab running clockworkmod and then mount USB so it will show up on my pc? Do I have to try and perform a backup and then run the adb command when it freezes? I don't think I can do that because if I navigate away from the mount USB it automatically unmounts it. Anyway adb doesn't appear to be seeing the gtab anyway. When I run the SDK manager it does not find any android devices. If I run the "adb devices" command it comes back with no devices. So I am not sure what basic thing I am missing to get adb or SDK to recognize the gtab.
I apologize for my lack of knowledge on adb. Your first link says if I have adb already set up to run adb shell dmesg > dmesg.txt while in clockworkmod so I am assuming I do this after mounting USB to get the pc to recognize the gtab.
I will try download and burn another iso image from a different location and see if I can boot off a disc. Assuming this time it is successful do I run the ADB command you listed in the second link while the GTab is mounted to USB and recognized by the pc? Hopefully ADB will see it if I can get this to work.
*update* I downloaded the ISO image from a different location. When I went to the folder it was downloaded to I noticed that the first ISO image I downloaded was only approx 100MB in size instead of 700+ mb. So I am re-burning another disc. Hopefully this will allow me to boot properly.
*update #2* I was able to successfully boot off of the new disc. Now I just need to figure out how and where to enter the adb command line in your link ($ sudo ./adb shell dmesg > dmesg.txt) i tried this using the Shell option but it says command not found. If I choose the File Manager option and navigate to where the adb file is that was in your linked zip file it just prompts me to edit/copy/move/rename or delete the file. I am out of time tonight so I will work on it more tomorrow. The good news though is that when I use File Manager the Gtab is listed so it is at least recognized. Now I just need to figure out how to get the dmesg.txt file you request but making some progress... I think
ashton555 said:
*update #2* I was able to successfully boot off of the new disc. Now I just need to figure out how and where to enter the adb command line in your link ($ sudo ./adb shell dmesg > dmesg.txt)
Click to expand...
Click to collapse
Step by step instructions in this post.
thanks a bunch. Those instructions were easy to follow and made sense. I have never used linux before but alot of it reminded me back of my old unix days (terminal commands that is).
Anyway I think I did everything correct and I am now attaching the txt file.
Thanks again for your help and patience with this Linux newbie let me know if I need to provide any additional information.
ashton555 said:
Anyway I think I did everything correct and I am now attaching the txt file.
Click to expand...
Click to collapse
You did indeed. And I can't see any obvious problems with the NAND-flash device, judging from the kernel messages.
Since you've already tried to take backups using CWM before, that action should've created a log file. This file might be useful. Retrieve it. Inside an xterm window on Linux, run:
Code:
hostpc$ [B]sudo ./adb pull /cache/recovery/log recovery.log[/B]
Attach this "recovery.log" file.
Next, try to read, one by one, the NAND flash partitions that CWM usually backs up. Here's an example run on my gTablet:
Code:
hostpc$ [B]sudo ./adb shell[/B] [I]Get into the shell in CWM[/I]
~ # [B]dump_image boot /dev/null[/B]
~ # [B]dump_image recovery /dev/null[/B]
~ # [B]dump_image system /dev/null[/B]
mtd: read error at 0x029a0000 (I/O error)
mtd: read error at 0x02da0000 (I/O error)
~ # [B]dump_image cache /dev/null[/B]
~ #
Type in only the commands in bold.
As you can see, my "system" partition on the NAND flash has errors (and the kernel also report this when it boots), but, the command will not hang. According to the kernel message that you just supplied, you don't have any errors on your onboard NAND flash, so, theoretically, you shouldn't get any errors at all. But, we'll see if the dump_image command hangs when reading system just like CWM does.
And if the dump_image command does hang somewhere, we can see if formatting just that system partition will get it working again. There is a utility on this board which we could use for doing that, though I've never tried it.
I successfully completed the next two tasks. I am attaching the recovery.log file. Note I had an issue copying the .log file to where I could access it in win7 (for some reason I cant attach a file while in linux). I opened it with a word processor and then saved it to my c drive which messed up the formatting. So I opened it in Word to get the formatting correct and saved it as a txt file so thats why the attached file is recovery.txt. Let me know if it messed it up to where its not useable.
On the second task
~ # dump_image boot /dev/null
this worked fine and quick
~ # dump_image recovery /dev/null
this worked fine and quick
~ # dump_image system /dev/null
this worked but took maybe 10-15 seconds
~ # dump_image cache /dev/null
this one gave an I/O error but completed the dump
mtd: read error at 0x00080000 (I/O error)
ashton555 said:
Let me know if it messed it up to where its not useable.
Click to expand...
Click to collapse
The file is just fine... and I can't see any error messages in it.
~ # dump_image system /dev/null
this worked but took maybe 10-15 seconds
Click to expand...
Click to collapse
This is normal -- "system" partition is ~200MB.
~ # dump_image cache /dev/null
this one gave an I/O error but completed the dump
mtd: read error at 0x00080000 (I/O error)
Click to expand...
Click to collapse
This also looks like normal behaviour, but, I'm puzzled that the kernel did not report any bad blocks on this partition. Check if this is a transient error:
1. Repeat the "dump_image cache ..." command a few times and see if the I/O error location is the same.
2. Try to "fix" the error on the cache partition by using the "wipe cache partition" menu item in CWM. Do this a couple of times.
3. Run the "dump_image cache ..." command again.
4. Attempt another full system backup using CWM.
If step 4 fails, we'll see if the writing of the backup to the sdcard is the problem, because the reading seems to be completing without any hangs as of now.
BTW, the most important partitions are all being read fine. The "cache" partition is not that important -- it can be empty (but not corrupt) each time the system boots and only the initial bootup might go a little slower.
And, if, in the end of all this, you can't use CWM at all, you can still make a full system backup using nvflash and a few Unix commands.
1. Repeat the "dump_image cache ..." command a few times and see if the I/O error location is the same
....i did the dump 4 times and it always gave the same I/O location
2. Try to "fix" the error on the cache partition by using the "wipe cache partition" menu item in CWM. Do this a couple of times
.... I wiped the cache 4 times successsfully
3. Run the "dump_image cache ..." command again.
.... same I/O error location
4. Attempt another full system backup using CWM
.... still freezing at backing up system
So I guess I need to try and do the backup with NVFlash and unix/linux commands? If you have a link on how to do that I will give it a try or I can search for it and see if there is a discussion thread on it.
Thanks again for your help and trying to resolve this
Question - if I started over from scratch and went back to stock and then loaded vegan gingerbread would this issue possibly correct itself? Also more importantly if I back up some apps using titanium backup before I go back to stock can I then restore them with Titanium once I have vegan ginger back loaded? Also if I loaded vegan 5.1.1 could I restore the same apps I backed up in vegan ginger? Hopefully that made sense. I don't mind starting from scratch if I need to I just wasnt sure if I would permanently lose certain apps I have loaded. It's only about 10 apps I care about
*update* - well I think I am going to be forced to start over anyway. After wiping the cache a couple times and attempting another backup (froze again at backing up system) I now can't get the gtab to boot completely. It is stuck at the flashing vegan ginger edition screen. It flashes for awhile then the screen goes black then it goes back to the flashing screen again. I know you said it would take longer to boot up the first time after wiping the cache but was doing the flash cycling for over an hour which I assume is too long? I tried wiping the cache again and I also wiped the davlik cache as someone suggested in another thread but it is back to being stuck in the flashing screen loop. Assuming I do have to start over can I at least boot to CWM, mount ext USB and copy off the titanium backup files I made so I can restore some of the paid for apps?
ashton555 said:
3. Run the "dump_image cache ..." command again.
.... same I/O error location
Click to expand...
Click to collapse
Looks like a permanent I/O error in the cache partition, then. But, I don't understand why it is "system" which is hanging on backup.
4. Attempt another full system backup using CWM
.... still freezing at backing up system
Click to expand...
Click to collapse
Get me the recovery.log.
So I guess I need to try and do the backup with NVFlash and unix/linux commands?
Click to expand...
Click to collapse
I'll think this over during the weekend. In the mean-time, read through this thread. You can safely take a complete backup of your tablet while I do a bit of experimentation on a clockworkmod-like solution. But, I suspect that you may not be able to backup "cache" using nvflash going by the I/O errors. I have errors on my "system" partition and a nvflash backup fails on it, but CWM doesn't have any problems backing up and restoring.
Question - if I started over from scratch and went back to stock and then loaded vegan gingerbread would this issue possibly correct itself?
Click to expand...
Click to collapse
Probably not. But, see this thread. It shows you how to wipe all the partitions on the NAND flash device. We don't need to format the entire NAND flash. We can see if doing a few repeated formats of the "system" and "cache" partitions gets CWM working again, if you're willing to wipe "system"--you will have to load Vegan-Ginger right after this.
Also more importantly if I back up some apps using titanium backup before I go back to stock can I then restore them with Titanium once I have vegan ginger back loaded? Also if I loaded vegan 5.1.1 could I restore the same apps I backed up in vegan ginger? Hopefully that made sense. I don't mind starting from scratch if I need to I just wasnt sure if I would permanently lose certain apps I have loaded. It's only about 10 apps I care about
Click to expand...
Click to collapse
I haven't used Titanium backup so I can't say how well it works, but, judging from the reports that other users have made, what you're suggesting should work without any problems. User downloaded applications are stored either on /data or on /mnt/sdcard (for apps moved to SD card). Since your SD cards don't seem to be affected, you can go ahead with Titanium backup.
ashton555 said:
Assuming I do have to start over can I at least boot to CWM, mount ext USB and copy off the titanium backup files I made so I can restore some of the paid for apps?
Click to expand...
Click to collapse
Yeah, copy the files in CWM, then just do a "wipe data/factory reset" and see if it boot loop goes away.
But, before you do that, gimme a half-hour and I'll send you commands which you can use to save the files in /data and /sdcard. I just have to compile and test a new version of busybox. The tar command already present in CWM doesn't seem to work properly for me.
Attaching the recovery file
I am running the nvflash back up right now.
It successfully did part-1.img through part-11.img with no errors. The last thing it said though is
"rem CACHE PARTITION BACKUP NOT NEEDED
"nvflash.exe" -r --read 12 part-12.img
press enter to continue
Is this maybe because I wiped the cache and it's empty?
I looked on my ext SD card and the titanium backup files are there (except for a couple I had forgotten do ....) so I think I am okay for going back to square one if need be.
I will go ahead (tomorrow probably) try doing what is described thread about wiping partitions on the NAND device and just formating the system and cache partitions. I am assuming that at this point I guess its okay to go ahead and try to load vegan tab 5.1.1 instead of ginger again since I wanted to try out 5.1.1 anyway or if you have any experience with it would you recommend Brilliant Corners instead since its a newer rom. I think I will have to reload the 1.2 bootloader which is okay.
ashton555 said:
Attaching the recovery file
Click to expand...
Click to collapse
No errors in there.
The last thing it said though is
"rem CACHE PARTITION BACKUP NOT NEEDED
"nvflash.exe" -r --read 12 part-12.img
press enter to continue
Is this maybe because I wiped the cache and it's empty?
Click to expand...
Click to collapse
I think so. The cache partition isn't that important anyway, so it can be skipped.
I will go ahead (tomorrow probably) try doing what is described thread about wiping partitions on the NAND device and just formating the system and cache partitions.
Click to expand...
Click to collapse
I would suggest that you copy the Titanium backed-up apps safely away immediately, then format just the system and cache partitions as per that thread. You will need to be in APX mode to use nvflash.
Immediately after the nvflash, (since the system partition is now gone), boot into CWM, then do a factory reset, repartition the internal sdcard, copy the Vegan-5.1.1 update file onto the now clean sdcard through the PC and then flash it. This should give you a clean slate.
Then check if you can do a backup using CWM. If you still can't, then I'll see if a solution can be devised to do partial backups.
And, I have tried neither Vegan* nor Brilliant Corners, so the choice is up to you.
Sorry, my test commands aren't working so I can't send you those commands I promised to back up your /data and /system--I suspect a bad USB cable.

[Q] Bricked and Malfunctioning Partitions

I have a GTab that was running Calkulin + Clemsyn Combo Overclock at 1.5 ghz V8 on the 1.2 branch fine for a couple months now, then something happened today. Woke up to find there was no sound coming from it (I'd left an Anti-mosquito app running all night), so I tried to play a couple music files. Seemed to get frozen instead of playing, so I restarted. That's when it went into a boot loop from 3 birds to the first splash screen of the loaded ROM.
Attempted to do a backup via CWM, and it failed on /data. Tried a data wipe/reset, then reflashing the ROM and finally NVFlash. Still goes into a bootloop. Repartitioning and mounting doesn't do anything; ADB doesn't see the device at all in CWM or APX; /data cannot be mounted and /sdcard mounts only when a card is inserted (doesn't see the internal space) but still doesn't mount USB storage and says: "E:Unable to write to ums lunfile (No such file or directory)"; drive shows in Win7, but is inaccessible;
As mentioned, APX mode and NVFlash along with CWM works fine. And I can mount /cache and /system fine. I've gotten to Code Double Red here and now I'm draining the battery for the next step (really don't want to pull any screws). Also tried the fix here, but it seems that's just for CM7, which I'll probably try flashing some time.
I'm going to return to the 1.1 branch and try a couple ROMs there, but I have a really slow connection and it's taking a while to get nvflash 1.1.
Did a quick search of the forum and didn't find anything quite similar. Obvious question is, has anyone ever experienced this before? What are some other steps I can take to fix this? Is there a way to backup the internal SD before I probably have to wipe it?
Connect the USB cable to the tablet, then boot it into CWM, and run this command on your PC:
Code:
C:\SOME\PATH> [B]adb shell dmesg > dmesg.txt[/B]
Post that dmesg.txt file here. We'll see what's wrong.
Connected the charger long enough to run the command, but all I get is "error: device not found". As I'd said, ADB doesn't detect the tablet, even though Windows knows when it's connected and disconnected. Is there anything that I can flash to get me a terminal? That's the only way I can think of to get that command run and hopefully direct the output to my SD. Thanks.
I now have a completely dead battery. Wondering what to do next since it's supposed to have been hard reset now. Not seeing anything different after booting; same boot loop even though I just flashed a ROM again.
rajeevvp said:
Connect the USB cable to the tablet, then boot it into CWM, and run this command on your PC:
Code:
C:\SOME\PATH> [B]adb shell dmesg > dmesg.txt[/B]
Post that dmesg.txt file here. We'll see what's wrong.
Click to expand...
Click to collapse
I had seen this thread before where you were helping someone last year. Wish I'd read further to see that he eventually got the same problem I now have. I'm currently working my way through everything. First I need to get ADB running though, so I'm working on that now. Think I may be needing that partition swap trick, but we'll see...
Having issues getting the right USB drivers installed for ADB on Windows 7 64 bit. Using instructions here. But each time I uninstall the device, as soon as I plug in the tablet, it installs the default drivers. Using both Device manager and USBDeview. Updating and other options are also disabled when there is nothing installed. Considering to do a direct registry hack of the device info if I can, and hopefully not break anything important.
Try using Linux.
I finally got ADB working on my system and did some experimenting. Seems there's definitely something wrong with my internal SD according to the dmesg output. Luckily I have a SD which I used in my SG3, and it is already properly partitioned, so I'll try using that. Tried making a fstab file in /etc (mtdblock3) but I got "Magic Value Mismatch" error, so I NVFlashed to return it to how it was. I'm currently researching how to create update files, because it seems that's the only way I can get the SDs swapped. Any guidance is still welcomed. Thanks alot.
Skele Drew said:
Seems there's definitely something wrong with my internal SD according to the dmesg output.
Click to expand...
Click to collapse
Yeah. There are clear error messages relating to the internal SD card. You can either return the tablet and get a replacement, or, use my SD card device swapping technique to use the external SD in place of the non-working internal one.
Tried making a fstab file in /etc (mtdblock3) but I got "Magic Value Mismatch" error, so I NVFlashed to return it to how it was. I'm currently researching how to create update files, because it seems that's the only way I can get the SDs swapped.
Click to expand...
Click to collapse
If you use my files, you don't need to modify anything manually. What're you trying to change, BTW?
I can definitely use some help there. Where are the files? I tried modifying the custom ROM I use by adding a custom fstab and vold.fstab to /etc, an init script to init.d and replacing the /data mounting command with:
Code:
ui_print("Copying Data Files");
run_program("/sbin/mount", "-t", "ext3", "/dev/block/mmcblk2p2", "/data");
ui_print("Mount information:");
ui_print(run_program("/sbin/mount"));
Not sure what you're attempting to do here...
If you just want to use an external SD card in place of your non-working internal one, then all you have to do is a) flash either one of the CWM zip files and then b) flash the SD card swapping zip file right after you install the ROM of your choice. And, if you tell me which ROM you plan to install, I can look inside it and tell you if my scripts will work with that ROM.
If you can read shell/awk scripts, you can look inside the zip files to see what they do and how they do it.
rajeevvp said:
Not sure what you're attempting to do here...
If you just want to use an external SD card in place of your non-working internal one, then all you have to do is a) flash either one of the CWM zip files and then b) flash the SD card swapping zip file right after you install the ROM of your choice. And, if you tell me which ROM you plan to install, I can look inside it and tell you if my scripts will work with that ROM.
If you can read shell/awk scripts, you can look inside the zip files to see what they do and how they do it.
Click to expand...
Click to collapse
I was trying to make a swap script myself, but it's not working. /system dir gets corrupted. I'm using Clemsyn_Caulkinver8final2, a Froyo ROM.
Look at my scripts. If you have any questions, just ask.
Where are the scripts? That's what I've been asking...
EDIT: If this is what you use, then all should be ok. Let you know the result when I'm again online. Thanks alot for your help!
That's what I was talking about. I modified the device-swapping script today to fix-up an additional shell script, /system/etc/inandop.sh, on the various Clemsyn/Beasty ROMs (incl. yours), so use the newer zip file.
rajeevvp said:
That's what I was talking about. I modified the device-swapping script today to fix-up an additional shell script, /system/etc/inandop.sh, on the various Clemsyn/Beasty ROMs (incl. yours), so use the newer zip file.
Click to expand...
Click to collapse
Appears it still doesn't work. However, now instead of having a boot loop, it's just stuck at the splash screen after the 3 birds. I'm going to try combining your script and the ROM to see if I can get better results. I'm also going to try inserting some log/debug messages where I can.
Skele Drew said:
Appears it still doesn't work. However, now instead of having a boot loop, it's just stuck at the splash screen after the 3 birds. I'm going to try combining your script and the ROM to see if I can get better results. I'm also going to try inserting some log/debug messages where I can.
Click to expand...
Click to collapse
THANK YOU RAJEEV!!!!!!!
Today I got the time to work on my tablet again, since I just restarted college and it's been a bit hectic. Decided to try CM7 since when I looked into your script I saw direct management for it, so I NV'd back to 1.1 (I didn't know what branch CM7 was on, but flashing CM7 on 1.2 gave an error and aborted). The first time I tried the CM7, it got to the CM7 logo, then was there for a while until I only had a black screen. The only way I knew the tablet was still on was because ADB was still connected. Then I flashed your script and VOILA! everything started great. So now I have my tablet again for my classes .
I am planning to still run a few tests to see if I can somehow recover/fix the internal SD, so I downloaded your set of e2fsprogs. Think I'll make a flashable file for the entire package.
Again, thanks for all your assistance. It's much appreciated. I really didn't have that much time anymore to work on it myself too. I will continue to learn more as time goes on though, and I hope one day I'll become a guru like you .
Skele Drew said:
Decided to try CM7 since when I looked into your script I saw direct management for it, so I NV'd back to 1.1 (I didn't know what branch CM7 was on, but flashing CM7 on 1.2 gave an error and aborted).
Click to expand...
Click to collapse
The official CM7 is, right now, only for 1.1. However, since you can replace just the kernel and instantly make a 1.2 ROM, you'll have to look at the kernel messages to tell which bootloader version you have (Note: this is only for pershoot kernels).
The first time I tried the CM7, it got to the CM7 logo, then was there for a while until I only had a black screen. The only way I knew the tablet was still on was because ADB was still connected.
Click to expand...
Click to collapse
This is to be expected. When a ROM first runs, it writes a whole bunch of stuff into /data; but, your internal SD card is messed up, so every write would've ended up with the kernel retrying for quite a bit and then failing.
You should've flashed the ROM and immediately afterwards my script to fix-up the mount points on the ROM--ie. before the first boot.
I am planning to still run a few tests to see if I can somehow recover/fix the internal SD, so I downloaded your set of e2fsprogs. Think I'll make a flashable file for the entire package.
Click to expand...
Click to collapse
I doubt if you can "fix" your internal SD card error using any of the e2fsprogs--it looks like a card-controller error rather than a media error. You have one of the non-standard internal SD cards which has caused problems for some other users as well.
Ok. I do have a few issues I hope I can get some help on. For one, flash player doesn't work, and that's something very important. All my browsers direct me to get flashplayer. It worked pretty well in my previous ROM, so it may be an issue with CM7, but I haven't seen any similar issues on their site.
Also, the tablet is less responsive now, though I think this has to do with the /data partition being on external SD, though it's a class 6 card.
Sent from my GTablet using Tapatalk
Did you partition the external SD card correctly into 2 partitions (the first as VFAT and the second as ext3) before you installed CM7? I'm not sure what steps from my post you followed and what steps you skipped: you mentioned you were planning to modify the scripts/ROM, right?
It is also possible that my script is not doing the right thing on CM7 since it doesn't touch the vold.fstab on it. Get me the output of a mount command in CM7, and these files:
Code:
/system/etc/vold.fstab
/system/build.prop
Also make sure that you, or the ROM provider, haven't enabled the SD card switching in Settings > Cyanogenmod settings.
The SD I'm using was in a SG3 using this ROM, so I think it's correctly partitioned. I've accessed the partitions before and the correct names are associated with the contents. I only followed steps 1 & 4. The option to use removable for apps and media is disabled.
build.prop
mount.txt
vold.fstab

[Q] I think I killed it.

Alright, so this is going to take a bit of explaining, please bear with me.
I got this phone a couple of weeks ago, subsequently rooted it, and shortly thereafter decided upon Viper for my ROM. After playing around for a bit, I took a look at Beastmode kernel yesterday. I backed up my phone, installed the new kernel, and everything went to hell shortly thereafter. Upon rebooting, my phone no longer detected a mounted SD card. Along with this, it also doesn't have working audio. I tried rolling back to my restoration point, but I cannot find it now. While digging through directories in recovery, I've found two things out.
1: There is now a storage/emulation/legacy folder with (almost) every folder that was in mnt/sdcard.
2: My restore point is gone, and I don't have the original kernel on my phone
I figured this wouldn't be THAT big of a problem, connect my phone to my PC, go into ADB and try to push the stock s-off kernel. Next set of problems.
1: /mnt/sdcard is showing as a non-directory, insists it doesn't exist.
2: storage/emulation/ shows as read only, and all lower subdirectories are coming up as not existing (I believe it to be an issue with folder naming, legacy is actually 0 on my file explorer on the phone, I think?).
Where I stand now::
At this moment, I have the HTC Droid DNA Toolkit running, the stock s-off Kernel, and a phone that doesn't cooperate with anything.
Also; I tried downloading the .zip directly on my phone, but because it doesn't think there's an SD card, it's refusing to let me download it. It lets me download apps from the market, though.
Any ideas?
PS! Forgot the biggest SNAFU in all of this. On my phone are about 200 pictures from my vacation which I hadn't put onto my computer yet because I am an imbecile. This is keeping me from wiping the phone down to brass tacks and starting all over. If someone can find a way for me to pull said pictures from my device, I can wipe it and see if that helps.
Killerkendolls said:
Alright, so this is going to take a bit of explaining, please bear with me.
I got this phone a couple of weeks ago, subsequently rooted it, and shortly thereafter decided upon Viper for my ROM. After playing around for a bit, I took a look at Beastmode kernel yesterday. I backed up my phone, installed the new kernel, and everything went to hell shortly thereafter. Upon rebooting, my phone no longer detected a mounted SD card. Along with this, it also doesn't have working audio. I tried rolling back to my restoration point, but I cannot find it now. While digging through directories in recovery, I've found two things out.
1: There is now a storage/emulation/legacy folder with (almost) every folder that was in mnt/sdcard.
2: My restore point is gone, and I don't have the original kernel on my phone
I figured this wouldn't be THAT big of a problem, connect my phone to my PC, go into ADB and try to push the stock s-off kernel. Next set of problems.
1: /mnt/sdcard is showing as a non-directory, insists it doesn't exist.
2: storage/emulation/ shows as read only, and all lower subdirectories are coming up as not existing (I believe it to be an issue with folder naming, legacy is actually 0 on my file explorer on the phone, I think?).
Where I stand now::
At this moment, I have the HTC Droid DNA Toolkit running, the stock s-off Kernel, and a phone that doesn't cooperate with anything.
Also; I tried downloading the .zip directly on my phone, but because it doesn't think there's an SD card, it's refusing to let me download it. It lets me download apps from the market, though.
Any ideas?
PS! Forgot the biggest SNAFU in all of this. On my phone are about 200 pictures from my vacation which I hadn't put onto my computer yet because I am an imbecile. This is keeping me from wiping the phone down to brass tacks and starting all over. If someone can find a way for me to pull said pictures from my device, I can wipe it and see if that helps.
Click to expand...
Click to collapse
Have you tried using an OTG cable to mount a flash drive? That's what I do when I backup/flash anything, I keep all my roms, kernels, backups, basically anything flashable on a flash drive, and use an OTG cable in CWM.
For the pictures:
Step 1; adb reboot recovery
Step 2; adb devices (to make sure it's detected)
Step 2.1: If your phone isn't detected, open sideload in recovery, adb devices again, then close sideload
Step 3: adb pull /sdcard/ C:\<username>\Desktop\sdcardbackup\
To fix everything else you'll probably need to wipe everything and flash a new rom.
EDIT: For future "snafus" the sdcard is on /sdcard/ not /mnt/sdcard/ because it's on internal memory, not mounted memory.
walther1337 said:
For the pictures:
Step 1; adb reboot recovery
Step 2; adb devices (to make sure it's detected)
Step 2.1: If your phone isn't detected, open sideload in recovery, adb devices again, then close sideload
Step 3: adb pull /sdcard/ C:\<username>\Desktop\sdcardbackup\
To fix everything else you'll probably need to wipe everything and flash a new rom.
EDIT: For future "snafus" the sdcard is on /sdcard/ not /mnt/sdcard/ because it's on internal memory, not mounted memory.
Click to expand...
Click to collapse
Well, I feel silly for that confusion. I've pulled everything from the sdcard, which honestly mattered more to me than fixing the phone. I'll putter around with getting the ROM and kernel operating correctly in the next couple of hours.
UPDATE!
Once I had the adb pull command corrected for me, pushing the new ZIP on there was an instant success in recovery. SD card exists correctly once again, installed Viper ROM over, full functionality once more.
Killerkendolls said:
Well, I feel silly for that confusion. I've pulled everything from the sdcard, which honestly mattered more to me than fixing the phone. I'll putter around with getting the ROM and kernel operating correctly in the next couple of hours.
UPDATE!
Once I had the adb pull command corrected for me, pushing the new ZIP on there was an instant success in recovery. SD card exists correctly once again, installed Viper ROM over, full functionality once more.
Click to expand...
Click to collapse
you can always do this too as long as the device is recognized by adb
Code:
adb shell
this will get you into the actual device where you can navigate around by using the " cd /dir_name " command and to go back up a dir use " cd .. " (a space and 2 "."s are needed) or just " cd " to get back to the starting point... if you know how to navigate through a unix terminal then you will know what to do here...
some other useful commands
Code:
ls, ls -a, ls -l, cd, cp, mv
ls = list (lists files/folders) "-a" means all, "-l" just makes it look neat and laid out better.
cd = change directory aka "dir"
cp = copy /path/to/file.ext /path/to/where/you/want/to/save/it/file.ext
mv = move (same as ^ ) except it just moves it and doesn't copy
oh and to exit adb shell just type "exit"
Honestly, just grab a working kernel. And use fastboot. Especially since you're s-off
fastboot flash boot boot.img should get you back in working order.
Sent from my HTC6435LVW using XDA Premium 4 mobile app

[GUIDE] Modfying CF-AutoRoot kit to enable ADB debugging on phone with broken screen

After breaking the screen on my phone I spent the following months reading about how to extract data. It all comes down to enabling ADB debugging and having your computer authorised. Usually this can be done from recovery and you're good to go. However, if you have a broken phone that is fully stock, with ADB disabled and with no custom recovery support then your data is as good as bricked. Such was the case with me when I broke my rare Samsung G360G. However, my phone was supported by CF-AutoRoot by Chainfire, and this gave just the opening I needed to go full wide.
Prerequisites:
Your phone needs to be supported by CF-AutoRoot. Check on there and the new site linked for support of your phone. If it's not there then you will need to download a stock ROM and use the CF-AutoRoot site tool to generate a root package for you. But that is outside the scope of this tutorial. This procedure has only been tested on Samsung. Your phone should have a minimal working charge.
https://autoroot.chainfire.eu/
This tutorial is also based on Linux. It should be translatable to Windows and Cygwin. But for simplicity I'll just use the method I used on Linux. However, if using Odin like I do, you'll need Windows to finish it off.
Aside from this it assumes files in are named in a particular format with a certain file format.
Tutorial:
1. First you need to download a CF-AutoRoot package for your phone. Won't get far without it.
2. Open up a terminal in Linux. We need to download some depends so enter this command:
Code:
sudo apt-get install android-tools-adb android-tools-fsutils
3. We need to extract the archive contents out. Create a suitable folder inside your home folder to build the patch in and cd to it. This uses an example file named CF-AutoRoot-example.tar.md5. Substitute with your actual archive name. Like so.
Code:
mkdir cfar-adb
cd cfar-adb
tar -xf CF-AutoRoot-example.tar.md5
4. There should be a recovery.img and a cache.img.ext4 extracted out. We just need to modify the cache.img.ext4. But first we need to convert it to a workable format. From a sparse to a raw image.
Code:
simg2img cache.img.ext4 cache.raw.ext4
5. We need to mount the cache image
Code:
mkdir cache
sudo mount -t ext4 -o loop cache.raw.ext4 cache
6. The big one. Doing the mod. So now we need to modify the cfar cleanup script. We need to insert commands on the end to enable ADB and add the key to authorise the computer. The following will do just that in this fashion.
a)
You will need to load in the cfar-cleanup.sh file inside the cfroot folder from the cache point mounted. Locate the end and paste the following lines before the reboot and exit commands on the end. Don't save yet.
Code:
echo -n 'mtp,adb' > /data/property/persist.sys.usb.config
mount -o remount,rw /system
echo '' >> /system/build.prop
echo 'persist.service.adb.enable=1' >> /system/build.prop
echo 'persist.service.debuggable=1' >> /system/build.prop
echo 'persist.sys.usb.config=mtp,adb' >> /system/build.prop
chmod 644 /system/build.prop
mount -o remount,ro /system
mkdir -p /data/misc/adb/
echo '' >/data/misc/adb/adb_keys
chmod 640 /data/misc/adb/adb_keys
b)
Load up the ~/.android/adbkey.pub file in a text editor and copy the entire contents in the clipboard. Now back at the script locate that last echo command you pasted into it and set the cursor just after the first single quotation mark. Now paste the clipboard in! This will add your key in. Make sure it's only between the single quotes with no extra characters or line feeds. The lines will naturally split if they don't fit on screen. Otherwise it should be good to go.
c)
Okay now save the file. The above will enable ADB and authorise your computer on the main Android system after the rooting script has done it's work. Before it reboots normally.
7. We need to unmount the cache so it's ready for use.
Code:
sudo umount cache
8. We need to convert the raw image back into a sparse image.
Code:
img2simg cache.raw.ext4 cache.img.ext4
9. Okay were almost done. Now we repack the files into a new Odin archive. Choose a suitable new filename. Like I have done here with my example file.
Code:
tar -H ustar -c recovery.img cache.img.ext4 > cfar-adb.tar
md5sum -t cfar-adb.tar >> cfar-adb.tar
mv cfar-adb.tar cfar-adb.tar.md5
10. The final step! So now the new package is ready for use. We just to use Odin and flash it to the phone. Save the package to a USB stick if needed.
a)
Reboot into Windows. Or you can run it virtualised from Linux. But I prefer to use the real things when dealing with things of a delicate manner and working blindly. Unplug your phone from the computer if connected. Now load up Odin in admin mode.
b)
Just to make sure pull the battery from your phone. Give it a few seconds then put the battery back in and click the back cover on. Now hold down volume down, then home key, and finally hold down power. Wait for the vibration. Then release power after a few moments. Finally release the other keys. At this point press volume up briefly. You should have just put your phone blindly into download mode. I've done this numerous times.
c)
Plug your phone into your computer. After a moment you should see Odin respond with a device added. Usually the phone can vibrate also when it connects giving more positive signs. If nothing happens disconnect the phone from the computer and retry the last step again to put it into download mode. Took me a few tries before I could do it blindly. It helps if you have a working Samsung to test it out on so you can see what happens before you can only feel it.
d)
Now in Odin press the PDA (or AP) button. Select the cfar-adb.tar.md5 package you made up. If the package is fine it will pass the md5 test. Now press the Start button and watch it go! If all goes well it will upload recovery, cache, give you a pass and then the phone will reset. At this point it will be in the process of being rooted, enable ADB, then reboot. If something goes wrong then you may need to go back and check all the patched files. Then rebuild the package again. But be careful, if the ADB has been enabled in the build.prop file one time, you don't want to add it in again and create duplicates, no matter how keen. Once I had it added the only other major problem I encountered was using the correct adb key.
e)
Hopefully now your phone is rooted, has ADB enabled and is booting up normally. Give it a few minutes. You can even see signs of life in Odin with adds and removes on USB activity. Your phone should also vibrate at times. And making noises is also a good sign.
1.1. So I just cranked it up to eleven. Open a Linux terminal again and give it a test. With your phone plugged in.
Code:
adb devices
If all goes well then adb will find your phone as well as list your device as authorised. You can now open shell to the inside. USB debugging is now enabled.
Conclusion:
Well I hope this helps those who have their app data stuck under a broken screen. As long as it was to type in this tutorial It still took me less time to write this tutorial than to learn all that was needed and apply it to my phone. This ends here but for you it may be only the beginning. A next step would be a screen mirroring app which I think is a must have for visual feedback. And USB debugging opens up these possibilities. One thing to be careful of, in a related issue, is that just because you can use adb and the phone is also rooted doesn't mean it will all work at once. If you are tempted to "su" it in an adb shell and get right in there then SuperSU will ask for permission on a blank screen. As will also happen if you try to do an adb backup, it will ask for confirmation on screen. So just expect to work with USB debugging blindly unless you already have a screen mirroring app installed. If you don't have one installed that is your next step.
And on that note. Good luck!
Hi there,
Your tutorial on how to achieve this on Linux looks real neat and complete. Unfortunately, i'm on Windows and i would like to know if you would be able to rewrite this totorial for a Windows user?
I've been reading online for about a week and i've never saw such a complete guide to help newbies to ADB to be able to retrieve data on their locked broken devices.
Cheers!
Hi RaiM1986 and thanks for your kind words. Yes I wrote it so it would be useful to newbies and seasoned hackers alike. Plus I needed to write down some instructions in case I need to do it all again.
Looking at the tutorial it is a bit Linux-centric. I don't know how well it would translate to Windows. Though there would be Windows version of the tools used the main problem would be mounting the filesystem image and making modifications without corrupting it. Because of things like Linux file modes.
However the following tools may be of assistance.
ADB tools:
https://wiki.lineageos.org/adb_fastboot_guide.html
Cygwin provides Linux tools if needed:
http://www.cygwin.com
simg2img:
https://github.com/KinglyWayne/simg2img_win
For mounting the ext4 image:
https://www.osforensics.com/tools/mount-disk-images.html
img2simg and other tools:
https://forum.xda-developers.com/showpost.php?p=49235638&postcount=5
For the ADB key it should be in %USERPOFILE%\.android and other spots I've read of are C:\Windows\System32\config\systemprofile\.android
In case any of the above fails, since I haven't tested them, the easiest alternative might be to just download a Linux live CD, boot it and do the steps inside. Of course any work is lost when you shut it down. You could also boot it in VM program running on Windows.
Amazing guide, Hypexed! The amount of work you put in to figure this out is incredible.
However, I'm stuck on step 6c, where I'm supposed to save the cfar-cleanup.sh file. It's not letting me save it at all, either within the mount point or to another location, it says that I don't have permissions to save the file. I tried the 'sudo chown' to change ownership to try to edit the permissions, but that didn't work either with it still saying I can't have access to the file. Any ideas? There is probably a simple solution, but this is my first time really using Linux so I'm a noob. I'm using Ubuntu 18.04.1LTS installed, not live, dual-booted with Windows, if that's important to know
SpinningQyarks said:
Amazing guide, Hypexed! The amount of work you put in to figure this out is incredible.
Click to expand...
Click to collapse
Thank you for noticing. It really was the culmination of months of hacking and cracking. Not to mention research. I decided I had to write a guide so I could document what I did in case I needed to do it again. And of course if it helped anyone else.
However, I'm stuck on step 6c, where I'm supposed to save the cfar-cleanup.sh file. It's not letting me save it at all, either within the mount point or to another location, it says that I don't have permissions to save the file. I tried the 'sudo chown' to change ownership to try to edit the permissions, but that didn't work either with it still saying I can't have access to the file. Any ideas? There is probably a simple solution, but this is my first time really using Linux so I'm a noob. I'm using Ubuntu 18.04.1LTS installed, not live, dual-booted with Windows, if that's important to know
Click to expand...
Click to collapse
Sorry you got stuck. I can see some issues in my guide. Especially after trying to do 6c again. First I notice I didn't specify where to store all the folders. Somewhere in the home folder obviously but it looks like you sorted that out fine.
I have tested a working solution to the permissions problem. In fact two:
1. Locate cf folder in the cache mount point on the desktop and go into it. Now right click in the window to bring up the context menu and select "Open as Root". Open up the editor as before.
2.. In the terminal run the editor as root. For example:
sudo gedit cfar-cleanup.sh
I've tested this on Mint which is a "relation" of Ubuntu so should work the same.
Now the original permissions should be left intact. I checked and they didn't have the execute bit set which is unusual. It may help here to save your work on the file to a place you can save to in the meantime. So you don't get stuck again. And then unmount your cache mount point, extract the raw image again as per step 4 and remount as per step 5, if the permissions need restoring. They really should be as they are originally set in the image.
Then continue through to step 6 and beyond as you were.
Good luck!

Categories

Resources