Hey Guys i'm trying to do the network unlock on my captivate, its rooted but when i do the command cat /sdcard/nv_data.bin >> /efs/nv_data.bin it comes back with not enough space.
so than i df efs and i get:
EFS: 6064k total, 6064k used, 0k available (block size 1024)
so than i ls efs and i get:
nv_data.bin
nv.log
imei
so since i am replacing the nv data anyways i figured i could remove the nv_data in hopes of clearing space so I do rm nv_data.bin and it comes back with:
rm failed for nv_data.bin, Read-only file system
can somone help? would my method of thinking even work?
thanks
edit would it work if i did
# mount -o rw,remount -t yaffs2 /dev/block/mtdblock3 /system
# rm /efs/nv_data.bin
edit 2:
so i found out that when i removed it through adb it worked, but maybe the edited nv_data file is bigger than the original?
this is what i did to check
- adb shell
- su
- rm /efs/nv_data.bin (no error)
- ls /efs (did not see nv_data.bin in there)
- cat /sdcard/nv_data.bin >> /efs/nv_data.bin (gave me the no space error)
what can i do now?
Talk about timing - your second edit made my post pointless.
Just to satisfy my curiousity, why are you using the cat command? Wouldn't it make sense to cp /sdcard/nv_data.bin /efs/nv_data.bin, as there isn't an nv_data.bin file in /efs to use the cat command on? (My CLI commands are a little rusty, I'll admit...)
If you're using a rom with CWM, try rebooting to CWM and accessing the phone from there first. In my experience, adb access from CWM gives you the read/write permissions you'll need.
Also, if you're trying to replace the nv_data.bin file, I think the commands in adb be:
adb root
adb pull /efs/nv_data.bin (backing up current)
adb shell
rm -i /efs/nv_data.bin
cp /mnt/sdcard/nv_data.bin (or /sdcard/nv_data.bin)
(ls /efs to confirm)
Or something like that?
thanks for the advice, but I ended up just doing a factory reset and redid the whole process and it worked.
Hey all
I have the same error message. when i ls efs i had few more files in there than the OP they are
nv_data.bin
imei
nv.log
cryptprop_onetimeboot
cryptprop_securewipedata
nv_data.bin.md5
this to try putting the original nv_data.bin file back. Id like to put the a modified one which im hoping will let me unlock my captivate.
thanks
Related
i have done a search, but came back with nothing that sounded like an answer to me, what I wanted to know is how would I go about backing up my ext2 partition, so that if I wanted to change my memory card I could just back and restore onto new card and continue using my phone as it was. I am running cyanogen's 4.04 rom with a 500mb ext2 partition on an 8gb card.
Do a quick search in the Dev forum for something called switchrom. Read up on what it does, and you'll see how to do what you want to do. If you can't figure it out after reading up on it, pm me and i'll walk you through it.
cheers...had a look through the whole thread seems like it could be implemented into next update to cyangogen recovery so will wait..dont want to mess around with scripts sounds a little scary!..
I've answered this on a few threads before, but I can't find them to copy and paste :-S
in the recovery console
Code:
cd /sdcard
mkdir app
mkdir app-private
cp /system/sd/app/* /sdcard/app
cp /system/sd/app-private/* /sdcard/app-private
your apps are now on your fat partition, so do your victory dance and copy the two folders on to the root of your new sdcard.
Go back to the recovery console (*not* terminal, it's just not a good idea to do this while the phone is running, but you can use adb shell when the phone is in recovery).
Code:
mount -o rw /dev/block/mmcblk0p2 /system/sd
rm -r /system/sd/*
cd /system/sd/
mkdir app
mkdir app-private
cp /sdcard/app/* /system/sd/app
cp /sdcard/app-private/* /system/sd/app-private
You're done, it's a good idea to wipe and reflash the ROM before you reboot.
Thanks mate, that makes sense..people always say search first but the search function is not the best on the forums..
I will give that code a go..thanks
after the first CP command line it says cp: cannot stat '/system/sd/app/*' : no such file or directory.
it cant find the app dir?
I'm having trouble finding a definitive way of uninstalling/installing apps onto my phone. this is what I've found.
Either through terminal or ADB:
mount -o rw,remount /system (another thread had mount -o rw,remount -t yaffs, /dev/block/mtdblock3 /system... or something along those lines)
rm -r /system/app/appname.apk
That only seemed to work for com.amazon.mp3.apk.
I've used astro file manager to find out the app names, for example on CM 4.0.4 he has the Work email, which I don't use. Under astro it is called just "Mail". I tried removing mail.apk and i've tried removing com.htc.android.mail.apk (which is what the app says under astro) but I cannot remove that one, nor any of the easier ones (camera.apk etc...). Only amazon mp3 was removed.
Am I missing something?
Also, installing apps. I am having trouble finding out how to push your own.
Any help with these?
Thanks
Easiest way would be to get root explorer off the market.
Or with adb do
Code:
adb remount
adb shell
rm /system/app/xxxx.apk (or if that doesn't work put -r after rm
In recovery console do
Code:
mount system
rm /system/app/xxx.apk (or -r if doesn't work)
Thats how i remove system apps.
same thing...
I tried rebooting into the console and trying this, here's what I got.
# Mount System
# rm /system/app/com.amazon.mp3.apk (this one works)
# rm /system/app/mail.apk
rm: cannot remove '/system/app/mail.apk' : No such file or directory
# rm /system/app/com.htc.android.com.apk
rm: cannot remove '/system/app/com.htc.android.com.apk' : No such file or directory
the others don't. I am finding the root address the same as with amazon mp3.
I am running CM 4.1.9. I tried it with 4.0.4 but I get the same issue. Only app that comes out is the amazon mp3. I am trying to delete the Work Email, Voice Dialer and push in the My Faves.
Any ideas what I am doing wrong?
Filenames are case sensitive.
/system/app/Mail.apk
/system/app/Camera.apk
Go to your apps directory to see the filenames with
Code:
cd /system/app
ls
Forum search adb explorer
AdamPI said:
Filenames are case sensitive.
/system/app/Mail.apk
/system/app/Camera.apk
Go to your apps directory to see the filenames with
Code:
cd /system/app
ls
Click to expand...
Click to collapse
Ahhh, Case sensitive. I didn't realize. Thanks for the info. You are the man!!!!!!!!
That was exactly it.
Thanks again!!!!!
hey guys i'm trying to copy my efs partition using adb shell using ramads code
"cd c:/your_ADB_directory_name/platform-tools (Use cd c:/your_ADB_directory_name/tools if you are using an older ADK versions)
adb shell
su
cp -r /efs /sdcard/efs
exit
exit"
I get to the *cp -r /efs /sdcard/efs* and it spits out a million and one errors saying it can't create any of the files due to there being no space.
my phone storage has 1.65gb and my SD has 8.3gb free of space so i'm quite puzzled by why it's saying this.
Check my thread to see if it helps...
http://forum.xda-developers.com/showthread.php?t=859914
Cheers!
Hi folks,
On my way trying to get 10 usefull posts to access the developers forums, I have writen this easy tutorial. xD
THIS IS FOR S5830i DEVICES. init.rc used belongs to S5830i ramdisk
Whats all about? Well, in this tutorial I will so you how to get root access directly from Kernel only modifing init.rc and adding su to tmp folder.
THIS IS NOT UNSECURING THE BOOT.IMG TUTORIAL
Question: Axyllum why are you posting this, if there are so many tutorials on how to do this for other devices?
Answer: Simple, as you all ready imagine, partition for boot.img is just 5MB Oh my god.
Then, if my boot image is all ready 4.28MB, how can I use a busybox thats 836KB (I compiled a busybox with mount, cp, mkdir, chmod and chown that is the minimum to get root: image = 836MB). Cant use this beacuse I exceed total mounting point size.
Kernel + ramdisk = 4.28MB if you pull stock boot.img from your device.
Minimum busybox explained before = 836KB
SU image 25KB to 86KB depending on the su image you use.
This makes a total of: 5.2MB. Try to flash it. It fails? Yes, you exceeded the mounting point size.
And the solution? Follow my tutorial.
Abilites you will need to follow the turotrial:
Know how to: Un pack & repack boot.img
Know how to: Decompress Ramdisk and compress it back. (to get the famous newramdisk in many many tutorials) newramdisk is just a name, you can compress back to any name, for example axyllumramdisk or yourramdisk or how ever you want to call it.
Asuming you know how to do the explained above and after my wierd chat, lets gooooo:
1. Open init.rc in your favourite text editor.
2. Go to this line in init.rc:
mount rfs /dev/stl9 /system check=no
You should see this:
mount rfs /dev/stl9 /system check=no
mount rfs /dev/stl9 /system ro remount
Got it? lets go to step 3.
3. Overwrite both lines with this:
mount rfs /dev/stl9 /system check=no
mkdir /system/xbin
copy /tmp/su /system/xbin/su
chown root root /system/xbin/su
chmod 06755 /system/xbin/su
mount rfs /dev/stl9 /system ro remount
Make sure you are not overwriting other lines or your ramdisk could not work.
4. Paste SU image file to tmp folder. Make sure SU image has execute permissions.
5. Compress back ramdisk (the famous newramdisk).
6. Repack boot.img
7. Flash it.
8. Restart device.
9. Download superuser.apk and busybox form market and.... there you go you made your kernel with root access and no need of a busybox.
Ok, this was simple, but i imagine more than one will like to know what we did.
I'll explain:
As we cant add a busybox, how the hell am i going to mount system rw, mkdir xbin, cp su from tmp to xbin, chmod / chown permissions?
I started reading the init.rc file (i was bored and my wife wanted to go shopping --> no way i have an init.rc file to mess up with), and I saw many mkdir, copy, chmod etc... commands. (Opened a beer)
So i thought, great, there is all ready a busybox with the least i need to make this. Then why dont i use this preinstalled commands?
And i did this:
mount rfs /dev/stl9 /system check=no --> first I checked this, this instruction is where init.rc mounts system. At this point system is mounted RW.
mkdir /system/xbin --> Then as system is rw, I will create xbin folder. how? with mkdir comand.
copy /tmp/su /system/xbin/su --> Great I did not find a cp command, but found a "copy" command someware in init.rc. Search for it, you will see its used. Then why dont I use it to copy SU in tmp folder to the just created xbin folder? It worked.
chown root root /system/xbin/su --> Owner of su in xbin is: yes, root.
chmod 06755 /system/xbin/su --> Set the right permission to su. You need to chmod with 06755. --> 09364, 66666, 83823 will not work looooolll just a joke i imagine you all ready know what setting permissions is all about.
mount rfs /dev/stl9 /system ro remount --> Remount system with ro (this is the read only remount command).
I dont know if there are any other tutorials doing this, this way, i just did it my self. I Found tutorials on doing the same, but busybox, and .sh script and su were needed. To much for our small boot.img partition.
Enjoy.
Tip, dont mess your init.rc if you do not understand it.
So, I went to fastboot and flashed my stock system image, recovery, boot....
booted up and it works fine.
But, I'm still rooted, even though the backup wasn't. wat.
so, now I'm on a fully stock system with root, and need to unroot. how do I?
In order to create an image of your system partition, your device needs to be rooted. Since 'root' is on the system partition, it will be rooted when you restore it again.
Open Android Terminal Emulator or adb shell and enter the following:
Code:
su
mount -o remount,rw system
rm /system/app/Superuser.apk
rm /system/xbin/su
Voila, root gone!
soupmagnet said:
In order to create an image of your system partition, your device needs to be rooted. Since 'root' is on the system partition, it will be rooted when you restore it again.
Open Android Terminal Emulator or adb shell and enter the following:
Code:
su
rm /system/app/Superuser.apk
rm /system/xbin/su
Voila, root gone!
Click to expand...
Click to collapse
It seems like today isn't my day.
Code:
[email protected]:/ # rm /system/app/Superuser.apk
rm failed for /system/app/Superuser.apk, Read-only file system
255|[email protected]:/ # rm /system/xbin/su
rm failed for /system/xbin/su, Read-only file system
255|[email protected]:/ #
System is read only right now, and I'm not familiar wnough with adb shell to flip it to rw...
edit: luckly, I know my way both around Google, and around the linux terminal.
mounted as RW, removed, rebooting the tablet now. if it takes I"ll restore it and see if it sticks there too. thank you!
Oh yeah, you might want to remount the system partition first
I'll edit my response accordingly.