mYn*_*EAm 9 usb debian file-copy android mtp
所以我正在尝试使用 MTP 而不是 KDE Connect 在带有 Android 的三星 Galaxy S5 和我的 Debian9/KDE 机器之间共享文件。
问题是我不断收到:
mtp 协议的进程意外终止。
尝试复制文件时。
也常说
未找到存储。也许您需要解锁您的设备?
尝试一段时间后,我可以在 dolphin 中查看手机的一些内容:当手机上的对话框要求它时按“允许”,同时尝试在 dolphin 中打开它,它正确地将其检测为三星 Galaxy S5。
我曾经可以成功复制一堆图像。
我已经试过了sudo apt-get install --reinstall libmtp-common
。syslog 有如下内容:
usb 1-5: usbfs: process 7907 (mtp.so) did not claim interface 0 before use
usb 1-5: reset high-speed USB device number 35 using xhci_hcd
usb 1-5: usbfs: process 7909 (mtp.so) did not claim interface 0 before use
colord-sane: io/hpmud/pp.c 627: unable to read device-id ret=-1
usb 1-5: USB disconnect, device number 35
usb 1-5: new high-speed USB device number 36 using xhci_hcd
usb 1-5: usbfs: process 7930 (mtp.so) did not claim interface 0 before use
usb 1-5: usbfs: process 7930 (mtp.so) did not claim interface 0 before use
usb 1-5: usbfs: process 7930 (mtp.so) did not claim interface 0 before use
Run Code Online (Sandbox Code Playgroud)
安装jmtpfs
包
apt install jmtpfs
Run Code Online (Sandbox Code Playgroud)
编辑你/etc/fuse.conf
的如下
# Allow non-root users to specify the allow_other or allow_root mount options.
user_allow_other
Run Code Online (Sandbox Code Playgroud)
创建 udev 规则。使用lsusb
或mtp-detect
获取您设备的 ID
nano /etc/udev/rules.d/51-android.rules
Run Code Online (Sandbox Code Playgroud)
与以下行:
SUBSYSTEM=="usb", ATTR{idVendor}=="04e8", ATTR{idProduct}=="6860", MODE="0666", OWNER="[username]"
Run Code Online (Sandbox Code Playgroud)
将04e8
and替换6860
为你的,然后运行:
udevadm control --reload
Run Code Online (Sandbox Code Playgroud)
重新连接您的设备,打开终端并运行:
mkdir ~/mtp
jmtpfs ~/mtp
ls ~/mtp
Run Code Online (Sandbox Code Playgroud)
示例输出:
Card Phone
Run Code Online (Sandbox Code Playgroud)
要卸载您的设备,请使用以下命令:
fusermount -u ~/mtp
Run Code Online (Sandbox Code Playgroud)
您也可以使用该go-mtpfs
工具:
通过 FUSE 挂载 MTP 设备
mkdir ~/mtp
go-mtpfs ~/mtp
Run Code Online (Sandbox Code Playgroud)
用于挂载设备的图形工具gmtp
::
用于基于 MTP 的设备的简单文件传输程序
sudo apt install gmtp
gmtp
Run Code Online (Sandbox Code Playgroud)
使用 KDE 平台为应用程序访问 MTP 设备
归档时间: |
|
查看次数: |
9076 次 |
最近记录: |