Access root files from PC


  1. prj

    prj Well-Known Member

    Is there a program out there that lets you access the root directory on the phone from Windows to view, move, delete and copy files?

    Advertisement
    :
  2. scary alien

    scary alien not really so scary Moderator

    prj,

    Well, its the Android SDK's adb.exe utility. Its got the ability to push and pull files from to/from Windows as well as being able to invoke a shell to Linux on your phone.

    Here's some example commands to illustrate this:

    First, demonstrate sending (pushing) a file and retrieving (pulling) a file:

    c:\temp>
    c:\temp> cd c:\android-sdk-windows\tools
    c:\android-sdk-windows\tools> adb push c:\temp\testfile.txt /sdcard/download/fromwindows.txt
    c:\android-sdk-windows\tools> adb pull /sdcard/download/fromwindows.txt c:\temp\fromphone.txt

    Now, doing stuff from the shell:

    c:\android-sdk-windows\tools> adb shell [ launch a shell to the phone ]
    $ pwd [ display present working directory ]
    /
    $ cd /sdcard/download [ change directories ]
    $ pwd
    /sdcard/download
    $ su [ get root access ]
    #
    (notice how our prompt changes to the pound-sign to indicate we've now got root capability)
    # ls [ list the files in current directory ]
    fromwindows.txt
    # mv fromwindows.txt fromwin.dat [ rename a file ]
    # cp fromwin.dat savefromwin.dat [ copy a file ]
    # ls
    fromwin.dat savefromwin.dat
    # cat fromwin.dat [ copy a file to the stdout (screen) ]
    hi there, I'm a file that you created on Windows and transferred to your phone.
    # rm fromwin.dat [ delete a file ]
    # ls fromwin.dat
    rm failed for fromwin.dat, No such file or directory
    # cat savefromwin.dat > fromwin.dat [ copy a file to another file ]
    # ls
    fromwin.dat savefromwin.dat
    # exit [ terminate the shell and return to Windows Command Prompt ]
    c:\android-sdk-windows\tools>

    And on and on... Note: you can do all of the stuff above from the shell session using something like the Android Terminal Emulator (free in the Market), but you don't get to it by invoking "adb shell" (you only do that from Windows when in the SDK tools directory).

    Oh, also, the root directory would be "/" on the phone. You can "cd /" to change to that directory to start navigating.

    Hope that helps...cheers!
    xpierrelouis, JaymzA and ABCDawg like this.
  3. doogald

    doogald Guides Guide

    Scary, I had just typed a similar post to yours, decided to preview, and there yours was. Excellent, though probably not what the OP was thinking he was going to get. ;)
  4. scary alien

    scary alien not really so scary Moderator

    Lol! Thank you again, doogald, I always appreciate you being there to catch me when and if I fall :).

    I actually typed it from how I think it should behave rather than testing how it really does (so I hope I didn't make any typos). I sit on a AIX Unix box at work all day, so I better know my shell commands ;),

    I figured I'd give a taste of things instead of too much since there's so may ways to do things in Unix. prj, if you need elaboration, please let us know.

    I did have trouble with the "CODE" formatting--I think it was all of the backslashes I posted. It looked alright after I was done, so I left it that way.

    Cheers!
  5. TJTHEBEST

    TJTHEBEST Well-Known Member

    root explorer
  6. prj

    prj Well-Known Member

    Scary...Your post reminds of the old DOS days. Ahhhhhhhh! :eek: :eek:

    xene97...That is exactly what I was looking for. Works perfect. Thanks.
  7. scary alien

    scary alien not really so scary Moderator

    Very nice! I think I saw this way earlier in the year and totally forgot about it. Pretty nice idea for some folks. Good post! Do you use this?

    Hey, don't forget the CP/M days, too! I've still got my Kaypro II with its 5.25-inch floppys, 2.5MHz (yeah, that's megahertz, not giga- :eek:) Z-80A processor so I could play Zork (my favorite computer game of all time :cool:).
  8. xene97

    xene97 Well-Known Member

    I do use Android Commander. I like to backup all of the apks before I kill them. My fingers have been dyslexic lately so it's easier to use a GUI interface to copy & delete rather then to continually backspace & retype in order to use ADB.

    Believe it or not, but I just threw away an unopened box of 5.25" drives. I still remember marvelling at them when they came out - so much smaller than the 8" ones my father used to use!
  9. chan2828

    chan2828 New Member

    I have a rooted HTC Wildfire. I used root explorer and delete applications from the system/app. But after reboot the deleted applications (pre-installed) came right back.
    How would I be able to uninstalled those unwanted pre-installed applications?
  10. Podivin

    Podivin VIP Member VIP Member

    Try deleting apps using Titanium Backup. I've never had one come back doing it that way.
  11. RootNoob

    RootNoob New Member

    So my device is rooted however using "su" in the shell doesn't change the prompt.. and I am unable to gain full access to the device file structure etcetera.. Any ideas????
  12. scary alien

    scary alien not really so scary Moderator

    How did you root (i.e., what method did you use)?

    If you can't see the "#" prompt in a terminal session on your phone, then must not be fully rooted with the su program and SuperUser app...

    Did you just run the 1-click app to install the custom recovery (and perhaps not (yet) flash the rootme.zip file)?

    Let us know (the more details and background, the better ;)).

    Cheers!
  13. HR47

    HR47 New Member

    Hello,
    I have a problem with the camera on my samsung galaxy s
    when you start the application appears on camera failure,
    I've been reading some sites and it seems that replacing the system files / firmware for the original files from another galaxy the problem is solved,
    The problem is that even with the root done I can not copy files to it, it gives me an message saying link error Incompatible (I'm copying the original files in the folder sdcard / bluetooth)
  14. scary alien

    scary alien not really so scary Moderator

    HR,

    I think you'll want this forum: Samsung Galaxy S - Android Forums

    We love to hear from folks here in the HTC Droid Eris forums, but not sure that we can help you. The good folks over in the above Samsung forums should be able to help address your issues.

    Cheers!
  15. Scurge

    Scurge New Member

    so I did all of the above and got the adb shell to work ok and everything worked fine, however, the file I wanted to get keeps saying permission denied. I really need into this file, it is in the /data/system directory on the phone. is there any way around this? i tried to pull it and tried to cat the file but nothing. any advise? I haven't rooted the phone and dont want to if i can help it. I'm worried that things like gmail that stay logged in will "forget" the passwords, just like my wife did... help please.

    edit: oh yeah and its a eris phone
  16. metlcat

    metlcat Well-Known Member

    To access anything in the system/data directory you will need root.
  17. Bob Cat

    Bob Cat Careful, They're sharp!! Moderator

  18. Onewayoflife

    Onewayoflife New Member

    I didn't realise that you could get root explorer for PC.
  19. droidros

    droidros Well-Known Member

    Is there Root Explorer for PC?

    I have the Root Explorer app on my phone (Droid X) and was looking for an app with similar functionality that I could use on my PC, as it's pretty hard to manipulate fields or make edits on the phone.

    I tried Android Commander and really liked the interface - but it wouldn't access my /data files. Apparently I needed to have "full" root access, which I haven't. Then, while I was messing with it to try and get it to work, my PC froze and I ended up having to do a system restore.

    Although I wasn't able to use AC to edit my files, I did really like the screen shot capability of Android Commander so tried to redownload the application (I had restored to a previous checkpoint). But I got messages about how it might be harmful to my computer - and its website had been down for several days, which wasn't a good sign - so I ended up not downloading it again.

    So, I'm still looking for an Android file editing program for the PC. Has anybody else had problems (i.e., malware type problems) with Android Commander? If not, maybe I should give it another try.

    If I copy the data files into the SDcard folder on the phone (same place where media files are stored), would I be able to access them using such a program even though I'm not "fully" rooted?
  20. Bob Cat

    Bob Cat Careful, They're sharp!! Moderator

    Actually I think I did read somewhere about something similar but I can't rember where
  21. doogald

    doogald Guides Guide

    What do you mean by "full" root access? Are you rooted or not?

    As far as I know, the /data partition is not accessible to a non-rooted account - for very good reason, really. If you are rooted, you can access any partition from a terminal/command prompt if you have the Android ADB app installed and have basic knowledge of *nix commands (i.e., cp to copy file, rm to remove them, etc.)
  22. droidros

    droidros Well-Known Member

    I am not exactly sure, but this is what I understand. I am rooted, using the 1-click method (or whatever it's called) and I can access my data files on the phone using the Android App Root Explorer. However, apparently I have to also perform a few more steps and flash a custom ROM to be "fully rooted" -- which I haven't done because I haven't figured out all the steps or what ROM to choose.

    Anyway, I downloaded SQLite Database Browser for Windows from Download SQLite Database Browser Free . Although I still cannot get to the files in /data from the PC, I can browse and edit sqlite files on the SD card. So, I copied the database file from /data to /sdcard and was able to edit it using this program. After editing, I copy the file back to the /data folder.

    My phone is Droid X but I think this program should work for the OP.
  23. doogald

    doogald Guides Guide

    I think that there is a misunderstanding of terms. As far as I know, every 1-click root app will add the Superuser binary and SU app to your phone. If you have that, you are fully rooted - you can do anything that superuser (i.e., administrator level user access) will give you, including running apps ike Root Explorer, Titanium Backup, etc. Custom ROMs include all that as well, plus they may pre-install a few other options (i.e., replace the custom Motorola messaging apps, in your case, with stock Android versions), plus they do ot include the pre-installed bloatware that is on your stock, rooted Droid X (which you can remove, or "freeze", in any vase, since you are rooted.)

    Anyway, it looks like you are all set...
  24. droidros

    droidros Well-Known Member

    Thanks - and I also thought that I was fully rooted because I have been able to use Root Explorer and Titanium Backup, etc. However, I haven't been able to access any data files from the PC, either with Android Commander or SQLite Browser. With AC, I was able to navigate to the root directory and saw all the folders listed, but when I opened the /data folder, it wouldn't populate.

    Using SQLite Browser (I no longer have AC) I seem to only be able to get to the files in the /SDcard folder. I can't find a way to get to the root directory. Any ideas?
Loading...

Share This Page