Tecnologia da Informação - TI : Configure Clients to use Ceph Storage like follows

Total de visualizações de página

quinta-feira, 14 de abril de 2016

Configure Clients to use Ceph Storage like follows


Configure Clients to use Ceph Storage like follows.
                                         |
        +--------------------+           |           +-------------------+
        | [dlp.server.world] |10.0.0.30  |   10.0.0.x|   [   Client  ]   |
        |    Ceph-Deploy     +-----------+-----------+                   |
        |                    |           |           |                   |
        +--------------------+           |           +-------------------+
            +----------------------------+----------------------------+
            |                            |                            |
            |10.0.0.51                   |10.0.0.52                   |10.0.0.53 
+-----------+-----------+    +-----------+-----------+    +-----------+-----------+
| [node01.server.world] |    | [node02.server.world] |    | [node03.server.world] |
|     Object Storage    +----+     Object Storage    +----+     Object Storage    |
|     Monitor Daemon    |    |                       |    |                       |
|                       |    |                       |    |                       |
+-----------------------+    +-----------------------+    +-----------------------+

 
For exmaple, Create a block device and mount it on a Client.
[1]First, Configure Sudo and SSH key-pair for a user on a Client and next, Install Ceph from Ceph admin Node like follows.
[cent@dlp ceph]$ 
ceph-deploy install client 

[cent@dlp ceph]$ 
ceph-deploy admin client
[2]Create a Block device and mount it on a Client.
[cent@client ~]$ 
sudo chmod 644 /etc/ceph/ceph.client.admin.keyring 

# create a disk with 10G

[cent@client ~]$ 
rbd create disk01 --size 10240
# show list

[cent@client ~]$ 
rbd ls -l 

NAME     SIZE PARENT FMT PROT LOCK
disk01 10240M          2

# map the image to device

[cent@client ~]$ 
sudo rbd map disk01 

/dev/rbd0
# show mapping

[cent@client ~]$ 
rbd showmapped 

id pool image  snap device
0  rbd  disk01 -    /dev/rbd0

# format

[cent@client ~]$ 
sudo mkfs.xfs /dev/rbd0
# mount

[cent@client ~]$ 
sudo mount /dev/rbd0 /mnt
[cent@client ~]$ 
df -hT 

Filesystem              Type      Size  Used Avail Use% Mounted on
/dev/mapper/centos-root xfs        27G  1.3G   26G   5% /
devtmpfs                devtmpfs  2.0G     0  2.0G   0% /dev
tmpfs                   tmpfs     2.0G     0  2.0G   0% /dev/shm
tmpfs                   tmpfs     2.0G  8.4M  2.0G   1% /run
tmpfs                   tmpfs     2.0G     0  2.0G   0% /sys/fs/cgroup
/dev/vda1               xfs       497M  151M  347M  31% /boot
/dev/rbd0               xfs        10G   33M   10G   1% /mnt

Nenhum comentário:

Postar um comentário

O Caminho para a Infraestrutura Ágil: Modernizar ou Estagnar?

  Com certeza. Para um post mais denso e detalhado, o ideal é abordar a Transformação Digital e a Modernização da Infraestrutura . Esse tipo...