fuseftp: Implementing userspace filesystems with Perl
Well, as I mentioned earlier, 2.6.14 has this nifty new FUSE feature, allowing the implementation of a file system in userspace. Unfortunately, there was no implementation of a FTP filesystem. Fortunately, there are Perl bindings for FUSE :-).
One can implement a userspace filesystem using the whole power of Perl, and that makes it quite easy. I implemented a basic ftp filesystem this morning, which uses Fuse.pm and Net::FTP to allow read only access to ftp servers. It works quite well and was really easy, so this might be the beginning of a couple of nice userspace filesystems written in Perl. I could actually create MegasusFS….
BTW, you can download fuseftp from my wiki page.
Usage is quite easy, you can simply:
marcus@hal2000:~: mkdir kernel marcus@hal2000:~: fuseftp kernel/ ftp.kernel.org & Successfully logged into ftp.kernel.org [1] 7150 marcus@hal2000:~: cd kernel/ marcus@hal2000:~/kernel: ls for_mirrors_only lost+found pub usr welcome.msg marcus@hal2000:~/kernel: cd .. marcus@hal2000:~: fusermount -u kernel/ [1]+ Done fuseftp kernel/ ftp.kernel.org
You are missing support for passive connections, I hacked this small thing into your code (could be done nicer, but it’s 7am here and i need to get into my bed soon):
————————————————
#make the connection
my $ftp;
if ($arg_opts{”–passive”}) {
$ftp = new Net::FTP($host, Passive => 1) or
die “Can’t connect to $host: $@\n”;
} else {
$ftp = new Net::FTP($host) or
die “Can’t connect to $host: $@\n”;
}
————————————————
Of course the help need to be updated after this, too…but it is outdated in every case (hint: “fusesmb”).
Nice work btw. ![]()
Thanks, applied, it is in 0.4. Good catch about the fusesmb, the fun thing is that I never actually had a look at fusesmb’s source, so this just came from my brain confusing the one three letter abbriviation with another.
Thanks for this. It’s working nicely here - I’m in the process of packaging it for Arch Linux.
I’m getting an error from one particular server, debug output as follows:
$ fuseftp –debug heanet http://ftp.heanet.ie &
[1] 24532
$ Successfully logged into http://ftp.heanet.ie
unique: 1, opcode: INIT (26), nodeid: 0, insize: 48
INIT: 7.2
INIT: 7.2
unique: 1, error: 0 (Success), outsize: 24
$ ls heanet
unique: 2, opcode: GETATTR (3), nodeid: 1, insize: 40
unique: 2, error: 0 (Success), outsize: 112
ls: heanet: Input/output error
$ fusermount -u heanet
unique: 3, opcode: FORGET (2), nodeid: 1, insize: 48
FORGET 1/1
[1]+ Done fuseftp –debug heanet http://ftp.heanet.ie
I can lftp to the server, so I know it’s working. I’ve also tried it with –passive, but the result is the same.
I have sent you a patch to fix the “–passive”-stuff and to (optional) ask the user for the password. Hope that gets included, too. ![]()
I have another patch witch is to simple to create a patch. Add these lines after ‘print “Successfully logged into $host\n”;’:
unless (DEBUG || $arg_opts{’–foreground’})
{
fork() and exit(0);
}
Now fuseftp will put itself into the background. Works fine here…
Of course the option “–foreground” must be added in the docu, too.
And btw.: Seems like this blog translates “–” (”- -”, two minus) into “-” (one minus)….
First line shoud be the following I think:
unless (DEBUG || $arg_opts{’–foreground’} || $arg_opts{”–debug”})
(Sorry for spamming)
it would be nice to be able to ftp to a server listening on a nonstandard port (i.e. not port 21); is that already possible?
AltLinux Sisyphus
AS: Perl FUSE tests shows one error, so this is not clear test.
1) i wish there’d be a way to use generic mount command.
Perhaps in the mountpoind directory there can be some dot-file with more info for fuse and fuse filesystems?
2) what about access grants ? I made folder for local anonymous ftp server as /mnt/temp.ostnet.ru (root:root, chmod 1+rw)
When i make fuseftp i got all dirs in /mnt/temp.ostnet.ru belonging to me (bdv:bdv) but with only grants of rx, i could not make subdirectory there or upload files
3) fuse FtpFS is imho to be able to log its messages to SysLog or kernel log perhaps.
4) FtpFS is to handle filenames locales.
NEwest FTP RFC claims it is UTF8 used for naming files, but… i saw no such modern ftp servers nor clients still.
In russia, usually FTP server is patched to accept/list filenames in windows-1251 charset fir dumb Win32 clients and more sofisticated unix clients (lftp, gFTP, etc) usually have option to use it instead of their unix-box locale. http://www.freesource.info/wiki/Lokalizacija/NATSPECDescription
As usual, people will start to use a small hack for the weirdest things - and here I go:
I have this small dedicated server that comes with 40GB disk and 40GB ftp-accessible backup space.
I can use fuseftp to mount it and copy over locally created tarballs with backups and even run things like tar -czf /mnt/ftp-backup/lala.tar.gz /var.
but I have something else in mind
at first, is there a way to keep the mount active (i.e. sending NOOP for at least 30 minutes?), second
I’m trying to turn that backup space into a filestorage for my backup utility, but am getting weird errors as if some things like stat, etc. won’t work.
A small example…
Connecting to Storage daemon File at xxxx:9103 …
Sending label command for Volume “lala” Slot 0 …
dev.c:111 Unable to stat device /mnt/ftp-backup/bacula: ERR=Permission denied
Device “FileStorage” requested by DIR could not be opened or does not exist.
3999 Device “FileStorage” not found or could not be opened.
[…]
Well, I’m running this as root, and I can’t tell why this permission denied is coming up. Do You have any hint for me?
Florian
I upgraded fuse to 2.5.0 today, and fuseftp no longer works. Here’s the error message:
$ fuseftp my_mnt/ http://ftp.myisp.com
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Successfully logged into http://ftp.myisp.com
Backgrounding…
$ /usr/bin/perl: relocation error: /usr/lib/perl5/site_perl/5.8.7/i686-linux-thread-multi/auto/Fuse/Fuse.so: symbol fuse_mount, version FUSE_2.2 not defined in file libfuse.so.2 with link time reference
Downgrading to 2.4.2 solves it for the moment.
Thanks for the suggestion. I rebuilt fuse.pm, and it looked like that was the fix - the error message was not displayed. However, the server was not mounted, either, even though the “Successfully logged etc” and “Backgrounding” messages were shown. I tried again with –debug and it reported a segfault. No other details were given.
I’ll report it upstream.
When running with Fuse.2.4.2-2 I get the following error.
/usr/bin/perl: symbol lookup error: /usr/lib/perl5/site_perl/5.8.6/i386-linux-thread-multi/auto/Fuse/Fuse.so: undefined symbol: fuse_mount_compat22
Any clues what I have done wrong?
Ta
Hi, I’m having problems with Fuse for Perl. I’m running FC4. I ran (as su):
yum install fuse fuse-devel
cpan Cache::File Fuse
Cache::File seems to have installed fine, but Fuse gives me a bunch of problems. I pasted the output to:
http://rafb.net/paste/results/Sly5YX54.html
Thanks in advance for any help.
My FTPFS v3 (written in C++) is the replacement of Fuseftp.
http://freesoft.ex-code.com/ftpfs.xml
Currently I have alpha release which is very slow and probably buggy. But in the future my FTP filesystem should become THE FTP filesystem for GNU/Linux.
Current version of my FTPFS v3 uses LUFS instead of FUSE, but this should be corrected.
I have just installed fuseftp and am delighted with it. However it will not run from /etc/fstab. Here is my entry:
fuseftp#username:password@hostname /mnt/KFT fuse user,rw 0 0
and here is the error if I try to mount it:
mount /mnt/KFT
Use of uninitialized value in join or string at /usr/lib/perl5/5.8.6/File/Spec/Unix.pm line 73.
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Couldn’t make FTP connection to /mnt/KFT on port 21: Net::FTP: Bad hostname ‘/mnt/KFT’!
[mellor@Pier-1~]$
Please maybe someone can help me..
Tried to do the example with kernel.org:
dau@nerd1:~$ fuseftp kernel/ http://ftp.kernel.org
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Successfully logged into http://ftp.kernel.org
Backgrounding…
dau@nerd1:~$ fusermount: failed to open /dev/fuse: Is a directory
could not mount fuse filesystem! at /usr/local/lib/perl/5.8.8/Fuse.pm line 106.
Then i tried to rebuild Fuse.pm but the make test results:
nerd1:~/.cpan/build/Fuse-0.06# make test
PERL_DL_NONLAZY=1 /usr/bin/perl “-Iblib/lib” “-Iblib/arch” test.pl
test/s/mount…..ok 1/3
# Failed test ‘mount succeeded’
# in test/s/mount.t at line 20.
# Looks like you failed 1 test of 3.
test/s/mount…..dubious
Test returned status 1 (wstat 256, 0×100)
DIED. FAILED test 3
Failed 1/3 tests, 66.67% okay
test/chmod…….not properly mounted
Compilation failed in require at test/chmod.t line 2.
BEGIN failed–compilation aborted at test/chmod.t line 2.
test/chmod…….dubious
Test returned status 2 (wstat 512, 0×200)
test/chown…….not properly mounted
Compilation failed in require at test/chown.t line 2.
BEGIN failed–compilation aborted at test/chown.t line 2.
test/chown…….dubious
Test returned status 2 (wstat 512, 0×200)
test/getattr…..not properly mounted
Compilation failed in require at test/getattr.t line 2.
BEGIN failed–compilation aborted at test/getattr.t line 2.
test/getattr…..dubious
Test returned status 2 (wstat 512, 0×200)
test/getdir……not properly mounted
Compilation failed in require at test/getdir.t line 2.
BEGIN failed–compilation aborted at test/getdir.t line 2.
test/getdir……dubious
Test returned status 2 (wstat 512, 0×200)
test/link……..not properly mounted
Compilation failed in require at test/link.t line 2.
BEGIN failed–compilation aborted at test/link.t line 2.
test/link……..dubious
Test returned status 2 (wstat 512, 0×200)
test/mkdir…….not properly mounted
Compilation failed in require at test/mkdir.t line 2.
BEGIN failed–compilation aborted at test/mkdir.t line 2.
test/mkdir…….dubious
Test returned status 2 (wstat 512, 0×200)
test/mknod…….not properly mounted
Compilation failed in require at test/mknod.t line 2.
BEGIN failed–compilation aborted at test/mknod.t line 2.
test/mknod…….dubious
Test returned status 2 (wstat 512, 0×200)
test/open……..not properly mounted
Compilation failed in require at test/open.t line 2.
BEGIN failed–compilation aborted at test/open.t line 2.
test/open……..dubious
Test returned status 2 (wstat 512, 0×200)
test/read……..not properly mounted
Compilation failed in require at test/read.t line 2.
BEGIN failed–compilation aborted at test/read.t line 2.
test/read……..dubious
Test returned status 2 (wstat 512, 0×200)
test/readlink….not properly mounted
Compilation failed in require at test/readlink.t line 2.
BEGIN failed–compilation aborted at test/readlink.t line 2.
test/readlink….dubious
Test returned status 2 (wstat 512, 0×200)
test/rename……not properly mounted
Compilation failed in require at test/rename.t line 2.
BEGIN failed–compilation aborted at test/rename.t line 2.
test/rename……dubious
Test returned status 2 (wstat 512, 0×200)
test/rmdir…….not properly mounted
Compilation failed in require at test/rmdir.t line 2.
BEGIN failed–compilation aborted at test/rmdir.t line 2.
test/rmdir…….dubious
Test returned status 2 (wstat 512, 0×200)
test/statfs……not properly mounted
Compilation failed in require at test/statfs.t line 2.
BEGIN failed–compilation aborted at test/statfs.t line 2.
test/statfs……dubious
Test returned status 2 (wstat 512, 0×200)
test/symlink…..not properly mounted
Compilation failed in require at test/symlink.t line 2.
BEGIN failed–compilation aborted at test/symlink.t line 2.
test/symlink…..dubious
Test returned status 2 (wstat 512, 0×200)
test/truncate….not properly mounted
Compilation failed in require at test/truncate.t line 2.
BEGIN failed–compilation aborted at test/truncate.t line 2.
test/truncate….dubious
Test returned status 2 (wstat 512, 0×200)
test/unlink……not properly mounted
Compilation failed in require at test/unlink.t line 2.
BEGIN failed–compilation aborted at test/unlink.t line 2.
test/unlink……dubious
Test returned status 2 (wstat 512, 0×200)
test/utime…….not properly mounted
Compilation failed in require at test/utime.t line 2.
BEGIN failed–compilation aborted at test/utime.t line 2.
test/utime…….dubious
Test returned status 2 (wstat 512, 0×200)
test/write…….not properly mounted
Compilation failed in require at test/write.t line 2.
BEGIN failed–compilation aborted at test/write.t line 2.
test/write…….dubious
Test returned status 2 (wstat 512, 0×200)
test/s/umount….fusermount: entry for /tmp/fusemnt-root not found in /etc/mtab
# Failed test ‘unmount’
# in test/s/umount.t at line 8.
# Looks like you failed 1 test of 1.
test/s/umount….dubious
Test returned status 1 (wstat 256, 0×100)
DIED. FAILED test 1
Failed 1/1 tests, 0.00% okay
Failed Test Stat Wstat Total Fail Failed List of Failed
——————————————————————————-
test/chmod.t 2 512 ?? ?? % ??
test/chown.t 2 512 ?? ?? % ??
test/getattr.t 2 512 ?? ?? % ??
test/getdir.t 2 512 ?? ?? % ??
test/link.t 2 512 ?? ?? % ??
test/mkdir.t 2 512 ?? ?? % ??
test/mknod.t 2 512 ?? ?? % ??
test/open.t 2 512 ?? ?? % ??
test/read.t 2 512 ?? ?? % ??
test/readlink.t 2 512 ?? ?? % ??
test/rename.t 2 512 ?? ?? % ??
test/rmdir.t 2 512 ?? ?? % ??
test/s/mount.t 1 256 3 1 33.33% 3
test/s/umount.t 1 256 1 1 100.00% 1
test/statfs.t 2 512 ?? ?? % ??
test/symlink.t 2 512 ?? ?? % ??
test/truncate.t 2 512 ?? ?? % ??
test/unlink.t 2 512 ?? ?? % ??
test/utime.t 2 512 ?? ?? % ??
test/write.t 2 512 ?? ?? % ??
Failed 20/20 test scripts, 0.00% okay. 2/4 subtests failed, 50.00% okay.
make: *** [test_dynamic] Fehler 1
Remark:
The /dev/fuse directory was manually created by root…
If i delete it the user got this:
dau@nerd1:~$ fusermount: failed to open /dev/fuse: No such file or directory
could not mount fuse filesystem! at /usr/local/lib/perl/5.8.8/Fuse.pm line 106.
I’ve just tried out fuseftp. And unfortunately, I found out that lufs, although not longer supported, works much better. Fuseftp can’t cope with directories with names like .svn (anything beginning with .) and generally, is not good at writing data. So, for now i stick with lufs. But I will be watching you, it would be nicer to use software that is still supervised than abandonware ![]()
Hi there.
I’ve tried to install fuseftp though difficult but have got a little success.
However, fuseftp seems to not work correctly.
When I mount my local ftp as a directory, I can see all the filenames but having problem reading the contents of the files.
Like I did mount my mp3 folder into Linux and used mpg123 trying to play one, but just keep getting this message:
“substr outside of string at /usr/bin/fuseftp line 381.”
and it keeps repeat and took the whole screen.
I’m using fuseftp 0.8 and complied libfuse-perl by myself.
Hi,
I have a buggy ftp that refuses connection the first time fuseftp tries to connect. It would be nice if fuseftp would have a retry counter, allowing you to retry automatically. Addiotionally I have a lot of ftp servers around that don’t accept e.g. more than 10 users. woulb be nice if fuseftp could handle this.
btw: I got those ugly FUSE cpan errors too, simply use cpan
cpan> install Fuse
cpan> look Fuse
> make install
> exit
That’s it.
There is a trouble on some FTP servers, when ftp_getdir returns only list of files, not directories. I think, that’s because some servers doesn’t process correctly NLST command. Maybe, it would better not to use Net::FTP->ls()(that uses NLST command), use Net::FTP->dir() instead and parse it’s output?
I’m having trouble using fstab or the “mount” command to use fuseftp. If you look into mount.fuse, you’ll see that fuse binaries are supposed to follow the following syntax:
${FSTYPE} ${MOUNTPATH} ${MOUNTPOINT} ${OPTIONS}
However, fuseftp expects
fuseftp OPTIONS MOUNTPOINT MOUNTPATH
I changed mount.fuse as a workaround, but really the order in which fuseftp gets it’s parameters should be changed ![]()
In other news:
–options=allow_others doesn’t work. I think I’m using a wrong version of Fuse… I have version 0.8 of Fuse.pm, is that alright?
# fuseftp –options=allow_others /mnt/boing/ user@host
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Successfully logged into host
Backgrounding…
Use of an invalid mountopt argument at /usr/bin/fuseftp line 588
#
hey there,
just used fuseftp to access a ftp server within my network here. mounting, reading, deleting and stuff works just fine but the performance is somehow dissapointing.
i use 100mbit here which allows me roughly 9mb/sec using ncftp. if i try to fill the same host via fuseftp i hardly get 200kb/sec.
is there something i missed? or is this a common problem?
thanks in advance,
toskala
Well, it shouldn’t be dead slow, but still were running through perl code and we’re doing a lot of caching but still we sometimes need to issue a plentitude of commands (for example a simple ‘ls’ isn’t that simple at all). Maybe that is where the preformance goes. I didn’t experience it to be really slow, but it is still a non local emulated access, which is always slower as a direct access to your local harddrive.
I use gentoo and gave fuseftp a try as the ftp-filesystem using lufis was unusable, hanging nearly all of the time.
But with fuseftp i get the following error:
fuseftp kernel/ http://ftp.kernel.org
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Successfully logged into http://ftp.kernel.org
Backgrounding…
perl: fuse_opt.c:67: fuse_opt_insert_arg: Assertion `pos argc’ failed.
![]()
I can’t seen to find Cache/File.pm anywhere in my Fedora Core 4 box. The best cpan comes up with is Cache/FileCache.pm. Did Cache change? A quick substitution of FileCache for File in Makefile.PL and fuseftp doesn’t work, if they did change the name of the module, they also changed the API.
Hi. I have the following problem:
I need to connect to an ftp host using a ftp-proxy like this:
[LAN][FTP Proxy][FTP Host]
So I tried to set the ftp_proxy environment variable. But I just don’t get it running
Filezilla, my FTP Client is running by using “USER RemoteID@RemoteHost”. Anyone can help?
Regards
Philipp
I’m having problems creating new dirs with fuseftp. “mkdir aha” always responds something like “cannot create directory aha: File not found”. Actually, in German:
mkdir: kann Verzeichnis „aha“ nicht anlegen: Datei oder Verzeichnis nicht gefunden
And the command “ls” shows this funny line:
?——— ? ? ? ? ? aha
However, after unmounting and remounting the filesystem, the directory shows up correctly and is usable.
I’m running Debian unstable. Any ideas?
Regards,
Bernd
Hi,
how can I mount as a Normal-User?
chmod 4755 fusermount
doesn’t work.
I’m running SuSE 9.2.
Regards,
Daniel
File not found problems…
i can connect fine, but listing gives me:
?——— ? ? ? ? ? #FILENAME
?——— ? ? ? ? ? #FILENAME
?——— ? ? ? ? ? #FILENAME
?——— ? ? ? ? ? #FILENAME
and copying gives me:
Trying to flush not open file web4/test
Trying to close not open file web4/test
cp: cannot create regular file `/mnt/backup/test’: No such file or directory
I connect using:
/usr/bin/fuseftp /mnt/backup/ USER:PASS@192.168.1.2:web4
fuseftp 0.8 AND fuse-2.5.3 with all perl modules installed…
perl v5.8.5
.. any ideas ?
Regards,
Glenn
EDIT:
this only seems to be a problem if it’s a windows ftp server im connecting to..
Tried IIS-ftp and WAR-FTPd..
** Fuseftp and SAMBA **
I use fuseftp to mount a ftp server directory in FC5. The mounted directory is exported to windows PC via SAMBA.
Initially, it works and after, say several minutes, the mounted directory becomes empty in FC5 as well as in Windows.
I have to umount and mount again.
I have run fuseftp in debug but the log remains nothing special. Below is a partial debug log:
========
unique: 682, error: 0 (Success), outsize: 16
unique: 683, opcode: GETATTR (3), nodeid: 1, insize: 40
unique: 683, error: 0 (Success), outsize: 112
unique: 684, opcode: OPENDIR (27), nodeid: 1, insize: 48
unique: 684, error: 0 (Success), outsize: 32
unique: 685, opcode: RELEASEDIR (29), nodeid: 1, insize: 56
unique: 685, error: 0 (Success), outsize: 16
unique: 686, opcode: GETATTR (3), nodeid: 1, insize: 40
unique: 686, error: 0 (Success), outsize: 112
========
Pls advise.
Well, I guess that you’re running in the still unresolved reconnection problem at the moment. Fuseftp (or more specific, the underlying Net::FTP) times out after a while without Fuseftp knowing that the connection is lost. This need to be fixed, but I’m quite out of time at the moment.
Hey Marcus,
I’ve been trying to get rsync to work with fuseftp mounted target. I haven’t had a lot of luck, but in the process I’ve found a few bugs in version 0.8.
Mkdir/rmdir bug.
The ftp_makedir and ftp_rmdir functions don’t properly clear dir_seen for the directory the new directory was made/removed in. You also need to delete the attr_cache for the newly made/deleted directory. If you do “mkdir foo” you get “mkdir: cannot create directory `foo’: No such file or directory”, and when you do an ls -l you get:
?——— ? ? ? ? ? foo
Rename bug.
The ftp_rename function doesn’t properly clear dir_seen, for the source and target directories. It also doesn’t clear the type_cache and attr_cache for old and new files. This bug appears when you “mv foo bar” and then do an “ls -l” in the directory.
total 0
?——— ? ? ? ? ? bar
After the move you can also do “ls -l foo” and still get cached information about the nonexistant file.
O_RDWR bug.
If a file is opened for O_RDWR the code does not handle this case, and opens it for read only. I haven’t completely fixed this problem so you can both read and write the file, I’ve just hacked around it so O_RDWR is a synonym for O_WRONLY. This helps me getting rsync to work.
Here is my diff:
176a177
>
273,286c274,275
my ($dir) = $newname =~ m|(.+)/.+|;
> delete $dir_seen{$dir} if $dir;
321c310
if ($flags & (O_WRONLY)) {
471,476c460
delete $dir_seen{$dir};
490,495c474
delete $dir_seen{$dir};
For some reason my diff got mangled in my last post, trying again.
176a177
>
273,286c274,275
my ($dir) = $newname =~ m|(.+)/.+|;
> delete $dir_seen{$dir} if $dir;
321c310
if ($flags & (O_WRONLY)) {
471,476c460
delete $dir_seen{$dir};
490,495c474
delete $dir_seen{$dir};
Here’s another bug.
Let’s say you open a file for reading, the code calls $ftp->retr and stashes the handle away for later read calls. Before you read/close the file you attempt to stat another file on the filesystem. This hangs. The problem is ftp_getattr gets called and a $ftp->cwd gets executed. This will hang because the FTP server is thining it’s sending you a file, and won’t accept any more commands. At least that’s why I think it doesn’t work.
Mike
Hi,
I mounted a remote ftp target with
fuseftp –passive –cache=memory ./mountpoint/ user:pass@host:/location
During cp-ing away a 5MB file into a local filesystem I got a bunch of such errors:
…
substr outside of string at /usr/bin/fuseftp line 381.
substr outside of string at /usr/bin/fuseftp line 381.
substr outside of string at /usr/bin/fuseftp line 381.
…
The copy of the file was corrupted afterwards. It still had the same filesize tough…
hi, i am having problems w/ ver 0.8. here is the console log:
$ fuseftp ftp-remote psikutas
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Successfully logged into psikutas
Backgrounding…
jose@darkstar:~$ Day too small - -25569 > -24856
Sec too small - -25569
I’m using FC6 and I’ve installed the version 0.8. Here, passive connections not working, and Net::FTP use passive mode as default. I’ve changed fuseftp from:
my $ftp;
if ($arg_opts{’–passive’}) {
$ftp = new Net::FTP($host, Passive => 1, Port => $port);
} else {
$ftp = new Net::FTP($host, Port => $port);
}
to
my $ftp;
if ($arg_opts{’–passive’}) {
$ftp = new Net::FTP($host, Passive => 1, Port => $port);
} else {
$ftp = new Net::FTP($host, Passive => 0, Port => $port);
}
And it works.
Hi Marcus,
thanks for that great program! ![]()
For lightweight use it works great for me, but when I do backups with the dar utility (http://dar.linux.free.fr) which are around 50GB in size, then fuseftp:
1) eats 620MB of memory during operation (I did NOT specify –cache=memory)
2) errors out after some minutes with this message:
substr outside of string at /usr/local/bin/fuseftp line 378.
/bin/ls: cannot access /mnt/ftpbackup/dar_vmail-20070105*: No such file or directory
Line 378 is the last line of ftp_read().
If I can be of any help to fix this problem I’ll be glad to provide more infos / do testing.
Note that with curlftpfs it works fine, but I’d like to get your nice utility working.
Mark
I installed fuseftp for backup files to a FTP Server. A ~200Mbyte file takes hours. Speed to the FTP Server is about ~5Mbyte/sec.
I think it is not made to transfer hundreds of Mbytes or even Gbates of data…
I have installed Fuse on Ubuntu 6.10. I create a folder and connect to the FTP server like so:
mkdir mysite/
sudo fuseftp mysite/ username:password@hostaddress
I get this result:
fuseftp 0.8 - 2005 (c) by Marcus Thiesen
Successfully logged into hostaddress
Backgrounding…
However if I do ls -l I get the following:
?——— ? ? ? ? ? mysite
Can anyone help?
Hi Marcus,
I would like to implement fuseftp in my LiveCD Nekdesk.
Therefore I want to write a mounting utility with kde-kommander.
I would like to know the errorlevels fuseftp produces, that I will be able to depend the neccessary dialogs on.
Regards, Manfred
As of April 2007, the latest update has been released in December 2005, so it can be considered as unmaintained. Use LftpFS
Hallo …
I install on the Linux RedHat Enterprice 3 the fuse rpm “fuse-2.6.5-1.el3.rf”
To padlock I am install the fuseftp-o.8.tar.gz.
After the Command fuseftp cam the Error Messages:
#########
[root@OMS_Linux7 fuseftp-0.8]# fuseftp
Can’t locate Fuse.pm in @INC (@INC contains: /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 /usr/lib/perl5/site_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/site_perl/5.8.0 /usr/lib/perl5/site_perl /usr/lib/perl5/vendor_perl/5.8.0/i386-linux-thread-multi /usr/lib/perl5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl /usr/lib/perl5/5.8.0/i386-linux-thread-multi /usr/lib/perl5/5.8.0 .) at /usr/bin/fuseftp line 44.
BEGIN failed–compilation aborted at /usr/bin/fuseftp line 44.
#############
You can help me ….
The best regards vor Germany
Hans
Is there any way to use fuseftp with an account that has ‘@’ in the account name?
Net::FTP seems to break the string at the first @ character, so it interprets us@er:pass@host as username ‘us’ and host ‘er’, and gives the following error message:
Can’t connect to er: Net::FTP: Bad hostname ‘er’
Well, that’s true. I fixed the handling of @ in the left hand side of the server string, it’s in the just released 0.4 version.