can't get file transfer working. Help, please!
#1
This feels very dumb, but I just can't get it.
  • connected via USB cable. Supposedly just shows up in Dolphin. In my case, No. Not under Network Places, not anywhere that I can see.
  • I really really really don't want to go the whole ssh route. For me, that's a huge bother just to transfer a file or two every couple of weeks.
  • bluetooth: seems to work ok on the pinephone, but I just can't get it to work on the desktop. So apparently that's out. Seems to be a hardware issue? (Generally, I never use bluetooth.)
  • smb: I guess it should work, but I don't see how or where. I've never used it so I have no clue where to start.
  • ftp: keeps asking me for hostnames. I don't know. Mobian? 10.60.0.10:21 (for ordinary ftp). I downloaded filezilla on the desktop in the hope that would help, but it doesn't seem to see either the usb-attached local device or tell me what the hell it wants for host name etc.
It's been so long since I've had to fight with this sort of thing, I don't remember, at all, any possible solutions.

What I'd *really* like is for the pinephone filesystem to show up in Dolphin when the usb cable is attached, without any fuss or muss.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
OS: Mobian Bookworm, Phosh. Pinephone Braveheart from 2020-02-11
  Reply
#2
The file transfer via USB cable is currently disabled, I think. It did work in Mobian early on but files copied to the Pinephone wound up owned by root and were not accessible to the "mobian" user unless ownership or file access bits were changed.

What I'm currently doing for file transfer is using sshfs on the PC and ssh server on the Pinephone, so to mount the phone's home directory on your PC:

Code:
sshfs mobian@pinephone-ip-address:/home/mobian /local/mount/point  #sudo not needed if you have read/write access to mount point

You can then use the command shell or file manager to copy files back and forth. When done, unmount sshfs:

Code:
fusermount -u /local/mount/point

A limitation of sshfs is that it does not support symbolic links.
  Reply
#3
I just as confused as quixote here with the file transfer...

I've tried the BT way : transfer frome the pinphone to the desktop works the desktop to phone systematically fails. Also the transfer rate would note go above 3kb/s, but anyway...

USB connection does not make the phone appear anywhere.

Other options : I'm willing to try, but I'm too much of a noob to get anything done because there's always a step I get wrong.

Typically, I've tried the option from Zebulon here above (thx btw), but I get the following :
fuse: bad mount point `/local/mount/point': No such file or directory

And now I have no idea what to do!

Just getting ifconfig working on my phone to find its ip took me the whole evening Smile

I guess that's the price to pay to move away from iOS and Windows... Hopefully the community will not let me down here Wink 

File transfer would be part of the features I would really need before considering moving to the pinephone as a daily.
I could always transfer files through SD cards, but hey. We're talking Linux here, there's gotta be a better way!
  Reply
#4
Koikilensoi Wrote:Typically, I've tried the option from Zebulon here above (thx btw), but I get the following :
fuse: bad mount point `/local/mount/point': No such file or directory

On the sshfs command, "/local/mount/point" is not meant to be taken literally if that's what you're doing, it means use or create a suitable mount point that you have read/write access to. Below are the exact commands that I just used to mount my Pinephone's $HOME to be accessible on my Linux PC. Needless to say you need to substitute your own Pinephone's IP address. Smile

(Note that I have my ssh server set up so that it only accepts key-based logins, not passwords, and it is firewalled off from all but my home LAN's subnet. Those steps are not necessary for this to work but if you do not have those kind of security measures in place you don't want to leave ssh server running when not on your home network or connected to cellular internet.)

Code:
mkdir /tmp/mnt
sshfs mobian@192.168.1.200:/home/mobian /tmp/mnt

You will be prompted for your password unless using key-based ssh login. This will be the number used to unlock the phone's screen. Once the sshfs command completes, your home directory on the Pinephone will be in /tmp/mnt on your desktop or laptop computer, and can be accessed with your file manager or command prompt, whichever you prefer.

When done you can unmount the Pinephone from your PC.

Code:
fusermount -u /tmp/mnt

As I said, bear in mind that sshfs will not follow symbolic links. On my Pinephone the directories I'd most likely want to deal with for file transfer (Downloads, Pictures, Videos, etc.) are on an SD card with those directories symlinked from /home/mobian on the eMMC. So when I do file transfer I modify that sshfs command so it goes to the mount point of the SD card on the Pinephone. However if your entire system is on the eMMC or on an SD card, mounting your /home/mobian directory is probably what you would want.
  Reply
#5
(05-14-2021, 09:33 PM)quixote Wrote: This feels very dumb, but I just can't get it.
  • connected via USB cable. Supposedly just shows up in Dolphin. In my case, No. Not under Network Places, not anywhere that I can see.
  • I really really really don't want to go the whole ssh route. For me, that's a huge bother just to transfer a file or two every couple of weeks.
  • bluetooth: seems to work ok on the pinephone, but I just can't get it to work on the desktop. So apparently that's out. Seems to be a hardware issue? (Generally, I never use bluetooth.)
  • smb: I guess it should work, but I don't see how or where. I've never used it so I have no clue where to start.
  • ftp: keeps asking me for hostnames. I don't know. Mobian? 10.60.0.10:21 (for ordinary ftp). I downloaded filezilla on the desktop in the hope that would help, but it doesn't seem to see either the usb-attached local device or tell me what the hell it wants for host name etc.
It's been so long since I've had to fight with this sort of thing, I don't remember, at all, any possible solutions.

What I'd *really* like is for the pinephone filesystem to show up in Dolphin when the usb cable is attached, without any fuss or muss.

Ubuntu 20.04 => File Manager => Server adress "sftp://mobian@mobian"
Password: 1234



HTH
Ciao
Walter
PS: first Posting


Attached Files Thumbnail(s)
   
  Reply
#6
Progress! No real result, but progress.

Desktop to pinephone says "Permission denied" So somewhere, something about ssh is not set up to let it go. My timestamps on the config files are 2014.... No wonder I don't remember anything. I vaguely recall setting it up to be passwordless and require a key. ??

Pinephone to desktop, after I installed EasySSH, connected beautifully. Cool! Except I can't get the syntax right to copy the files I need. (scream) I'd like to get all four files in subdir "anbox"

so the terminal shows: quixote@desktop:~$

At that prompt, I tried cp ~/anbox/* mobian@10.66.0.10:/home  but maybe I typoed something because it didn't go. I'll try again. Edited to add: nope. I've tried  mobian@10.66.0.10:/home  mobian@10.66.0.10:/home/mobian  mobian@10.66.0.10:/ and it keeps saying "is not a directory."

Walter's sftp method would be good, except for me it just keeps prompting for the password, even though I'm entering the right one. All very frustrating. (I use debian/kde and dolphin file manager. It may not handle sftp as elegantly as ubuntu.)

Thanks for the suggestions! And if you have more, please bring 'em on Big Grin
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
OS: Mobian Bookworm, Phosh. Pinephone Braveheart from 2020-02-11
  Reply
#7
(05-16-2021, 12:35 AM)quixote Wrote: At that prompt, I tried cp ~/anbox/* mobian@10.66.0.10:/home  but maybe I typoed something because it didn't go. I'll try again. Edited to add: nope. I've tried  mobian@10.66.0.10:/home  mobian@10.66.0.10:/home/mobian  mobian@10.66.0.10:/ and it keeps saying "is not a directory."

If you're using sshfs, that's not the way you would copy files, you copy to the mount point. If we assume that you mounted the $HOME of the Pinephone with sshfs to /tmp/mnt as in my example, for what you're trying to do the command would be:

Code:
cp -R ~/anbox/* /tmp/mnt

Note that "cp -R" will copy subdirectories. If not comfortable using the command line it might be easier to just bring up two file manager windows for the source and destination, and copy/paste between them.

Certainly if you set up ssh on the Pinephone to require a key you either need to change that to permit password login or add your computer's public key to /home/mobian/.ssh/authorized_keys on the phone. (Once you can do ssh logins to the Pinephone then sshfs should work as well.)
  Reply
#8
(05-15-2021, 06:00 AM)Zebulon Walton Wrote: On the sshfs command,  "/local/mount/point" is not meant to be taken literally if that's what you're doing

Of course that was what I was doing! Smile

Anyway i've followed your instructions and with a few tries (and errors), I eventually made it! Thanks a lot for the help!

Regarding security considerations and to be perfectly clear, are you saying that unmounting the Pinephone after the transfer leaves the ssh server running?
I would have other questions regarding ssh, but I guess that not Pinephone related anymore, so I'll save that for somewhere else.

Thx again.
  Reply
#9
Glad you got it working! It's actually pretty easy once you see how it works.

But yes, when you unmount the sshfs connection the ssh server is still running on the Pinephone. In fact you probably have it running all the time anyway at the moment, which is an obvious security issue if you will be using the phone on public wifi or cellular internet.

What I do is run the ssh server on an alternate port, set it up to only accept key-based logins, and firewall off the port from everything but my home LAN's subnet.

Alternately you could just configure the ssh server so it does not start automatically at boot time and just start/stop it manually as needed.
  Reply
#10
Urgh. I did forget the local mountpoint step. However, it still does me no good because I get "connection reset by peer". The peer in this case being the desktop, not the pinephone. (Recap: ssh on desktop for me is totally stuck on however I set it up when I needed serious security for students in a lab. It had passwordless, private key entry. So I installed easyssh on the pinephone. I can log into the desktop from the phone, but other than that seem to get nothing but error messages.)

When the pinephone tries to access the desktop, I bump into the same key-needed issue I think. Since you have your system set up for that, maybe you know how to turn it OFF? I found the /etc/ssh config file and uncommented password access to allow it, no settings in ~/.ssh/ config files that look relevant, but something is still preventing all access.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
OS: Mobian Bookworm, Phosh. Pinephone Braveheart from 2020-02-11
  Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Short Guide to Using OpenVPN client GUI and .ovpn config file on PP biketool 0 98 12-16-2024, 02:07 PM
Last Post: biketool
  Calls 4G not working oliwierzgorniak 2 2,276 08-06-2024, 02:20 PM
Last Post: baptx
  Mobile internet via cellular network mostly not working Anna 18 14,202 01-19-2024, 02:59 AM
Last Post: anonymous
Exclamation The internal speaker stops working anonymous 6 2,762 01-17-2024, 05:53 PM
Last Post: anonymous
  APN settings not working with new operator SIM card user641 1 1,451 03-01-2023, 04:43 PM
Last Post: anonymous
  Possible Solution for Microphone Not Working Ferriah 0 1,236 02-13-2023, 01:09 PM
Last Post: Ferriah
  Squeekboard stopped working Zebulon Walton 2 1,708 11-24-2022, 08:41 PM
Last Post: Zebulon Walton
  suspend inhibit no longer working jsch 3 2,752 10-23-2022, 09:20 AM
Last Post: LibrePhoneUser
  low disk space on file system root revisited benedikt55 2 2,154 09-24-2022, 10:16 AM
Last Post: benedikt55
  Rescue Your Mobian post Update Aug22 faster fix to working guide biketool 9 6,922 09-05-2022, 12:10 AM
Last Post: biketool

Forum Jump:


Users browsing this thread: 1 Guest(s)