Hey guys, so I am having a very odd problem with adb push. I am a bit of a newb with this stuff, but I am trying to root my phone (Samsung Stratosphere), which has been kind of an undertaking so far. I am following the tutorial on androidcentral, but on the step where I need to execute "adb push su/system/bin" I encountered this error.
It just prints the man file, like I didn't even say 'push'. I have zero idea why this happens, since it doesn't happen with any other adb commands, just push. Can you guys help me out? I have no idea what I'm doing wrong, and the oddness of the error suggests to me that it's just something I don't know about because I haven't ever done this before.
I appreciate any suggestions you might have at this point.
NearlyNoon said:
Hey guys, so I am having a very odd problem with adb push. I am a bit of a newb with this stuff, but I am trying to root my phone (Samsung Stratosphere), which has been kind of an undertaking so far. I am following the tutorial on androidcentral, but on the step where I need to execute "adb push su/system/bin" I encountered this error.
It just prints the man file, like I didn't even say 'push'. I have zero idea why this happens, since it doesn't happen with any other adb commands, just push. Can you guys help me out? I have no idea what I'm doing wrong, and the oddness of the error suggests to me that it's just something I don't know about because I haven't ever done this before.
I appreciate any suggestions you might have at this point.
Click to expand...
Click to collapse
From what you mentioned its a syntax error for the ADB push command. You did:
Code:
adb push su/system/bin
When the correct syntax would be:
Code:
adb push su /system/bin
There should be a space in between su and the /system/bin path. Also make sure the su binary is located in the folder where you have ADB and Fastboot. The syntax for the ADB command adb push in general is:
Code:
adb push <file> <path you want to push file to on your device>
Again note the space in between the file parameter and path to push the file to your device parameter. Let me know if you still have questions I'll be happy to help.
Sent from my SCH-I535 using xda premium
Thanks so much! You were totally right, it was a syntax error.
Related
Hey guys
One of the things im working on atm, having a bit of trouble trying to get a sysctl.conf I am working on to be loaded at startup
I've managed to generate the file, edit what i want, gotten it into /etc, but therein lies the problem
when i try to run systl -p, it keeps telling me the following:
sysctl: error setting key <insert sysctl key here>: Permission Denied
How can i overcome this? As soon as ive finished the work on this file, I'll be happy to share it with everyone
so no ideas?
Do you have superuser permissions (su, command prompt #) ?
When trying with this:
-p
Load in sysctl settings from the file specified or /etc/sysctl.conf if none given.
Perhaps this helps ?
-e
Use this option to ignore errors about unknown keys.
I try running su from command prompt
after using adb shell, all i get after running su is this
Brief 5sec delay, and permission denied. Thats what i dont get, I've Rooted the phone using the guide on the forums and everything went to the letter
*Shrugs* I dunno, tried the -p, thats what gives me the error i get.
Nutterpc said:
I try running su from command prompt
after using adb shell, all i get after running su is this
Brief 5sec delay, and permission denied. Thats what i dont get, I've Rooted the phone using the guide on the forums and everything went to the letter
*Shrugs* I dunno, tried the -p, thats what gives me the error i get.
Click to expand...
Click to collapse
Look at your phone to allow Superuser permission after entering su in the terminal or command
Sent from my X10i using XDA App
had a bit more of a fish round the net to see if anyone else ham similar issues
seems i was able to find the eventual root cause of it, was /system/bin/sh was set to secure mode, so i downloaded root explorer and changed the permissions
now the only thing is, how do i actually get the sysctl.conf im working on to be loaded at start, when i turn the phone on?
You might find something useful in this thread:
http://forum.xda-developers.com/showthread.php?t=523707
So as the title suggests whenever I run the crackin.bat file in order to prepare my legend to be downgraded, it always displays the
cr--rw---- 1 1001 2002 90 line instead of the needed crwxrwxrwx 1 1001 2002 90 line.
I have looked everywhere to find a solution to this problem yet no matter where I look, everybody seems to be able to fix this by just either turning off and on their phone or wiping it. But I have tried all of those and, I have also tried doing this step on a different computer and reinstalling the needed files yet to no avail.
So if anybody has a possible workaround please do share it so I can finally root my phone after many tedious hours.
Sorry for the noob question and many thanks in advanced to anyone who can help me.
Azaruc said:
- Get visionary+
- Temproot your legend with it
- Use commandline with adb on your pc to flash misc1-2.img.
type the following commands from the folder where you have adb;
Code:
adb shell
su
accept the notification on your phone if one comes up
and then in the command line type this;
Code:
/data/local/flash_image misc /data/local/misc1-2.img
That should be enough to make it possible to run the 1.31 RUU.
Click to expand...
Click to collapse
http://forum.xda-developers.com/showpost.php?p=11863394&postcount=2
Ahh, thank you. I had come across that before but i just didn't think that it would help! Silly me.
Ok, is there an IRC chat for the legend somewhere, im STILL getting this error. I can't find visionary+ anywhere where im sure enough its not going to mess up my phone, and i aparently am missing the files needed however none of the guides have downloads of everything i need.
PLEASE can someone help me? im so confused nothing is making sense. I get to copying files from DxDrx but that is nonexistant, what am i missing?
Ok, i got passed this step by doing these steps
1: download visonary here
http://forum.xda-developers.com/atta...3&d=1290501865
or here
http://content.modaco.net/dropzone/com.modaco.visionaryplus.r13.apk
or you can get it off the market
Then download hack4legend here http://www.multiupload.com/I3ZALKWB6A and unzip it somewhere (this is adb and the rooting tools)
2: install and open up visonary on your phone and do a temp root on your phone.
3: open up cmd and type in the following
cd "your hack4legend path here but with out the "" "
adb shell
su
4: after you do that on your computer you should see a notification on your phone come up, it might take a little. Accept it.
5: type this into the command promt
/data/local/flash_image misc /data/local/misc1-2.img
6: run the 1.31 RUU and your good.
Hope this helps
Unreal_628 said:
Ok, i got passed this step by doing these steps
5: type this into the command promt
/data/local/flash_image misc /data/local/misc1-2.img
Click to expand...
Click to collapse
/data/local/flash_image: not found
what am i doing wrong? i had to copy the contents of hack4legend to my adb folder so i have adb, is that it? do i have to change the drectory somewhere?
Mmm, if their is a platform tools sub folder in the android sdk try putting the hack 4 legend in there and re trying. It will either have to go in there or the tools sub folder in the android sdk.
And also make sure that when you use the cd command make sure to not just go to the android ask folder but into the platform - tools/tools depending on where you put your hack, try putting it in both and using different paths. Also you might wanna try updating the adb module "android sdk platform - tools revision 3" through the sdk manager.
And as allways make sure you have usb debugging on and have your phone connected to the computer through charge mode only.
I've got all the files loaded on my phone, ext2 partition created, adb installed etc. When I go to type in
Code:
sh /sdcard/ubuntu/ubuntu.sh
I get an error [!: not found. Any ideas?
I have tried deleting & adding the folder back, redownloaded the files, still get this error message. I've even went to the ubuntu folder while in adb shell and verified the files could be seen ("ls" command) in the shell, which they could.
Any help would be great!
Ideas?
Anybody have an idea?
I give up... can not figure it out & I can't get any help from anyone. Looks like I'll stick with carrying my laptop around for Ubuntu..
Sent from my Xoom using XDA Premium App
I don't really know what you're trying to do offhand, but if the file is on your sdcard and not in a unix file system (ext) then it wont execute. If it is, then make sure you have execute permissions (chmod 755).
type ls -l /sdcard/ubuntu/ubuntu.sh
to verify
Sorry you're not getting much help. Have you tried sending a private message to the guy who pioneered that whole process?
tbh, not many people have use for ubuntu on droid. It's cool, sure, but I don't dev, and I have far more functionality on gingerbread than ubuntu.
Per this issue, and specifically this comment, I'm trying to grant the BATTERY_STATS permission to GSam Battery Monitor. I've tried the adb command "pm grant com.gsamlabs.bbm android.permission.BATTERY_STATS" but can't get it to work. I've also tried "pm grant com.gsamlabs.bbm android.Manifest.permission.BATTERY_STATS" but the results are the same. Doing it through ConnectBot gives me the following error:
Operation not allowed: java.lang.SecurityException: grantRuntimePermission: Neither user 10338 nor current process has android.permission.GRANT_RUNTIME_PERMISSIONS.
Doing it through adb gives me this:
Bad argument: java.lang.IllegalArgumentException: Unknown package: com.gsamlabs.bbm
This is on a stock Moto Z Play, 7.1.1
kernel:
3.18.31-perf-g757c8d9
[email protected] #1
Build number NPN26.118-22
Are you running the pro version? Then it needs to be com.gsamlabs.bbm.pro
The error is because it can't find a package named com.gsamlabs.bbm, so I would investigate why that's occurring. Either there's a typo (I don't see one) or that's not the correct package name.
ConnectBot won't work because ConnectBot doesn't have superuser permissions. Unless your device is rooted it'll have to be done through adb or using a PC-side program which effectively does the same thing.
Thanks! I think that was it, as adding .pro to the end didn't give an error. But it didn't actually say it was successful, either. It just spit out all the adb usage info like if you just type "adb" with no parameters. Any idea how I know if it worked?
vertigo_2_20 said:
Thanks! I think that was it, as adding .pro to the end didn't give an error. But it didn't actually say it was successful, either. It just spit out all the adb usage info like if you just type "adb" with no parameters. Any idea how I know if it worked?
Click to expand...
Click to collapse
Do the advanced stats in BBM work now? Also, are you on the paid version of BBM? That's the pro version, iirc.
You are typing "adb -d shell pm grant com.gsamlabs.bbm.pro android.permission.BATTERY_STATS", right?
Got busy with other stuff and just now got back to this, but I got it working. The reason I got the output I did before was because I was typing an invalid command, since pm grant isn't one of the commands of adb.exe. I had to type adb shell THEN type the command, and then it worked (and I just noticed you said that, I must have overlooked that when I looked at it before since I was busy). Also, for anyone that might come across this trying to do this, GSam didn't automatically recognize that this was done. I had to go through the steps of having it show me how to do it and at the end of that it worked. One final note, I had to update to the latest SDK for it to work, the version I was using was too old. Thanks again for the help apraetor!
Yea, I had a feeling after re-reading your original post that you were missing the "adb -d shell" portion, glad it's working.
vertigo_2_20 said:
Got busy with other stuff and just now got back to this, but I got it working. The reason I got the output I did before was because I was typing an invalid command, since pm grant isn't one of the commands of adb.exe. I had to type adb shell THEN type the command, and then it worked (and I just noticed you said that, I must have overlooked that when I looked at it before since I was busy). Also, for anyone that might come across this trying to do this, GSam didn't automatically recognize that this was done. I had to go through the steps of having it show me how to do it and at the end of that it worked. One final note, I had to update to the latest SDK for it to work, the version I was using was too old. Thanks again for the help apraetor!
Click to expand...
Click to collapse
Hello there, it's been a while since I've been here, I had a Samsung Galaxy S2 last time I posted. Anyway...
I was trying to enable the Camera2 API, so I unlocked my bootloader for it. I followed a guide that explained how to do the API thing without installing a custom recovery or rooting, however while everything went well (no errors during the procedure), the API wasn't actually enabled. And I confirmed it by reading the build.prop file, finding out that the "persist.camera.HAL3.enabled=1" line was not in it.
The guide I followed consisted in booting the TWRP recovery from fastboot, and pushing commands through adb shell that way; "setprop persist.camera.HAL3.enabled=1", to be precise. It didn't work though.
So naturally, I searched for another way, and found one that uses a different way of adding that line to the build.prop file, by pulling said file from the system partition, editing it on the PC running adb, pushing it back to /system, and setting the permissions through the following commands:
Code:
adb pull /system/build.prop
Then, after editing the file through notepad++, adding the "persist.camera.HAL3.enabled=1" line
Code:
adb push build.prop /system
to put it back, edited, and then to set the permissions
Code:
adb shell
cd system
chmod 644 build.prop
My question is: can this second method be mixed with the frist one? Essentially, can I do the pull/edit/push/chmod series of commands off of a TWRP that I'm temporarily running via fastboot? Or does it have to be installed?
I know that you might wonder "why don't you just flash it, making your life easier?", but now it's a matter of principle, I need to know if this can be done without doing it. Plus, since I don't plan on doing anything else that needs it, it's kind of a waste of time having to then go back to the original recovery.
Hope someone can help me with this doubt, thanks in advance to anyone who will!