How to make Android MTP in CentOS7 available for all users?
Clash Royale CLAN TAG#URR8PPP
up vote
4
down vote
favorite
I'm using Moto G4 play with Marshmallow; and CentOS 7. I'm able to mount the device and see the content as root, by using jmtpfs
. First time I used sudo
then I switched as root and then mounted, works fine on both occasions; but files are only visible for root user. personal user is not able to access the content
[shiva@jayan ~]$ sudo su -
[sudo] password for shiva:
Last login: Wed Dec 6 23:51:54 IST 2017 on pts/0
[root@jayan ~]# jmtpfs /media/phone/
Device 0 (VID=22b8 and PID=2e82) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Android device detected, assigning default bug flags
[root@jayan ~]# ll /media/phone/
total 0
drwxr-xr-x. 38 root root 0 Dec 3 4453203 Internal storage
But when I try to view it as my user, I get permission denied, as a dumb attempt I even tried to change user after mounting.
[shiva@jayan /]$ ll /media/phone
ls: cannot access /media/phone: Permission denied
[shiva@jayan /]$ cd media/
[shiva@jayan media]$ ll
ls: cannot access phone: Permission denied
total 0
d????????? ? ? ? ? ? phone
[shiva@jayan media]$ sudo chown shiva:shiva phone
[sudo] password for shiva:
chown: changing ownership of âÂÂphoneâÂÂ: Function not implemented
Then I tried to mount from my user, it detected no mtp :(
[root@jayan ~]# fusermount -u /media/phone
[root@jayan ~]# exit
logout
[shiva@jayan ~]$ jmtpfs /media/phone/
No mtp devices found.
Now my question is how to resolve this?
How to make mtp devices available for my user (or)
How to access files after mounting it as root! I tried using sudo chmod -R 775
, it ran forever :'( yet was not able to access those files
centos android mtp
add a comment |Â
up vote
4
down vote
favorite
I'm using Moto G4 play with Marshmallow; and CentOS 7. I'm able to mount the device and see the content as root, by using jmtpfs
. First time I used sudo
then I switched as root and then mounted, works fine on both occasions; but files are only visible for root user. personal user is not able to access the content
[shiva@jayan ~]$ sudo su -
[sudo] password for shiva:
Last login: Wed Dec 6 23:51:54 IST 2017 on pts/0
[root@jayan ~]# jmtpfs /media/phone/
Device 0 (VID=22b8 and PID=2e82) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Android device detected, assigning default bug flags
[root@jayan ~]# ll /media/phone/
total 0
drwxr-xr-x. 38 root root 0 Dec 3 4453203 Internal storage
But when I try to view it as my user, I get permission denied, as a dumb attempt I even tried to change user after mounting.
[shiva@jayan /]$ ll /media/phone
ls: cannot access /media/phone: Permission denied
[shiva@jayan /]$ cd media/
[shiva@jayan media]$ ll
ls: cannot access phone: Permission denied
total 0
d????????? ? ? ? ? ? phone
[shiva@jayan media]$ sudo chown shiva:shiva phone
[sudo] password for shiva:
chown: changing ownership of âÂÂphoneâÂÂ: Function not implemented
Then I tried to mount from my user, it detected no mtp :(
[root@jayan ~]# fusermount -u /media/phone
[root@jayan ~]# exit
logout
[shiva@jayan ~]$ jmtpfs /media/phone/
No mtp devices found.
Now my question is how to resolve this?
How to make mtp devices available for my user (or)
How to access files after mounting it as root! I tried using sudo chmod -R 775
, it ran forever :'( yet was not able to access those files
centos android mtp
First what group owns that mount when it's mounted? Then you need to realize that there is audev rule
that determine what happens to that mount, so overriding that might do the trick!
â George Udosen
Dec 19 '17 at 5:15
Please run thiscat /etc/group | grep uucp
, if that group exists add yourself to it! And see here: wiki.archlinux.org/index.php/MTP
â George Udosen
Dec 19 '17 at 5:22
1
Your question told me thatjmtpfs
exists, and it turned out it works out just fine with my Android phone - thanks!
â telcoM
Dec 21 '17 at 13:32
@GeorgeUdosen nope there is no such group, thanks for the input; might help someone with such case :)
â Shiva
Dec 21 '17 at 17:54
add a comment |Â
up vote
4
down vote
favorite
up vote
4
down vote
favorite
I'm using Moto G4 play with Marshmallow; and CentOS 7. I'm able to mount the device and see the content as root, by using jmtpfs
. First time I used sudo
then I switched as root and then mounted, works fine on both occasions; but files are only visible for root user. personal user is not able to access the content
[shiva@jayan ~]$ sudo su -
[sudo] password for shiva:
Last login: Wed Dec 6 23:51:54 IST 2017 on pts/0
[root@jayan ~]# jmtpfs /media/phone/
Device 0 (VID=22b8 and PID=2e82) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Android device detected, assigning default bug flags
[root@jayan ~]# ll /media/phone/
total 0
drwxr-xr-x. 38 root root 0 Dec 3 4453203 Internal storage
But when I try to view it as my user, I get permission denied, as a dumb attempt I even tried to change user after mounting.
[shiva@jayan /]$ ll /media/phone
ls: cannot access /media/phone: Permission denied
[shiva@jayan /]$ cd media/
[shiva@jayan media]$ ll
ls: cannot access phone: Permission denied
total 0
d????????? ? ? ? ? ? phone
[shiva@jayan media]$ sudo chown shiva:shiva phone
[sudo] password for shiva:
chown: changing ownership of âÂÂphoneâÂÂ: Function not implemented
Then I tried to mount from my user, it detected no mtp :(
[root@jayan ~]# fusermount -u /media/phone
[root@jayan ~]# exit
logout
[shiva@jayan ~]$ jmtpfs /media/phone/
No mtp devices found.
Now my question is how to resolve this?
How to make mtp devices available for my user (or)
How to access files after mounting it as root! I tried using sudo chmod -R 775
, it ran forever :'( yet was not able to access those files
centos android mtp
I'm using Moto G4 play with Marshmallow; and CentOS 7. I'm able to mount the device and see the content as root, by using jmtpfs
. First time I used sudo
then I switched as root and then mounted, works fine on both occasions; but files are only visible for root user. personal user is not able to access the content
[shiva@jayan ~]$ sudo su -
[sudo] password for shiva:
Last login: Wed Dec 6 23:51:54 IST 2017 on pts/0
[root@jayan ~]# jmtpfs /media/phone/
Device 0 (VID=22b8 and PID=2e82) is UNKNOWN.
Please report this VID/PID and the device model to the libmtp development team
Android device detected, assigning default bug flags
[root@jayan ~]# ll /media/phone/
total 0
drwxr-xr-x. 38 root root 0 Dec 3 4453203 Internal storage
But when I try to view it as my user, I get permission denied, as a dumb attempt I even tried to change user after mounting.
[shiva@jayan /]$ ll /media/phone
ls: cannot access /media/phone: Permission denied
[shiva@jayan /]$ cd media/
[shiva@jayan media]$ ll
ls: cannot access phone: Permission denied
total 0
d????????? ? ? ? ? ? phone
[shiva@jayan media]$ sudo chown shiva:shiva phone
[sudo] password for shiva:
chown: changing ownership of âÂÂphoneâÂÂ: Function not implemented
Then I tried to mount from my user, it detected no mtp :(
[root@jayan ~]# fusermount -u /media/phone
[root@jayan ~]# exit
logout
[shiva@jayan ~]$ jmtpfs /media/phone/
No mtp devices found.
Now my question is how to resolve this?
How to make mtp devices available for my user (or)
How to access files after mounting it as root! I tried using sudo chmod -R 775
, it ran forever :'( yet was not able to access those files
centos android mtp
edited Dec 21 '17 at 18:04
GAD3R
22.6k154894
22.6k154894
asked Dec 6 '17 at 19:41
Shiva
737
737
First what group owns that mount when it's mounted? Then you need to realize that there is audev rule
that determine what happens to that mount, so overriding that might do the trick!
â George Udosen
Dec 19 '17 at 5:15
Please run thiscat /etc/group | grep uucp
, if that group exists add yourself to it! And see here: wiki.archlinux.org/index.php/MTP
â George Udosen
Dec 19 '17 at 5:22
1
Your question told me thatjmtpfs
exists, and it turned out it works out just fine with my Android phone - thanks!
â telcoM
Dec 21 '17 at 13:32
@GeorgeUdosen nope there is no such group, thanks for the input; might help someone with such case :)
â Shiva
Dec 21 '17 at 17:54
add a comment |Â
First what group owns that mount when it's mounted? Then you need to realize that there is audev rule
that determine what happens to that mount, so overriding that might do the trick!
â George Udosen
Dec 19 '17 at 5:15
Please run thiscat /etc/group | grep uucp
, if that group exists add yourself to it! And see here: wiki.archlinux.org/index.php/MTP
â George Udosen
Dec 19 '17 at 5:22
1
Your question told me thatjmtpfs
exists, and it turned out it works out just fine with my Android phone - thanks!
â telcoM
Dec 21 '17 at 13:32
@GeorgeUdosen nope there is no such group, thanks for the input; might help someone with such case :)
â Shiva
Dec 21 '17 at 17:54
First what group owns that mount when it's mounted? Then you need to realize that there is a
udev rule
that determine what happens to that mount, so overriding that might do the trick!â George Udosen
Dec 19 '17 at 5:15
First what group owns that mount when it's mounted? Then you need to realize that there is a
udev rule
that determine what happens to that mount, so overriding that might do the trick!â George Udosen
Dec 19 '17 at 5:15
Please run this
cat /etc/group | grep uucp
, if that group exists add yourself to it! And see here: wiki.archlinux.org/index.php/MTPâ George Udosen
Dec 19 '17 at 5:22
Please run this
cat /etc/group | grep uucp
, if that group exists add yourself to it! And see here: wiki.archlinux.org/index.php/MTPâ George Udosen
Dec 19 '17 at 5:22
1
1
Your question told me that
jmtpfs
exists, and it turned out it works out just fine with my Android phone - thanks!â telcoM
Dec 21 '17 at 13:32
Your question told me that
jmtpfs
exists, and it turned out it works out just fine with my Android phone - thanks!â telcoM
Dec 21 '17 at 13:32
@GeorgeUdosen nope there is no such group, thanks for the input; might help someone with such case :)
â Shiva
Dec 21 '17 at 17:54
@GeorgeUdosen nope there is no such group, thanks for the input; might help someone with such case :)
â Shiva
Dec 21 '17 at 17:54
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
2
down vote
accepted
Un-comment the user_allow_other
on your /etc/fuse.conf
file.
Mount your android device with allow_other
option on your home directory without sudo
:
$ mkdir phone
$ jmtpfs -o allow_other phone/
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
1
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
2
down vote
accepted
Un-comment the user_allow_other
on your /etc/fuse.conf
file.
Mount your android device with allow_other
option on your home directory without sudo
:
$ mkdir phone
$ jmtpfs -o allow_other phone/
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
1
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
add a comment |Â
up vote
2
down vote
accepted
Un-comment the user_allow_other
on your /etc/fuse.conf
file.
Mount your android device with allow_other
option on your home directory without sudo
:
$ mkdir phone
$ jmtpfs -o allow_other phone/
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
1
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
add a comment |Â
up vote
2
down vote
accepted
up vote
2
down vote
accepted
Un-comment the user_allow_other
on your /etc/fuse.conf
file.
Mount your android device with allow_other
option on your home directory without sudo
:
$ mkdir phone
$ jmtpfs -o allow_other phone/
Un-comment the user_allow_other
on your /etc/fuse.conf
file.
Mount your android device with allow_other
option on your home directory without sudo
:
$ mkdir phone
$ jmtpfs -o allow_other phone/
answered Dec 19 '17 at 11:46
GAD3R
22.6k154894
22.6k154894
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
1
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
add a comment |Â
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
1
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
Thanks for the answer, not in a position to check and certify the answer. But I felt compelled to thank, and so here it is :) give me 6 hours
â Shiva
Dec 21 '17 at 11:56
1
1
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
Thanks!! Works like magic. Didn't do any hard core file transfer testing - sort of one mkdir, delete tmp file and open a video. Hope that covered all normal file operations ;)
â Shiva
Dec 21 '17 at 17:58
add a comment |Â
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f409288%2fhow-to-make-android-mtp-in-centos7-available-for-all-users%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
First what group owns that mount when it's mounted? Then you need to realize that there is a
udev rule
that determine what happens to that mount, so overriding that might do the trick!â George Udosen
Dec 19 '17 at 5:15
Please run this
cat /etc/group | grep uucp
, if that group exists add yourself to it! And see here: wiki.archlinux.org/index.php/MTPâ George Udosen
Dec 19 '17 at 5:22
1
Your question told me that
jmtpfs
exists, and it turned out it works out just fine with my Android phone - thanks!â telcoM
Dec 21 '17 at 13:32
@GeorgeUdosen nope there is no such group, thanks for the input; might help someone with such case :)
â Shiva
Dec 21 '17 at 17:54