GNOME Bugzilla – Bug 534027
Nautilus does not handle symlinks on an ftp server
Last modified: 2010-12-24 23:08:51 UTC
Please describe the problem: I set up an ftp server locally, added two ftp user accounts with home directory and created a third folder called 'shared' (with proper permissions set), for the two users to exchange files. I then created symlinks to that shared folder so that it could be accessed by both users (from within their home directories). Works just fine when using a standalone ftp client or through firefox, or... windows explorer (yes, win explorer handles the symlinks properly). Unfortunately, when I create a connection to either ftp account through nautilus (Places/Connect to a server...) I can only connect to the user's home directory, the symlink being reported as broken. The only action nautilus offers is to remove that bad symlink (which is not bad at all as it works when using standalone ftp clients). Steps to reproduce: 1. Open a connection to an ftp server 2. Try to access the directory to which the symlink points 3. Failure... Actual results: Nautilus says the symlink is broken, and offers to remove it. Expected results: I should be able to access the folder to which the symlink points. Does this happen every time? YES Other information:
*** Bug 535100 has been marked as a duplicate of this bug. ***
Are you able to navigate around the share using the gvfs-bin utils? (gvfs-ls, gvfs-cat, etc). If not, we should move this to the gvfs-ftp backend.
(In reply to comment #2) > Are you able to navigate around the share using the gvfs-bin utils? (gvfs-ls, > gvfs-cat, etc). If not, we should move this to the gvfs-ftp backend. > I have the same problem and I can navigate around with gvfs-ls and gvfs-cat: gvfs-mount ftp://www.myserver.at/ gvfs-ls ftp://www.myserver.at/www/ gvfs-cat ftp://www.myserver.at/www/index.php (www is the symlink) [Maybe nautilus checks itself wheter a directory with the given name exists]
A similar problem occurs when you try to access an hidden file or folder. (file which do not appear in the directory-listing but you can still access when you know its name) It tells you »ftp://localhost/hidden« could not be found (german: konnte nicht gefunden werden) Please check your spelling and try again. (german: Bitte prüfen Sie die Rechtschreibung und versuchen Sie es noch einmal.) But you can access the hidden files/folders normally by using gvfs-cat: alexander@hwi-meier:~$ gvfs-cat ftp://localhost/hidden/hidden.txt This is hidden.
Bug is still present in Version 2.24.1 I think the correct component would be "Navigation". This bug is similar to: http://bugzilla.gnome.org/show_bug.cgi?id=551822
In Nautilus 2.26.2 I am able to open hidden direcories, relative symbolic links but not absolute symbolic links. Example outputs: alexander:/home/ftp$ ls -al lrwxrwxrwx 1 root root 8 2009-06-03 10:11 bar -> foo/bar/ drwxr-xr-x 3 root root 4096 2009-06-03 10:11 foo drwxr-xr-x 2 root hidden 4096 2009-06-03 09:49 .hidden lrwxrwxrwx 1 root root 9 2009-06-03 10:31 test -> /var/www/ lrwxrwxrwx 1 root root 3 2009-06-03 10:59 test2 -> ../ alexander:ftp$ gvfs-ls ftp://alexander@localhost/home/ftp/ -lh foo 0 (directory) test2 0 (directory) test 9 (symlink) bar 0 (directory) With nautilus I can access bar, foo and .hidden, test2 but not test (the symbolic link with an absolute path). With gvfs-utils I can access every symlink/directory. As Andreas Henriksson fixed the bug with the hidden directories (http://bugzilla.gnome.org/show_bug.cgi?id=520399) I added him to the CC list.
Hello Alexander! Could you please provide the debug output from gvfsd-ftp when doing your test? Either directly run /usr/lib/gvfs/gvfsd-ftp host=localhost user=foo password=bar or replace your gvfsd main daemon with /usr/lib/gvfs/gvfsd -r to see the debug output .....
Please also specify which version of gvfs you are using. Thanks!
Hello Andreas! I am using gvfs 1.2.2 When opening the FTP-folder in nautilus I get following debug output (I hope I didn't forget something important): --> LIST -a <-- 150 Opening ASCII mode data connection for file list --- drwxr-xr-x 4 ftp nogroup 4096 Jun 3 08:59 . --- drwxr-xr-x 5 root root 4096 Jun 3 07:37 .. --- lrwxrwxrwx 1 root root 8 Jun 3 08:11 bar -> foo/bar/ --- drwxr-xr-x 3 root root 4096 Jun 3 08:11 foo --- lrwxrwxrwx 1 root root 9 Jun 3 08:31 test -> /var/www/ --- lrwxrwxrwx 1 root root 3 Jun 3 08:59 test2 -> ../ <-- 226 Transfer complete --> CWD /home/ftp/var <-- 550 /home/ftp/var: No such file or directory So it seems the problem is, that it is trying to CWD to the target (var) instead of the link name (test).
Created attachment 135872 [details] [review] symlink dest fullpath fix. Fix the handling of symlink with fullpath destinations, rather then a relative destination. This should fix Alexander Meiers problem. (The original bug report is to vague to know if it's the same issue.)
-> gvfs
This problem has been fixed in our software repository. The fix will go into the next software release. Thank you for your bug report. (The patch has been applied to the stable "gnome-2-26" branch and will be part of future 1.2.x releases. The development tree "master" has not been changed since the ftp backend is currently being reorganized in the "ftp-reorg" branch which will hopefully soon be merged into the master branch.... atleast before gvfs 1.4.0 / gnome 2.28.)
I'm sad to say that this bug is happening again. I have Ubuntu Maverick with GNOME Nautilus 2.32.0 and gvfs 1.6.4-0ubuntu1.1 The problem is really in Nautilus since via ftp tool I can cd to symbolic link with no problem. Also gvfs-bin tools works fine.