Connections Component Pack: Configurando o NFS Server

From Wiki
Revision as of 14:59, 13 August 2019 by Ebasso (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Procedimento

1) Criar a partição pv-connections

2) Executar a criação dos diretórios

mkdir -p /pv-connections/esdata-{0,1,2}
mkdir -p /pv-connections/esbackup
mkdir -p /pv-connections/customizations
mkdir -p /pv-connections/mongo-node-{0,1,2}/data/db
mkdir -p /pv-connections/solr-data-solr-{0,1,2}
mkdir -p /pv-connections/zookeeper-data-zookeeper-{0,1,2}
mkdir -p /pv-connections/test

chmod -R 777 /pv-connections
chmod -R 005 /pv-connections/customizations

3) Instalar os pacotes do nfs

yum -y install nfs-utils

4) Configurar o /etc/exports

VOCÊ PODE UTILIZAR O nsfSetup.sh, MAS PREFERI FAZER MANUALMENTE.

Você deve adicionar as subnets de todos os seus servidores kubernetes.

/pv-connections/mongo-node-0/data/db       10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/mongo-node-1/data/db       10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/mongo-node-2/data/db       10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/solr-data-solr-0           10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/solr-data-solr-1           10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/solr-data-solr-2           10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/zookeeper-data-zookeeper-0 10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/zookeeper-data-zookeeper-1 10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/zookeeper-data-zookeeper-2 10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/esbackup                   10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/esdata-0                   10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/esdata-1                   10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/esdata-2                   10.1.0.0/255.255.0.0(rw,no_root_squash)
/pv-connections/customizations             10.1.0.0/255.255.0.0(rw,no_root_squash)

5) Executar o comando

systemctl restart nfs-server


6) Testando em um servidor remoto

mkdir /pv-connections

mount -t nfs 10.1.1.1:/pv-connections /pv-connections

cd /pv-connections/

ls

testando a escrita

cd /pv-connections/test

touch $HOSTNAME

Ver também