Raspberry omv

Post on 01-Jul-2015

435 views 3 download

Transcript of Raspberry omv

NAS on Raspberry

Stefano BallardiniStefano Ballardini 10262013 @ I.I.S. Alberghetti - Imola 11092013 @ Sala Consigliare Comune di Faenza - Faenza

Un Network Attached Storage (NAS) è un dispositivo collegato ad una rete di computer la cui funzione è quella di condividere tra gli utenti della rete una memoria di massa, in pratica costituita da uno o più dischi rigidi

(from Wikipedia)

DEFINIZIONE DI N.A.S.

VANTAGGI

- Dati centralizzati- Dati in sicurezza

PRIMO INGREDIENTE: il RaspBerry PiDEFINIZIONE DI RASPBERRY PI

Il Raspberry Pi è un single-board computer (un calcolatore implementato su una sola scheda elettronica) sviluppato nel Regno Unito dalla Raspberry Pi Foundation

( from Wikipedia )

http://www.raspberrypi.org/

CARATTERISTICHE HW DEL RASPBERRY

SECONDO INGREDIENTE: SdCard compatibile

http://elinux.org/RPi_SD_cards

http://www.raspberrypi.org/

TERZO INGREDIENTE: la RaspbianDEFINIZIONE

Raspbian is a free operating system based on Debian optimized for the Raspberry Pi hardware

- www.raspbian.org

- http://www.raspberrypi.org/downloads

+ = Raspbian

INSTALLAZIONE di Raspbian:

dd bs=4M if=immagine-wheezy-raspbian.img of=/dev/X

INSTALLAZIONE di Raspbian:

dd bs=4M if=immagine-wheezy-raspbian.img of=/dev/X

AGGIUNTA IP di RETE:

Modifica di /etc/network/interface di Raspbian

iface eth0 inet static address 192.168.0.10 netmask 255.255.255.0 gateway 192.168.0.1 broadcast 192.168.0.0

RAGGIUNGIAMO IL RASPBERRY:

- Configurazione ip sul pc locale- Accensione del Raspberry- Collegamento al Raspberry via SSH

PRIME CONFIGURAZIONI:# raspi-config

MA CHE ASPETTO HA STA RASPBIAN ?

- utilizziamo un server VNC: - ci colleghiamo al Raspberry via ssh - # apt-get install tightvncserver - $ tightvncserver :1 -geometry 800x600

- dal pc locale usiamo un client vnc per vedere RS - # apt-get install xtightvncwiever - $ xtightvncwiever 192.168.0.10:1

MA CHE ASPETTO HA STA RASPBIAN ?

QUARTO INGREDIENTE: Open Media VaultDEFINIZIONE

OpenMediaVault is the next generation network attached storage (NAS) solution based on Debian Linux. It contains services like SSH, (S)FTP, SMB/CIFS, DAAP media server, RSync, BitTorrent client and many more. Thanks to the modular design of the framework it can be enhanced via plugins.

Iso disponibili per cpu x86 a 32 e 64 bit

REPOSITORY DI OPENMEDIAVAULT e INSTALLAZIONE

Aggiungiamo i repo nel /etc/apt/sources.listdeb http://packages.omv-plugins.org fedaykin maindeb http://packages.omv-plugins.org fedaykin-armhf main

apt-get updateNO_PUBKEY 68EA3C673512CBCF

Prendere la chiave conwget -O - http://packages.omv-plugins.org/omv-plugins.pub|apt-key add -

apt-get updateapt-get install openmediavault

TRUBLESHOOTING

Si sono verificati degli errori nell'elaborazione: tftpd-hpa openmediavaultE: Sub-process /usr/bin/dpkg returned an error code (1)

Modificare il file /etc/default/tftpd-hpa, ultima riga, in questo modo:TFTP_OPTIONS="--secure –ipv4"

apt-get install openmediavault

CONFIGURAZIONE DI OPENMEDIAVAULT

Browser, ip del NAS

adminopenmediavault

BUONA CONFIGURAZIONE !

CONFIGURAZIONE SAMBA on OMV web interface

- Impostazioni: Gruppo di lavoro- Condivisioni: Nome Condivisione

Cartella condivisa Vari parametri

SAMBA on OMV

LATO CLIENT:- usare il classico file manager

SAMBA on OMV TROUBLESHOOTING

LATO CLIENT- Cotrollare /etc/samba/smb.conf

CONFIGURAZIONE NFS on OMV web interface AND TROUBLESHOOTING

- Impostazioni: Abilitare NFS- Condivisioni: Risorsa Condivisa

Range IP Permessi

E in più.....

CONFIGURAZIONE NFS on OMV web interface AND TROUBLESHOOTING

E in più....

Lato Raspberry-OMV:

- installare rpcbind- controllare /etc/default/nfs-common NEED_IDMAPD=yes NEED_GSSD=no- controllare /etc/default/nfs-kernel-server NEED_SVCGSSD=no- controllare /etc/exports sostituire ro con rw - i servizi NFS non partono in automatico /etc/init.d/nfs-common start /etc/init.d/nfs-kernel-server start /etc/init.d/rpcbind start- NFS in automatico update-rc.d rpcbind enable && update-rc.d nfs-common enable

CONFIGURAZIONE NFS on OMV web interface AND TROUBLESHOOTING

E in più....

Lato Client:

- installare nfs-common- controllare /etc/default/nfs-common NEED_IDMAPD=yes- controllare le risorse “exportate” del NAS showmount -e 192.168.0.10- creare la directory in cui montare la risorsa remota mkdir /home/nfs- montiamo staticamente la risorsa condivisa sul NAS mount -t nfs4 -o _netdev,hard,intr 192.168.0.10:/ home/nfs

E in più....

Grazie per l'attenzione e buon Raspberry a tutti !

www.imolug.org http://www.imolug.org/MailingList https://www.facebook.com/ImoLUG