A package for GBase 8s database installation and cluster setup.
Project description
pygbase8s
介绍
提供gbase8s数据库及相关产品的安装部署、实例、集群配置等功能
安装教程
pip install pygbase8s
使用说明
from pygbase8s.machine import RemoteMachine
# 创建一个服务器实例
machine = RemoteMachine(ip='xxx.xxx.xxx.xxx', password='root_password')
from pygbase8s.product import IDS
# 指定数据库目录
ids = IDS(path="/opt/gbase8s", machine=machine)
# 安装数据库
ids.install(pkg_path="/data/GBase8sxxx.tar")
from pygbase8s.server_pool import ServerPool
# 初始化实例池
pool = ServerPool(ids=ids, count=5)
pool.initialize()
# 从实例池获取一个实例并初始化
server = pool.get_server()
server.initialize()
# 从实例池获取一个SDS集群并初始化
cluster = pool.get_cluster('sds')
cluster.initialize()
# 给集群配置CM
from pygbase8s.cm import CM
from pygbase8s.product import CSDK
csdk = CSDK(path="/opt/gbase8s", machine=machine)
csdk.install('/data/ClientSDKxxx.tar')
cm = CM(csdk=csdk, cluster=cluster)
cm.startup()
参与贡献
- Fork 本仓库
- 新建 Feat_xxx 分支
- 提交代码
- 新建 Pull Request
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
pygbase8s-0.0.1-py3-none-any.whl
(14.9 kB
view details)
File details
Details for the file pygbase8s-0.0.1-py3-none-any.whl.
File metadata
- Download URL: pygbase8s-0.0.1-py3-none-any.whl
- Upload date:
- Size: 14.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.8.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b0c8768f946512e5f54b3954e4cc5889c0254ba9141e1b91f9c83c49ffdb6591
|
|
| MD5 |
2bded75cc3510addc774c680b42ca0b5
|
|
| BLAKE2b-256 |
e9be469071ff3b58429ff2bd3241a5b0f0a19c5dd4b1e9cea29469a6749682ad
|