-
Notifications
You must be signed in to change notification settings - Fork 47
How to install CB Spider on WSL2's Ubuntu under 공유기(in the private Network)
ByoungSeob Kim edited this page Oct 10, 2024
·
2 revisions
============== In this case: Ubuntu 20.04.2 LTS on WSL2 under 공유기 환경
-
basic reference
-
prerequisites for WSL2's Ubuntu
$ sudo apt update; sudo apt install -y make gcc;
$ wget https://golang.org/dl/go1.17.linux-amd64.tar.gz
$ sudo rm -rf /usr/local/go && sudo tar -C /usr/local -xzf go1.17.linux-amd64.tar.gz
$ export PATH=$PATH:/usr/local/go/bin
$ go version
go version go1.17 linux/amd64
- build CB-Spider source
$ cd $HOME/go/src/github.com/cloud-barista/cb-spider; make;
[CB-Spider] build ./interface/spctl...
[CB-Spider] build ./bin/cb-spider....
- start CB-Spider server
$ cd $CBSPIDER_ROOT/bin; ./start.sh;
[CB-Spider] Driver Plugin Mode: Static Builtin Mode
ubuntu@POWERKIM-YOGA:bin# [CB-SPIDER].[INFO]: 2021-08-22 04:06:46 nutsdb-driver.go:36, github.com/cloud-barista/cb-store/store-drivers/nutsdb-driver.initialize() - ######## dbfile: /home/ubuntu/go/src/github.com/cloud-barista/cb-spider/meta_db/dat
[CB-SPIDER].[INFO]: 2021-08-22 04:06:46 nutsdb-driver.go:36, github.com/cloud-barista/cb-store/store-drivers/nutsdb-driver.initialize() - ######## dbfile: /home/ubuntu/go/src/github.com/cloud-barista/cb-spider/meta_db/dat
[CB-SPIDER].[INFO]: 2021-08-22 04:06:46 nutsdb-driver.go:36, github.com/cloud-barista/cb-store/store-drivers/nutsdb-driver.initialize() - ######## dbfile: /home/ubuntu/go/src/github.com/cloud-barista/cb-spider/meta_db/dat
[CB-SPIDER].[INFO]: 2021-08-22 04:06:46 nutsdb-driver.go:36, github.com/cloud-barista/cb-store/store-drivers/nutsdb-driver.initialize() - ######## dbfile: /home/ubuntu/go/src/github.com/cloud-barista/cb-spider/meta_db/dat
[CB-SPIDER].[INFO]: 2021-08-22 04:06:46 nutsdb-driver.go:36, github.com/cloud-barista/cb-store/store-drivers/nutsdb-driver.initialize() - ######## dbfile: /home/ubuntu/go/src/github.com/cloud-barista/cb-spider/meta_db/dat
[CB-SPIDER].[INFO]: 2021-08-22 04:06:48 CBSpiderRuntime.go:342, github.com/cloud-barista/cb-spider/api-runtime/rest-runtime.ApiServer() - **** Rest Auth Disabled ****
<CB-Spider> Multi-Cloud Infrastructure Federation Framework
- AdminWeb: http://121.183.128.96:1024/spider/adminweb
- Swagger UI: http://121.183.128.96.123:1024/spider/api
- check the health of CB-Spider server
$ curl -sX GET http://localhost:1024/spider/cloudos |json_pp
[CB-SPIDER].[INFO]: 2021-08-22 04:07:07 CIMRest.go:28, github.com/cloud-barista/cb-spider/api-runtime/rest-runtime.ListCloudOS() - call ListCloudOS()
[CB-SPIDER].[INFO]: 2021-08-22 04:07:07 CloudOSList.go:62, github.com/cloud-barista/cb-spider/cloud-info-manager.ListCloudOS() - {[ALIBABA AWS AZURE CLOUDIT CLOUDTWIN DOCKER GCP IBM MOCK OPENSTACK]}
{"time":"2021-08-22T04:07:07.3046753+09:00","id":"","remote_ip":"127.0.0.1","host":"localhost:1024","method":"GET","uri":"/spider/cloudos","user_agent":"curl/7.68.0","status":200,"error":"","latency":435200,"latency_human":"435.2µs","bytes_in":0,"bytes_out":100}
{
"cloudos" : [
"ALIBABA",
"AWS",
"AZURE",
"CLOUDIT",
"CLOUDTWIN",
"DOCKER",
"GCP",
"IBM",
"MOCK",
"OPENSTACK"
]
}
- CB-Spider Server 운영 중인 Ubuntu의 IP 확인
$ ifconfig
eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 172.28.107.143 netmask 255.255.240.0 broadcast 172.28.111.255
inet6 fe80::215:5dff:fe5f:80a4 prefixlen 64 scopeid 0x20<link>
ether 00:15:5d:5f:80:a4 txqueuelen 1000 (Ethernet)
RX packets 352752 bytes 512305843 (512.3 MB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 42967 bytes 3450481 (3.4 MB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (Local Loopback)
RX packets 21 bytes 2060 (2.0 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 21 bytes 2060 (2.0 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
-
Service_Address 설정 방법
- Browser는 Ubutu가 아닌 host OS인 Windows에서 실행되므로, - Windows에서 접속 가능한 Ubuntu IP인 172.28.107.143로 설정
-
vi $CBSPIDER_ROOT/setup.env 에서 다음과 같이 설정
export SERVICE_ADDRESS="172.28.107.143:1024"
-
-
restart CB-Spider Server
$ cd $CBSPIDER_ROOT/bin; ./stop.sh;
$ cd $CBSPIDER_ROOT/bin; ./start.sh;
... 중략...
<CB-Spider> Multi-Cloud Infrastructure Federation Framework
- AdminWeb: http://121.183.128.96:1024/spider/adminweb
- Swagger UI: http://121.183.128.96.123:1024/spider/api
- AdminWeb 접속 테스트
- In your Browser: http://172.28.107.143:1024/spider/adminweb
-
Install & Start Guide
-
Features & Usage
-
- AdminWeb Tool Guide
- CLI Tool Guide
- REST API Guide
-
Design
-
Developer Guide
-
Cloud Driver Developer Guide
- Cloud Driver Developer Guide-WIP
- VM SSH Key Development Guide-WIP
- VM User Development Guide
- What is the CSP SDK API Version of drivers
- Region Zone Info and Driver API
- Price Info and Driver API
- (StartVM TerminateVM) API Call Counts and Waiting
- StartVM and TerminateVM Main Flow of drivers
- VM Root Disk Configuration Guide
- Security Group Rules and Driver API
- Network Load Balancer and Driver API
- VM Snapshot, MyImage and Disk Overview
- Kubernetes and Driver API(PMKS, K8S)
- Tag and Cloud Driver API
- AnyCall API Extension Guide
-
Test Reports
- v0.2.8-for-espresso-release
- v0.3.0-espresso-release
- Azure:Terminating VM
- cb-user@VM: ssh login, sudo run
- v0.3.14 test for SG Source
- v0.4.0-cafemocha-release
- Test via REST API Gateway
- Test Reports of v0.4.11 (IID2 initial Version)
- Test Reports of v0.4.12 (Register & Unregister existing Resources)
- Test Reports for v0.6.0 Release
- How to ...
- How to provision GPU VMs
- How to Resolve the 'Failed to Connect to Database' Error
- How to test CB Spider with Mock Driver
- How to install CB Spider on WSL2 under 공유기/사설망
- How to install CB Spider on macOS
- How to run CB Spider Container on macOS
- How to install OpenStack on a VM for CB Spider Testing
- How to get Azure available Regions
- How to profile memory usage in Golang
- Deprecated:How to install protoc and plugins
- [For Cloud-Migrator]