Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add WeaveScope deployment script #419

Merged
merged 1 commit into from
Mar 22, 2021

Conversation

seokho-son
Copy link
Member

개요

이 PR은
MCIS에 WeaveScope 클러스터를 배치하여,
MCIS의 구성 형상(트래픽, 리소스, 프로세스 현황 등)을 비주얼라이즈하는 GUI를 제공할 수 있도록
WeaveScope 자동 설치 및 배치 스크립트를 제공합니다.

image

사용 방법

~/go/src/github.com/cloud-barista/cb-tumblebug/test/official/sequentialFullTest$

스크립트 실행

./deploy-weavescope-to-mcis.sh aws 2 shson

마지막 출력에 따라 Web 접속

URL: 15.222.62.163:4040/#!/state/{"topologyId":"hosts"}

사용 예시

son@son:~/go/src/github.com/cloud-barista/cb-tumblebug/test/official/sequentialFullTest$ ./deploy-weavescope-to-mcis.sh aws 2 shson
[Check jq package (if not, install)]
install ok installed
####################################################################
## Command (SSH) to MCIS 
####################################################################
[Test for AWS]
MASTERIP: 15.222.62.163
MASTERVM: aws-ca-central-1-shson-0
VMARRAY: [
  {
    "id": "aws-ca-central-1-shson-0",
    "csp_vm_id": "aws-ca-central-1-shson-0",
    "name": "aws-ca-central-1-shson-0",
    "status": "Running",
    "targetStatus": "None",
    "targetAction": "None",
    "native_status": "Running",
    "public_ip": "15.222.62.163",
    "location": {
      "latitude": "45.5000",
      "longitude": "-73.6000",
      "briefAddr": "Canada Central",
      "cloudType": "aws",
      "nativeRegion": "ca-central-1"
    },
    "monAgentStatus": "notInstalled"
  },
...
  {
    "id": "aws-ca-central-1-shson-9",
    "csp_vm_id": "aws-ca-central-1-shson-9",
    "name": "aws-ca-central-1-shson-9",
    "status": "Running",
    "targetStatus": "None",
    "targetAction": "None",
    "native_status": "Running",
    "public_ip": "35.183.137.159",
    "location": {
      "latitude": "45.5000",
      "longitude": "-73.6000",
      "briefAddr": "Canada Central",
      "cloudType": "aws",
      "nativeRegion": "ca-central-1"
    },
    "monAgentStatus": "notInstalled"
  }
]
IPLIST: 15.222.62.163 3.96.202.87 15.222.3.100 35.183.199.121 99.79.161.168 35.182.109.151 35.183.198.152 99.79.60.180 35.182.193.60 35.183.137.159
[Install Weavescope]
{
   "result_array" : [
      {
         "vm_ip" : "15.222.62.163",
         "result" : "Reading package lists...\nB
         "mcis_id" : "aws-ca-central-1-shson",
         "vm_id" : "aws-ca-central-1-shson-0"
      },
...
      {
         "vm_ip" : "35.183.137.159",
         "result" : "Reading package lists...\
         "mcis_id" : "aws-ca-central-1-shson",
         "vm_id" : "aws-ca-central-1-shson-9"
      }
   ]
}

[Start Weavescope] master
{"result":"580b2ed25be6ea00462024cb3d5c8f9be28575ef5cf6f5659ae8a6583017b1c7\nScope probe started"}

[Start Weavescope] the others
{"result_array":[{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-0","vm_ip":"15.222.62.163","result":"Process exited with status 1"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-1","vm_ip":"3.96.202.87","result":"e3fbe2ba95ce735eeecfb8304b10052caac2559b7fb913bf1ed2a34d6e26a8a7\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-2","vm_ip":"15.222.3.100","result":"8ecc6954c7cbe209c41fc0386aee78d2374cbf59af32f22104470eada2702f61\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-3","vm_ip":"35.183.199.121","result":"88c03fde00b5ed4adab7c7199570a895d015f3d66d18f8bd2314a85b064fd9be\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-4","vm_ip":"99.79.161.168","result":"ab0bc3a28e288c3402ae75ee61fa8f1af2236f81151e1b700db98c39e63a4012\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-5","vm_ip":"35.182.109.151","result":"f7a5a6391414362241f3e0664bd3619fbe876f48f5316a1a993cd18592fae4a8\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-6","vm_ip":"35.183.198.152","result":"42d5878e40c5f66da1c3f1a015c981943e3aa67a761fa8b2f28d158b0f24a71d\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-7","vm_ip":"99.79.60.180","result":"18b1b0634d16e536178efbed7dcceb657217d42dfcf18758fe5a556ec7b1a8c9\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-8","vm_ip":"35.182.193.60","result":"aa6edb81aa09a3b6790593d80fca6ff4dd4571aeff6960e7115d6ee6f45e480e\nScope probe started"},{"mcis_id":"aws-ca-central-1-shson","vm_id":"aws-ca-central-1-shson-9","vm_ip":"35.183.137.159","result":"748cb347e58d2ecee3e1b3a8d17f21d6e1490eea3bb5e5c7760e0b3517b32452\nScope probe started"}]}

[Access MCIS Weavescope]
URL: 15.222.62.163:4040/#!/state/{"topologyId":"hosts"}

다음과 같이, MCIS의 VM 구성 및 트래픽 현황 등을 화면으로 보여줌. (aws, gcp, azure 리젼을 각 2개씩 구성한 MCIS 예시)

image

@seokho-son seokho-son requested a review from jihoon-seo as a code owner March 21, 2021 07:01
@seokho-son seokho-son enabled auto-merge March 21, 2021 07:01
@seokho-son
Copy link
Member Author

cc @hermitkim1

Copy link
Member

@jihoon-seo jihoon-seo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What a nice feature!

@seokho-son seokho-son merged commit 8a91102 into cloud-barista:master Mar 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants