1

I'm a new (still new) linux user (Fedora, LXDE).

The phone I currently use is Samsung Avila, or Samsung Star (Samsung GT-S5230, http://www.samsung.com/pl/consumer/mobile-devices/other-phones/others/GT-S5230LKAPLS/, http://www.phonemore.com/samsung-star-gt-s5230/specs/503).

But it seems not to automounts, or I don't know where to look for it in the filesystem.

Is there a way to access the files on it (just photos), when connected by USB cable?

I was thinking about mount, but had some problems with e.g. finding the name of the device. Also, I would be glad if there is an application.


UPDATE 1:

My lsblk output:

NAME                                    MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT  
sda                                       8:0    0 55,9G  0 disk  
├─sda4                                    8:4    0    1K  0 part  
├─sda2                                    8:2    0 41,6G  0 part  
├─sda5                                    8:5    0  3,5G  0 part  
├─sda3                                    8:3    0    1G  0 part /boot  
├─sda1                                    8:1    0  100M  0 part  
└─sda6                                    8:6    0  9,3G  0 part  
  ├─fedora-swap                         253:1    0    1G  0 lvm  [SWAP]  
  ├─fedora-home                         253:4    0  768M  0 lvm  /home  
  ├─fedora-usr                          253:2    0    4G  0 lvm  /usr  
  ├─fedora-root                         253:0    0    1G  0 lvm  /  
  ├─fedora-home_michal_Dokumenty_Dyplom 253:5    0  512M  0 lvm /home/michal/Dokumenty/Dyplom  
  └─fedora-var                          253:3    0    2G  0 lvm  /var  

UPDATE 2:

The modes that my phone can use to connect to computer:
1) Media player mode;
2) PC studio mode;
3) Mass storage mode.


UPDATE 3:

simple-mtpfs outputs:

Firstly, I've checked whether ~/mnt exists.

Secondly, I've checked simple-mtpfs -l output: 1: SamsungGT-S5230.

The additional files that appeared in /dev after connecting the phone:
1) Media player mode: libmtp-1-1;
2) PC studio mode: ttyACM3;
3) Mass storage mode: --- (no additional files).

My outputs for simple-mtpfs /dev/[file name] ~/mnt:
1) Media player mode:
1.1) Running the command once: ERROR: Could not close session!,
1.2) Running the command twice and so on: LIBMTP PANIC: Trying to dump the error stack of a NULL device!;
2) PC studio mode: --- (no output appeared);
3) Mass storage mode: ---.

The same outputs appear for simple-mtpfs --device 1 ~/mnt.


UPDATE 4:

jmtpfs outputs:

My outputs for jmtpfs ~/mnt:
1) Media player mode:

Device 0 (VID=0438 and PID=e20c) is a Samsung GT-S5230.
PTP_ERROR_IO: failed to open session, trying again after resetting USB interface
LIBMTP libusb: Attemp to reset device
LIBMTP PANIC: failed to open session on second attempt
terminate called after throwing an instance of ‘MtpErrorCantOpenDevice’
  what(): Can’t open device
Przerwane (zrzut pamięci) [english literally: interrupted (memory dump)]

2) PC studio mode: No mtp devices found.;
3) Mass storage mode: No mtp devices found..


UPDATE 5:

  • When I run simple-mtpfs as root in Media player mode, it shows the same results if running as user (that is, as above).

  • jmtpfs -l shows the following output:

Device 0 (VID=0438 and PID=e20c) is a Samsung GT-S5230.  
Available devices (busLocation, devNum, productId, vendorId, product, vendor):  
1, 10, 0xe20c, 0x04e8, GT-S5230, Samsung
  • When I run jmtpfs for the mnt directory in my home directory (Media player mode), it shows only Device 0 (VID=0438 and PID=e20c) is a Samsung GT-S5230. output and there appears an mnt volume (?) on the left side of my file manager window (PCManFM), as illustrated below:
    mnt in file manager window
    But when I want to access, it displays (possible english version): Error - The specified directory is not valid. After clicking OK, it's empty.

What's interesting:
- when I cd ~/mnt, it displays (my free translation from Polish) No access;
- when I ls -ld ~/mnt, it displays No access to mnt;
- when I ls -l ~, it displays No access to mnt and the mnt row looks like that: d?????????? ? ? ? ? mnt.


UPDATE 6:

