You are not logged in.
I am trying to mount my Android device (Samsung Galaxy Note 10+) and I am not able to mount it. I tried a couple different methods like mtpfs and simple-mtpfs but when I open dolphin and try to access the phone, I get the error:
The file or folder udi=/org/kde/solid/udev/sys/devices/pci0000:00/0000:00:01.2/0000:01:00.0/0000:02:08.0/0000:04:00.3/usb4/4-4 does not exist.When I attempt to mount using the command line, the command hangs for a while.
When I use KDE Plasma, the device auto-mounts and I can access its internal storage. Preferably, I want to be able to auto-mount the device when I connect the device to my computer, but for now I can settle for mounting it manually and then accessing my files. I have libmtp, mtpfs, simple-mtpfs and kio-extras (dependency of dolphin for mtp support) installed already.
Last edited by mjd119 (2020-07-15 14:06:51)
Offline
Try using gvfs-mtp and jmtpfs, its what I use with my galaxy S9
Offline
Try using gvfs-mtp and jmtpfs, its what I use with my galaxy S9
Will either of them automount the device for me? That's my main goal. I looked at the wiki and I'm unsure how to do that.
Offline
I'm using I3wm with Thunar. I plug my phone in and my phone ask to allow access and Thunar mounts it.
You may need to change access settings on your phone.
Offline
You can use https://wiki.archlinux.org/index.php/Udisks or a udev rule to automount devices.
Afaics simple-mtpfs is the only half-wise reliable MTP implementation.
Technically you don't have to unmount MTP devices, but you better do nevertheless (because not doing so is what throws many implementations off)
The error in your original post looks like it's from kio-mtp - "solid" is KDEs HW abstraction. The reason why it works in KDE but not in i3 can be either
a) your i3 session is broken (do you use a DM or xinit for either session?)
b) this relies on some KDE daemon that doesn't start
Offline
You can use https://wiki.archlinux.org/index.php/Udisks or a udev rule to automount devices.
Afaics simple-mtpfs is the only half-wise reliable MTP implementation.
Technically you don't have to unmount MTP devices, but you better do nevertheless (because not doing so is what throws many implementations off)The error in your original post looks like it's from kio-mtp - "solid" is KDEs HW abstraction. The reason why it works in KDE but not in i3 can be either
a) your i3 session is broken (do you use a DM or xinit for either session?)
b) this relies on some KDE daemon that doesn't start
I use xinit to start. I could try with a display manager. I installed thunar recently so I think I'll try that.
Offline
Please post your xinitrc
Offline
Please post your xinitrc
# Added by mjd119 (Arch Wiki)
[[ -f ~/.Xresources ]] && xrdb -merge -I$HOME ~/.Xresources
# Start i3 if we call startx instead of using display manager
# Consistent file dialog (Arch Wiki)
# Make sure this is before the 'exec' command or it won't be sourced. [added by mjd119](from Arch Wiki)
[ -f /etc/xprofile ] && . /etc/xprofile
[ -f ~/.xprofile ] && . ~/.xprofile
# Added by mjd119 to set desktop background on startup for betterlockscreen (betterlockscreen)
# set desktop background with custom effect
#betterlockscreen -w dim
# Alternative (set last used background) (fixed for laptop)
#source ~/.fehbg
exec i3and my .xprofile is:
#!/bin/sh
# Added by mjd119 to configure qt,gtk, etc. for i3 (SDDM sources .xprofile, not .xinitrc)
if [ "$XDG_DESKTOP_SESSION" != KDE ]
then export QT_QPA_PLATFORMTHEME=qt5ct
fi
# Consistent file dialog (Arch Wiki)
export GTK_USE_PORTAL=1
# Proper scaling for QT apps (Arch Wiki)
#export QT_SCREEN_SCALE_FACTORS=1.75
# Export path for doom-emacs (mjd119)
export PATH=$PATH:~/.emacs.d/bin
#export GDK_SCALE=2
#export GDK_DPI_SCALE=0.5
export QT_AUTO_SCREEN_SCALE_FACTOR=0Also, I tried thunar and it doesn't show the device in the sidebar. On dolphin, it does.
Offline
Last link in my signature… ;-)
Edit: thunar will require gvfs-mtp
Last edited by seth (2020-07-14 19:52:47)
Offline
Last link in my signature… ;-)
Edit: thunar will require gvfs-mtp
Installing gvfs-mtp and accessing the device with thunar worked. Is using dolphin to access an mtp device without the KDE desktop environment possible? Is dolphin reliant on a specific implementation? I could switch to thunar when I run i3 but I do like dolphin.
Offline
Did you fix your xinitrc?
Offline
Did you fix your xinitrc?
I don't really see what's wrong with it for my use case.
Offline
Note: At the very least, ensure that the last if block in /etc/X11/xinit/xinitrc is present in your ~/.xinitrc file to ensure that the scripts in /etc/X11/xinit/xinitrc.d are sourced.
This esp. imports some important variables into the session environment - your session is "broken" and esp. not active and you might lack access to the session dbus.
Offline
Wiki wrote:Note: At the very least, ensure that the last if block in /etc/X11/xinit/xinitrc is present in your ~/.xinitrc file to ensure that the scripts in /etc/X11/xinit/xinitrc.d are sourced.
This esp. imports some important variables into the session environment - your session is "broken" and esp. not active and you might lack access to the session dbus.
My .xinitrc is now:
#!/bin/sh
# Added by mjd119 (Arch Wiki)
[[ -f ~/.Xresources ]] && xrdb -merge -I$HOME ~/.Xresources
# Start i3 if we call startx instead of using display manager
# Consistent file dialog (Arch Wiki)
# Make sure this is before the 'exec' command or it won't be sourced. [added by mjd119](from Arch Wiki)
[ -f /etc/xprofile ] && . /etc/xprofile
[ -f ~/.xprofile ] && . ~/.xprofile
# Added by mjd119 to set desktop background on startup for betterlockscreen (betterlockscreen)
# set desktop background with custom effect
#betterlockscreen -w dim
# Alternative (set last used background)
#source ~/.fehbg
# If statement from /etc/X11/xinit/xinitrc to give access to session dbus (mjd119)
# start some nice programs
if [ -d /etc/X11/xinit/xinitrc.d ] ; then
for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
[ -x "$f" ] && . "$f"
done
unset f
fi
exec i3
# Uncomment lines below to start KDE Plasma
#export DESKTOP_SESSION=plamsa
#exec startplasma-x11I am not sure what benefit this gives me. I looked up dbus and dbus session but didn't understand its exact purpose. Now I can access my mtp device in dolphin but not thunar. In thunar, the device icon and text is shaded. Nothing happens when I click it. When I right click it and then click the "Mount" option, I get the the error
Failed to mount "SAMSUNG Android".
Unable to open MTP device "004,018"Shouldn't I be able to access the device in both file managers? What's different now from when I first made the forum post is that I get a popup message on my phone asking to "Allow access to your data" which is what happens when I'm on a standard desktop environment like KDE.
Offline
You now have a valid session, known session bus and active user (altering polkit rules + likely socket activated polkit agent)
Ideally you want to move that block even above your xrdb call, ahead of everything.
The thunar error is from gvfs-mtp and likely libmtp - check your system journal on what's going on with such attempts - a typical cause is a failing subsequent mount attempt (eg. you mounted the device w/ dolphin first and then tried thunar w/o a reboot…)
Again: simple-mtpfs which simply ignores most of MTPs "extended" ways to fail… err: "features" is the only implementation I found to be able to reliably mount, unmount and remount all of my mtp devices.
Offline
You now have a valid session, known session bus and active user (altering polkit rules + likely socket activated polkit agent)
Ideally you want to move that block even above your xrdb call, ahead of everything.The thunar error is from gvfs-mtp and likely libmtp - check your system journal on what's going on with such attempts - a typical cause is a failing subsequent mount attempt (eg. you mounted the device w/ dolphin first and then tried thunar w/o a reboot…)
Again: simple-mtpfs which simply ignores most of MTPs "extended" ways to fail… err: "features" is the only implementation I found to be able to reliably mount, unmount and remount all of my mtp devices.
I see what you mean. I rebooted and opened Thunar. I was able to mount and access the device without any issues, but when I open dolphin, I get that "file or folder... does not exist" error I mentioned before. Calling journalctl -f gives me:
Jul 15 09:43:13 Arch dbus-daemon[617]: [session uid=1000 pid=617] Activating service name='org.kde.kiod5' requested by ':1.208' (uid=1000 pid=25680 comm="mtp.so [kdeinit5] mtp local:/run/user/1000/klaunch")
Jul 15 09:43:13 Arch dbus-daemon[617]: [session uid=1000 pid=617] Successfully activated service 'org.kde.kiod5'
Jul 15 09:43:13 Arch kiod5[25683]: kf5.kiod: Couldn't register name "kmtpd" with DBUS - another process owns it already!
Jul 15 09:43:13 Arch kiod5[25683]: kf5.kiod: loadModule "kmtpd"
Jul 15 09:43:13 Arch kiod5[25683]: kf5.kiod.kmtpd: new device, getting raw devices
Jul 15 09:43:13 Arch kiod5[25683]: kf5.kiod.kmtpd: No Error, continuing
Jul 15 09:43:13 Arch kiod5[25683]: kf5.kiod.kmtpd: Found device matching the Solid description
Jul 15 09:43:13 Arch org.kde.kiod5[25683]: error returned by libusb_claim_interface() = -6LIBMTP PANIC: Unable to initialize device
Jul 15 09:43:13 Arch kiod5[25683]: kf5.kiod.kmtpd: LIBMTP_Open_Raw_Device_Uncached: Could not open MTP deviceShould I just uninstall gvfs-mtp? I already have libmtp, mtpfs, and simple-mtpfs. Also I'm glad you told me to fix the .xinitrc. My bluetooth manager works now when before I tried to launch it and nothing came up.
EDIT:
When I disconnect my device, close out the file managers, and start up dolphin instead of thunar, I can access the device in dolphin but not thunar. So it appears I can only use one file manager at a time. The journalctl -f from this is:
Jul 15 09:56:11 Arch kiod5[25683]: kf5.kiod.kmtpd: New device attached with udi= "/org/kde/solid/udev/sys/devices/pci0000:00/0000:00:14.0/usb2/2-2" . Checking if PortableMediaPlayer...
Jul 15 09:56:11 Arch kiod5[25683]: kf5.kiod.kmtpd: SOLID: New Device with udi= "/org/kde/solid/udev/sys/devices/pci0000:00/0000:00:14.0/usb2/2-2"
Jul 15 09:56:11 Arch kiod5[25683]: kf5.kiod.kmtpd: new device, getting raw devices
Jul 15 09:56:11 Arch kiod5[25683]: kf5.kiod.kmtpd: No Error, continuing
Jul 15 09:56:11 Arch kiod5[25683]: kf5.kiod.kmtpd: Found device matching the Solid description
Jul 15 09:56:12 Arch kiod5[25683]: kf5.kiod.kmtpd: Created device "Galaxy Note10+" with udi= "/org/kde/solid/udev/sys/devices/pci0000:00/0000:00:14.0/usb2/2-2" and timeout 96
Jul 15 09:56:35 Arch gvfsd[28849]: error returned by libusb_claim_interface() = -6LIBMTP PANIC: Unable to initialize device
Jul 15 09:56:36 Arch gvfsd[28857]: error returned by libusb_claim_interface() = -6LIBMTP PANIC: Unable to initialize device
Jul 15 09:56:36 Arch gvfsd[28849]: Device 0 (VID=04e8 and PID=6860) is a Samsung Galaxy models (MTP).
Jul 15 09:56:37 Arch gvfsd[28857]: Device 0 (VID=04e8 and PID=6860) is a Samsung Galaxy models (MTP).Last edited by mjd119 (2020-07-15 13:58:43)
Offline
Removing gfvs-mtp will prevent thunar from mounting MTP devices. This does not necessarily mean that dolphin/kio will work more reliably.
Personally, I mount them w/ simple-mtpfs (and a more simpler dmenu script) and then access the mounted path as a "normal" directory; you could use udisks/udev to automount them instead.
I'm not aware of a way to make dolphin/thunar somehow use simple-mtpfs as backend.
Offline
Removing gfvs-mtp will prevent thunar from mounting MTP devices. This does not necessarily mean that dolphin/kio will work more reliably.
Personally, I mount them w/ simple-mtpfs (and a more simpler dmenu script) and then access the mounted path as a "normal" directory; you could use udisks/udev to automount them instead.I'm not aware of a way to make dolphin/thunar somehow use simple-mtpfs as backend.
Ok. Thank you. I'll look into udev rules and udiskie for MTP devices. Marking this issue as solved.
Offline