Root [Boost Mobile] Now I'm a Super User, but Stuck

cmpyutr

Newbie
I go into terminal emulator. Get a $ prompt. Enter su root, get a # prompt. Thought I could cp myfile sdcard (/mnt/sdcard). Nope, cp is not an available command. So I try mv. mv works to rename, but when I try to mv myfile /mnt/sdcard, get a message about failure due to cross link. Typical message ya get, I read, when one of the devices is not mounted. I'm thinking /mnt/sdcard is mounted, and so is wherever I am when I am at /. Can anyone help me copy a file over to the sdcard, so I can upload to my pc and analyze it?
 

Skinnyjeans21

Android Expert
you might have to run that command through adb after the command "adb shell" w/o the quotes. I think thats an adb command not something that can be executed via terminal emulator
 

jimsmith80

Android Expert
It all depends on how your simlinks are set up. To run the cp command on the stock rom with root you have to run toolbox cp /path/to/file /destination/of/copy
 

cmpyutr

Newbie
Thread starter
It all depends on how your simlinks are set up. To run the cp command on the stock rom with root you have to run toolbox cp /path/to/file /destination/of/copy

Okay, thanks. "toolbox", is that busybox? which I understand is likely installed to supplement the meager commands present in the os. If so, then do you mean

/path/to/busybox/folder cp /path/to/file /destination/of/copy ?

Like /bin/cp /data/myfile /mnt/sdcard/myfile, where I know I have a simlink for example which is sdcard -> /mnt/sdcard. So is "toolbox" a simlink for where busybox files are?

Thanks.
 

cmpyutr

Newbie
Thread starter
Okay, little more investigation on my part. I notice from the output of ls -l that I get this:

lrwxrwxrwx root root 2013-12-20 22:48 cat -> toolbox
lrwxrwxrwx root root 2013-12-20 22:48 chmod -> toolbox
lrwxrwxrwx root root 2013-12-20 22:48 chown -> toolbox

and so on.

So I typed:

$toolbox ls

which gave me valid output, but when I typed

$toolbox cp

output was

cp: no such tool

So apparently, my simlinks are fine, cuz my "mv" command worked, but cp is just not one of the commands available in the toolbox. I figure, like skinnyjeans said, I could use adb shell. But if I knew Linux better, maybe I could copy over a file from somewhere to the sdcard, maybe with "dd". dd appears to be a tool in the toolbox. how about dd path/to/infile path/to/outfile? Just don't wanna get in trouble, y'know?

Thanks.
 

cmpyutr

Newbie
Thread starter
Okay, think I got it now. From terminal emulator, you got:

$

then, cuz the file was in a directory that I didn't have access to, unless I was root, I did

$su root

Dangerous, ladies and gents. Be careful.

so now I got

#

then I did

#dd if=myfile of=/mnt/sdcard/myfile
98+1 records in 98+1 records out

#exit
$exit

Scary. Glad I didn't reverse the if= and the of=. data destruction
 

jimsmith80

Android Expert
Now that your rooted installing busybox is a simple as downloading an app from the play store. It will set up the simlinks for you, so all you will need to do is run cp.
 
Top