Post
Topic
Board Hardware
Re: [ANN] US/North American Bitfury sales now open ***full prototype pics***
by
Jutarul
on 30/09/2013, 08:31:43 UTC
Does anyone have some good pointers for setting up a network file server to point several rPIs at?  I've had a couple of memory cards fail already and I'd like to move to something more dependable.

/cet
just export a separate directory for each raspberry pi and associate it with the IP address each individual pi is booted with (as specified in the cmdline.txt). Then your /etc/exports file should look similar to this:
Code:
# /etc/exports: the access control list for filesystems which may be exported
# to NFS clients.  See exports(5).
#
# Example for NFSv2 and NFSv3:
# /srv/homes       hostname1(rw,sync,no_subtree_check) hostname2(ro,sync,no_subtree_check)
#
# Example for NFSv4:
# /srv/nfs4        gss/krb5i(rw,sync,fsid=0,crossmnt,no_subtree_check)
# /srv/nfs4/homes  gss/krb5i(rw,sync,no_subtree_check)
#
/var/lib/tftpboot/raspberry/192.168.1.249 192.168.1.249(rw,no_root_squash,async,insecure,no_subtree_check)
/var/lib/tftpboot/raspberry/192.168.1.248 192.168.1.248(rw,no_root_squash,async,insecure,no_subtree_check)
Before, you should have copied the rootfs to the server, e.g. by mounting directly the SD card:
mount /dev/sdb2 /mnt/sdb2
mkdir -p /var/lib/tftpboot/raspberry/template
cp -ax /mnt/sdb2/* /var/lib/tftpboot/raspberry/template

and populate each new client:
mkdir /var/lib/tftpboot/raspberry/192.168.1.249
cp -ax /var/lib/tftpboot/raspberry/template/* /var/lib/tftpboot/raspberry/192.168.1.249

The IPs dependent on your particular network configuration.

As long as the number of clients is low, the network and the server should be able to handle it. If somebody has access to >40 pi's, it would be worth some benchmarking to find out how large this can scale.