Create CloudConnect 2.5.1.2 instance in Google Cloud

1. Install CloudConnect

curl -O https://storage.googleapis.com/elastifile-upgrade-files/elcc-2.5.1.2-2188.b40fa40469af.tar
tar -xf elcc-2.5.1.2-1847.052a90349548.tar 
cd elcc-2.5.1.2-1847.052a90349548
./install.sh 
systemctl start ccweb
source ~/.bash_profile



2. Install conf file

cd /elastifile/
curl -O https://storage.googleapis.com/elastifile-upgrade-files/conf-patch.tar.gz
tar -xf conf.tar.gz 
nano conf/elcc.conf 


3. Activate elcc with json (required for 2.5.2+)

curl -O https://storage.googleapis.com/elastifile-upgrade-files/offline.json
/elastifile/bin/elcc service init offline.json -M mixed 


4. Mount local SSD (optional if using local SSD)

mkfs.ext4 -F /dev/sdb
mkdir -p /mnt/localssd
mount /dev/sdb/ /mnt/localssd/


5. Generate test files (optional)

for local ssd:
cd /mnt/localssd/
mkdir 100GB2
mkdir elcc
mkdir elcc/ccstore
mkdir elcc/workspace


Generate files 

cd 100GB2
dd if=/dev/urandom of=100GBfile2 bs=100M count=1000
cd 10



Generate files/dirs

#!/bin/bash
for i in {1..100}; do
  mkdir "dir-$i"
  for f in {1..1000}; do dd if=/dev/urandom of=dir-$i/10MBfile$f bs=1M count=10 1>/dev/null 2>&1; done
done


Create Buckets 2MB block and attach

/elastifile/bin/elcc bucket create gcp andrew-2-mb -C /elastifile/ccweb/elcc_gc_credentials/credentials.json 


/elastifile/bin/elcc bucket format gcp andrew-2-mb -B 2048 -C /elastifile/ccweb/elcc_gc_credentials/andrew-sa-elastifile-sa.json


Create Bucket in AWS

elcc bucket create aws andrew-aws-bucket-512-149u5ty --access AAAAAAAAAAAA --secret gjhdflgjdeorigjelgkrngdljghd
elcc bucket format aws andrew-aws-bucket-512-149u5ty --access AAAAAAAAAAAAAAAAAAAAA --secret gjhdflgjdeorigjelgkrngdljghd


Note: Not specifying a region will create in us-east-1 by default but specifying us-east-1 explicitly will fail 



Attach already created bucket:

/elastifile/bin/elcc ccstore open gcp andrew-2-mb -C /elastifile/ccweb/elcc_gc_credentials/andrew-sa-elastifile-sa.json


Adjust xmx:

nano /elastifile/bin/elcc


Checkin version:

elcc version scan andrew-hashfix-2048 /mnt/localssd/100-1k-1MB/
PID: 22100
[2018.05.02-01:04:28] Files 0 Dirs 0 Data 0 
# summary
{
  "total_num_dirs":101,
  "total_num_files":100000,
  "data_bytes":104857600000,
  "num_skipped":0,
  "elapsed_sec":10,
  "num_dirs_per_sec":10,
  "num_files_per_sec":10000,
  "update_time":"2018.05.02-01:04:38",
  "data_bytes_per_sec":10485760000,
  "num_filtered":0,
  "num_dirs":101,
  "total_data_bytes":104857600000,
  "num_files":100000
}
{
  "workdir":"/mnt/localssd/elcc/workspace/andrew-hashfix-2048__8295013314793849224"
}
OK
then take the workdir and put it in
elcc version commit andrew-hashfix-2048 /mnt/localssd/elcc/workspace/andrew-hashfix-2048__8295013314793849224 /mnt/localssd/100-1k-1MB/ --version_desc=/mnt/localssd/100-1k-1mb --config=/elastifile/conf/elcc.conf --threads=256



Reset CloudConnect vm back to zero:

yum erase -y ccweb-elcc-cli.x86_64 ccwebui.noarch ccweb.x86_64 emanage-assets.x86_64 elcc.noarch


A
Andrew is the author of this solution article.

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.