3.2 KiB
outline, description
| outline | description | ||
|---|---|---|---|
|
Learn how to connect to and manage MariaDB data in beOS Pro using CLI or Bytebase. |
View MariaDB data
To use MariaDB in beOS Pro, install it from Market first. This guide explains how to access and manage MariaDB data using CLI or Bytebase.
Install MariaDB service
Before connecting, install the MariaDB service from Market.
- Open Market from Launchpad and search for "MariaDB".
- Click Get, then Install, and wait for the installation to complete.
Once installed, the service and its connection details will appear in the Middleware list in Control Hub.
Get connection information
Before connecting, obtain MariaDB connection details from Control Hub.
-
Open Control Hub from Launchpad.
-
In the left navigation pane, go to Middleware and select Mariadb.
-
On the Details panel, record the following information:
- Host: Used for Bytebase connection.
- User: Used for Bytebase connection.
- Password: Used for both CLI and Bytebase.
Access via CLI
You can use the beOS Pro terminal to access the MariaDB container for debugging or data operations.
-
In Control Hub, open the beOS Pro terminal at the bottom of the left navigation pane.
-
Retrieve the Pod name for the middleware:
kubectl get pods -n mariadb-middleware -
Record the Pod name, then enter the container:
kubectl exec -it -n mariadb-middleware <mariadb-pod> -- sh -
Connect to MariaDB:
mysql -u root -p -
When prompted, enter the password you retrieved from Control Hub.
Manage via Bytebase
Bytebase provides a graphical interface for database management and schema changes.
Prerequisites
:::info MongoDB app required Bytebase uses MongoDB to store its metadata. Install MongoDB before installing Bytebase. :::
- Open Market and search for "MongoDB".
- Click Get, then Install, and wait until the service is running.
- After MongoDB is installed, search for "Bytebase" in Market.
- Click Get, then Install.
First-time setup
When launching Bytebase for the first time, you must configure an administrator account.
:::tip Remember these credentials. Only the admin account can create new database instances. :::
- Open Bytebase from Launchpad.
- Follow the on-screen prompts to set up your admin account with email and password.
Create a MariaDB instance
- Log in to Bytebase with your admin account.
- In the left navigation pane, select Instances, then click + Add Instance.
- Choose MariaDB as the database type.
- Fill in the connection fields using values from Control Hub:
- Host or Socket: Enter the Host address and do not include the port.
- Port: Keep the default, usually
3306. - Username: Enter the User value from Control Hub.
- Password: Enter the Password value from Control Hub.
- Click Test Connection to verify connectivity, then click Create.
Creating an instance in Bytebase does not create a new database. Once the instance is created, you can use the corresponding client tools to inspect and manage data.