I've tried android-tools (it uses ADB), as @Stolous suggested in his answer. My adb devices output (in all the three modes):

List of devices attached
* daemon not running. starting it now on port 5037 *
* daemon started successfully *

and then, after adb devices again, the output is just: List of devices attached and an empty line.

16
  • 1
    Add the output of lsblk to your question please. Commented Aug 10, 2017 at 16:29
  • 1
    Some Samsung devices only allow file access through a protocol, MTP, and do not offer the usual "Mass Storage Device" interface. If this is the case, you may need to install additional software to support MTP.
    – njsg
    Commented Aug 10, 2017 at 17:22
  • 1
    Also: not all MTP tools support all MTP phones. ArchLinux wiki has a list of MTP tools, you will have to see which one works better with your phone.
    – njsg
    Commented Aug 10, 2017 at 17:27
  • 1
    From your output, I guess "media player mode" is MTP. Here, the name libmtp-... is created by a udev rule installed by libmtp. Just to make sure, can you check the permissions on the libmtp-... file under /dev/? If it is assigned to a group with rw permissions, is your user in that group? (You can use e.g. the groups command to check your current groups.)
    – njsg
    Commented Aug 11, 2017 at 14:36
  • 1
    That said about MTP, if "Mass storage mode" is the regular "pendrive" interface, you probably want to try to get that one working first. If it does not create any new device file, can you check which lines show up in the kernel log (dmesg) when you plug the phone in its "mass storage mode"? There should be some USB-related messages identifying the device and then, hopefully, some more information about the "storage device".
    – njsg
    Commented Aug 11, 2017 at 14:39

2 Answers 2

2

What you need is MTP (Media Transfert Protocol) support.

You can install a tool called simple-mtpfs to mount your device storage.

dnf install simple-mtpfs

Then you will be able to mount it like this:

simple-mtpfs /dev/device /media/yourphone
3
  • Thanks, @Stolous, but it seems not to work. I've updated my question.
    – Silv
    Commented Aug 11, 2017 at 13:28
  • Try to create /etc/udev/rules.d/10-GT-S5230.rules containing SUBSYSTEM=="usb", ATTR{idVendor}=="X", ATTR{idProduct}="Y", SYMLINK="GT-S5230" (where X and Y are found with dmesg for example: dmesg | tail -n30 just after you plugged in your phone. Then reload udev rules configuration: sudo udevadm control --reload-rules
    – Stolous
    Commented Aug 11, 2017 at 16:28
  • It seems not to work. I've created the file with the correct vendor and product IDs, but the output of simple-mtpfs is the same (I've checked only Media player mode).
    – Silv
    Commented Aug 13, 2017 at 13:46
1

Another totaly different solution (Using ADB)

If you are in a hurry then this may be faster than configuring MTP (This may however be less practical if you plan on using this system very often).

  1. Install Android SDK tools: yum install android-tools (or download it here)
  2. Enable ADB on your phone (Setting/Developpers Options/Android Debug Bridge, USB Debugging, or something similar) and connect it via USB.

    Enabling USB Debugging

  3. Run adb devices. You should see your device here (You may also have to accept the connection on your phone).


If you don't then you can also connect via TCP/IP if your phone support it (you have to configure it in the developpers options on your phone) using adb connect IP.


  1. You can now run adb pull /sdcard/myfile ~/myandroidfiles/myfile in order to get your file(s) and adb push ~/myotherfile /sdcard/myotherfile to transfer a file from your computer to your phone.
3
  • Thanks, @Stolous, but I haven't seen any "ADB option" in my phone (maybe it's enabled by default and not made available to user?). When it comes to android-tools, I've updated my question (UPDATE 6).
    – Silv
    Commented Aug 13, 2017 at 12:53
  • Is it USB Debugging maybe ? I've updated my answer. It's normal if you can't see your phone using ADB on your computer because you didn't activate this option on your phone.
    – Stolous
    Commented Aug 13, 2017 at 14:13
  • My phone model is rather an old one, first presented on 2009 (Samsung Avila, or Samsung Star, samsung.com/pl/consumer/mobile-devices/other-phones/others/…). It hasn't such advanced options. I suppose it's operating system is Android-based, not "Android" itself (the best I could find, "proprietary", phonemore.com/samsung-star-gt-s5230/specs/503).
    – Silv
    Commented Aug 13, 2017 at 15:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .