this post was submitted on 19 Mar 2025
5 points (77.8% liked)

Linux

52095 readers
1479 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Hey,

So I've been connecting to an ftp server which I worked on with apps like GNOME Builder, and backed up the contents of with Pika Backup, connecting to it via the GNOME Files application, Nautilus, from the Network tab.

Recently, apps stopped being able to read files I opened with the file picker hosted on the ftp server, and after a lot of debugging I realised that was because Nautilus had for some reason switched from mounting the files under /run/user/1000/gvfs/ftp_address to the more abstract path ftp://ftp_address, under the virtual directory computer:///. Now apps can't read those files as they are not mounted under an actual path.

I couldn't find a way in Nautilus, FileZilla, or Dolphin to mount the ftp server files under a specified path /mnt/ftp_username, or even to put it back to the unwieldy but still working path it was under before, using a GUI.

I was recommended by an LLM assistant to use the curlftpfs command, but even with several variations of a command such as the following

sudo curlftpfs -v -o "uid=$UID,gid=$GID" ftp://username:correct%20password@ftp_address /mnt/ftp_username

it always gave the same error

Error setting curl: 

The curl command worked by itself, just not with curlftpfs, but with just curl I can't mount it.

I'm not sure what else to try, could I have some advice please?

Edit: it seems the error message was a bug with a combination of using curlftpfs and curl v8.9.1

A commenter also suggested using rclone or gio, as apparently curlftpfs is unmaintained and that's why it's not working.

all 17 comments
sorted by: hot top controversial new old
[–] eldavi@lemmy.ml 2 points 1 day ago (1 children)

in your shoes: i would switch to different connection method to see if it's curl that's causing your problem. ssh w sshfs would be the easiest switch since it doesn't required you to modify the ftp server, other than to install the ssh server.

if it's connects, then you know that curl is your culprit and you can further narrow down the problem; or just stick w ssh.

if it doesn't connect, then you know that curl is probably okay and that your problem is elsewhere.

[–] JackGreenEarth@lemm.ee 2 points 1 day ago

Sorry, I should have mentioned in the post: curl worked by itself, just not with curlftpfs. Someone else suggested using rclone, so I'm going to try that

[–] 2xsaiko@discuss.tchncs.de 2 points 1 day ago (1 children)

Try “gio mount ftp://…”

[–] JackGreenEarth@lemm.ee 1 points 1 day ago (1 children)
aarvi@fedora:~$ gio mount ftp://jack101:correct%20password@oncilla.mythic-beasts.com /mnt/jack101
gio: file:///mnt/jack101: volume doesn’t implement mount
gio: ftp://jack101@oncilla.mythic-beasts.com/: Location is already mounted

I think it is already mounted, but under the annoying computer:/// virtual directory, not where I want it, and what does it mean by 'volume doesn't implement mount'?

[–] 2xsaiko@discuss.tchncs.de 2 points 1 day ago (1 children)

Is there really nothing in /run/user/1000/gvfs? Try gio mount -l. Maybe unmount and remount.

It’s unlikely that it doesn’t actually mount, from the man page:

Mounting refers to the traditional concept of arranging multiple file systems and devices in a single tree, rooted at /.

The first error is because you have a separate argument at the end which is a local path. gio mount takes a list of locations to mount and not a mount point.

[–] JackGreenEarth@lemm.ee 1 points 1 day ago

Yeah, I tried without the mount point too, but I think that's just the same as what Nautilus does. There is nothing under /run/user/1000/gvfs

[–] a14o@feddit.org 2 points 1 day ago (1 children)

Error setting curl:

That doesn't seem like a complete error message to me. Is there any more information? Maybe with the -d (debug) flag?

[–] JackGreenEarth@lemm.ee 1 points 1 day ago (1 children)

I know, right? But even with -d, -v, or -o debug, that's all I get

[–] a14o@feddit.org 2 points 1 day ago (1 children)
[–] JackGreenEarth@lemm.ee 1 points 1 day ago (1 children)

Hmm, that also says it should have been fixed last year

This bug is fixed in current master, set to be released in curl 8.10.0 on September 11, 2024.

[–] a14o@feddit.org 2 points 1 day ago* (last edited 1 day ago) (1 children)

Fixed in curl, but not in a curlftpfs, apparently. Look at the comments on the accepted answer.

[–] JackGreenEarth@lemm.ee 1 points 1 day ago (1 children)

Idk how to downgrade it, it doesn't seem to be working

aarvi@fedora:~$ sudo dnf dg curl-8.8.0
Updating and loading repositories:
Repositories loaded.
Failed to resolve the transaction:
No match for argument: curl-8.8.0
You can try to add to command line:
  --skip-unavailable to skip unavailable packages
aarvi@fedora:~$ 
[–] a14o@feddit.org 2 points 1 day ago

I don't think downgrading the curl library is promising here. curlftpfs seems to be unmaintained. I recommend looking for alternatives or alternative workflows.

[–] Strit@lemmy.linuxuserspace.show 2 points 1 day ago (1 children)

Have you tried without the ftp:// part. eg. curlftpfs ftp-user:ftp-pass@my-ftp-location.local /mnt/my_ftp/

[–] JackGreenEarth@lemm.ee 1 points 1 day ago

I hadn't, I just did, unfortunately it gives the same error.