wiki.ipfire.org

The community-maintained documentation platform of IPFire

User Tools

Site Tools


optimization:outsourcing:start

Partial outsourcing of IPFire file system on a file server

Some may wonder at making an effort, but in embedded systems, the outsourcing of areas that are burdened by constant storage and retrieval (eg, proxy-cache), the lifetime of the CompactFlash card to extend considerably. In the following I describe the configuration of the IPFire as an NFS client and NFS server on Debian for outsourcing the booster Cache. Qualify for the “outsourcing”:

  • Fileserver with NFS (NFS=Network File System)
  • IPFIRE Router

1. First we need to install on server (Debian) and client (IPFire) the required packages.

On IPFIRE we need a root console:

pakfire update && pakfire install nfs

or WebGUI → IpFire → Install Addons → nfs

If packages are installed successfully IPFire requires a restart on console: Code:

reboot

or WebGUI → System → Restart

On file server install the NFS server. On my Debian Lenny server looks like this: Code:

apt-get install nfs-kernel-server nfs-common portmap

(maybe the NFS server is already installed) Now you must created on the server folder where the cache can be written. For example: Code:

mkdir /srv/router/booster/

This directory must now be made ​​writable. The Quick n 'Dirty method are

chmod 777 /srv/router/booster/

You should take more restrictive measures the folder secure is enough. (user, group, etc.) Then contributes to the newly create directory in the /etc/exports (eg nano): Code:

/srv/router 192.168.0.1(rw,sync)

(Assuming the later client (= IPFire) has the IP 192.168.0.1) then just have the change to: Code:

exportfs -a

be assumed.

Now you have included the shared folders on IPFire. First, delete old cache folder any existing.

rm -R /var/updatecache

Then creates one selfsame folder again:

mkdir /var/updatecache

… select the correct user:

chown nobody:squid /var/updatecache

… Makes it writable:

chmod 775 /var/updatecache/

Now connect to the NFS server:

mount 192.168.0.10:/srv/router/booster /var/updatecache

That's it. The whole solution is quite Quick 'n Dirty. Maybe you can help them improve.

optimization/outsourcing/start.txt · Last modified: 2011/07/16 07:47 by Lander