MaxoYour tax dollars at work. Premium Member join:2002-11-04 Tallahassee, FL |
Maxo to EUS
Premium Member
2012-Nov-30 1:33 pm
to EUS
Re: adb umount problemssaid by EUS:How about starting over and posting the proper output from the proper device, so we can see what's happening, and give some good advice? Agreed. Restart from "adb shell" and then copy everything you do into this thread. |
|
|
unibroker Premium Member join:2010-11-12 Coeur D Alene, ID |
okay |
|
unibroker 1 edit |
adb devices List of devices attached 2010720135452002 device
adb shell root@android:/ #
adb shell root@android:/ # umount /sdcard/ failed: Device or resource busy
I don't know why I am logged into the adb shell as root. I never login as root.
|
|
MaxoYour tax dollars at work. Premium Member join:2002-11-04 Tallahassee, FL |
Maxo
Premium Member
2012-Nov-30 1:45 pm
If you want to transfer a file from your PC to your phone try this.
~ touch ~/foo ~ adb push ~/foo /sdcard/ ~ adb shell shell@android:/ $ cd /sdcard shell@android:/sdcard $ ls -l foo -rw-rw-r-- root sdcard_rw 0 2012-11-30 13:41 foo shell@android:/sdcard $ exit ~
|
|
Maxo |
to unibroker
said by unibroker:adb devices List of devices attached 2010720135452002 device
adb shell root@android:/ #
adb shell root@android:/ # umount /sdcard/ failed: Device or resource busy
Those commands, if it actually worked, would unmount the sdcard that is inside your phone, from the Android OS. |
|
unibroker Premium Member join:2010-11-12 Coeur D Alene, ID |
to Maxo
Is my particular filename in this? This looks more complicated than my single push command but if it'll allow me to transfer and to safely remove device I'm willing to give it a try. |
|
MaxoYour tax dollars at work. Premium Member join:2002-11-04 Tallahassee, FL |
Maxo
Premium Member
2012-Nov-30 1:52 pm
The foo in my example is just a placeholder. Replace it with the actual file on your PC. When you transfer a file with adb push the filesystem on your phone is never mounted to your computer so no mounting or unmounting is needed. You can simply exit out of the adb shell and unplug your phone. adb push and adb pull are the best two commands for transferring files to and from your computer.
Edit: And you don't need to run the touch command. I just used that to create an empty file. |
|
unibroker Premium Member join:2010-11-12 Coeur D Alene, ID |
to Maxo
So when I type "exit" from adb shell that umounts at the same time? I don't mount manually so this would make sense. |
|
MaxoYour tax dollars at work. Premium Member join:2002-11-04 Tallahassee, FL |
Maxo
Premium Member
2012-Nov-30 2:00 pm
said by unibroker:So when I type "exit" from adb shell that umounts at the same time? The device never got mounted in the first place, so there is no need to unmount it. Mounting allows the filesystem of a device to exist in the tree of the PC. Instead, with adb, we are creating a connection similar to SSH or even telnet. |
|
|
unibroker Premium Member join:2010-11-12 Coeur D Alene, ID |
to Maxo
# ls -l cm-10-20121129-UNOFFICIAL-encore.zip ----rwxr-x system sdcard_rw 157698499 2012-11-28 20:22 cm-10-20121129-UNOFFICIAL-encore.zip
Looks like I have no permissions and Group has them all! Even everyone else has more than me.
|
|
MaxoYour tax dollars at work. Premium Member join:2002-11-04 Tallahassee, FL |
Maxo
Premium Member
2012-Nov-30 2:16 pm
said by unibroker:# ls -l cm-10-20121129-UNOFFICIAL-encore.zip ----rwxr-x system sdcard_rw 157698499 2012-11-28 20:22 cm-10-20121129-UNOFFICIAL-encore.zip
Looks like I have no permissions and Group has them all! Even everyone else has more than me.
I think when you connect over adb you are automatically part of the sdcard_rw group. If you are looking to flash to this cm rom, your custom bootloader should be able to do it. |
|
unibroker Premium Member join:2010-11-12 Coeur D Alene, ID |
I think you are correct because all of my files in the sdcard are listed the same way. I knew it was user error based on my history with everything having to do with tech. You kind sir are a gentleman and a scholar. Very much appreciated! |
|
unibroker |
to Maxo
After our discussion I tried to flash what I had pushed. It failed. I restored my prior ROM and noticed in Root Explorer that the file I had pushed which had originally said 150MB now said 0. Again, I read yesterday that this happens when not properly unmounting.
So I flashed the ROM that I had previously used and when I hooked up adb the device shows up in nautilus. I also get a notice on my device "USB Storage In Use. Before turning off USB Storage make sure that you have unmounted (ejected) your Android SD Card from your computer." Note that this ROM is Gingerbread whereas the other ROM is Jellybean. The outputs under this scenario from BASH are below (note the device is now B&N Nookcolor). In nautilus I then drag and drop my cm file from my computer to the device and select Safely Remove Drive.
lsusb Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 006 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 007 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub Bus 001 Device 003: ID 058f:6362 Alcor Micro Corp. Flash Card Reader/Writer Bus 002 Device 002: ID 03f0:110c Hewlett-Packard Bus 003 Device 002: ID 046d:c52b Logitech, Inc. Unifying Receiver Bus 001 Device 010: ID 2080:0002 Barnes & Noble NOOKcolor
adb devices List of devices attached 2010720135452002 device
$ adb shell# cd sdcard # ls -a . .. # umount /sdcard umount: can't umount /sdcard: Invalid argument
Notice that the only contents of my "sdcard" are pointers to the existing directory and the parent. When I would push the file it would end up here but could not be found on the device's sdcard. To add to the comedy I've just successfully flashed the zip file!
Apparently Gingerbread operates as mass storage and Jellybean adb when the usb cable is attached between the device and pc. I need adb to work if I'm to do the tinkering I want.
Thanks for your time. |
|
MaxoYour tax dollars at work. Premium Member join:2002-11-04 Tallahassee, FL |
Maxo
Premium Member
2012-Nov-30 4:19 pm
I'm running CM10 on my Galaxy S3 and cannot get mass storage to work. Every time I select it it goes back to MTP but still doesn't show up in Nautilus. When using the device as a mass storage device it is trivial to move files to and from the sdcard using Nautilus. I've used adb push and adb pull to move files back and forth with good success on Jellybean. |
|
unibroker Premium Member join:2010-11-12 Coeur D Alene, ID |
The file is my build so my thought is the problem is with my environment (not using an IDE). Oh well, I seem to learn more with the problems I create along the way. At least I finally found out what "foo" means. I see that in the literature and always mean to look it up. |
|