1753756 Members
4736 Online
108799 Solutions
New Discussion юеВ

Re: httpfs

 
SOLVED
Go to solution
Piotr Kirklewski
Super Advisor

httpfs

Hi there.
Is there anyone familiar with httpfs and how to mount the files in linux.
I have one server with apache running and some files in /var/www/html/repo.
On a different system I would like to be able to mount the repo to /mnt/repo but I'm struggling to do so.

http://10.15.0.3/repo/
Parent Directory -
BT4/ 07-Dec-2009 01:51 -
CentOS/ 18-Nov-2009 02:42 -
Knoppix/ 04-Dec-2009 01:05 -
bt4-beta.iso 07-Dec-2009 03:13

mount -t httpfs http://10.15.0.3/repo/bt4-beta.iso /mnt/httpfs/

mount: unknown filesystem type 'httpfs'

Anyone ?
Jesus is the King
3 REPLIES 3
Matti_Kurkela
Honored Contributor
Solution

Re: httpfs

http://httpfs.sourceforge.net/

HTTPFS is a FUSE-based filesystem, and it has its own mount utility, which is named simply "httpfs". This is because it needs to set up the appropriate processes before the actual mount operation.

Of course, to use FUSE, your system also needs to have the FUSE library and kernel module available. Old distributions may not have those components.

The correct mount command in this case is:

httpfs http://10.15.0.3/repo/bt4-beta.iso /mnt/httpfs/

(note that there is no "mount" anywhere on the command line!)

It may be possible to install/symlink the "httpfs" binary to /sbin/mount.httpfs, so that the regular mount command can automatically use it as a "mount helper" program for httpfs.

Alternatively, the FUSE FAQ says:
-----
Is it possible to mount a fuse filesystem from fstab?

Yes, from [FUSE] version 2.4.0 this is possible. The filesystem must adhere to some rules about command line options to be able to work this way.
Here's an example of mounting an sshfs filesystem:

sshfs#user@host:/ /mnt/host fuse defaults 0 0

The mounting is performed by the /sbin/mount.fuse helper script. In
this example the FUSE-linked binary must be called sshfs and must reside somewhere in $PATH.
-----

MK
MK
Kannan Kumaran
New Member

Re: httpfs

Hi,

To use the content of the cd you can just loop mount the iso
mount -o loop,ro http://10.15.0.3/repo/bt4-beta.iso /mnt/httpfs/

Rgds,//KK
Piotr Kirklewski
Super Advisor

Re: httpfs

Hi there


I have a PXE server in my network with Centos,Fedora,Memtest,Knopix etc.

I need to add backtrack to the list.

So I copied vmlinuz + initrd.gz to /tftpboot/backtrack/
I modified my configuration file: vim /tftpboot/pxelinux.cfg/default

LABEL backtrack
MENU LABEL BT4
KERNEL backtrack/vmlinuz
IPAPPEND 1
APPEND netboot=http httproot=http://10.15.0.3/repo/ vga=0x317 initrd=backtrack/initrd.gz ramdisk_size=9999 root=/dev/ram0 rw quiet

When I boot I can see the initrd.gz and vmlinuz are being loaded but then the system is unable to find BT4 directory and it drops into busybox shell. Which means that http://10.15.0.3/repo/ is not being mounted to /mnt/httpfs/.

I can mount it from command line though:

httpfs http://10.15.0.3/repo/ /mnt/httpfs/

All this makes me think that backtrack doesn't really understand following line in the configuration file:

APPEND netboot=http httproot=http://10.15.0.3/repo/

So how to make backtrack aware that I need it to mount httproot=http://10.15.0.3/repo/ to /httpfs during the boot proces ?

Reagrds

Peter
Jesus is the King