Experiment Name: Experiencing MariaDB of MariaDB on LinuxONE
Experiment Content:
1. View the system environment
2. Install MariaDB
3. Test MariaDB
Experiment Resources:
Hardware:LinuxONE
OS:Redhat 7.6
DB:MariaDB 5.5.60
Experiencing MariaDB of MariaDB on LinuxONE
The following content is displayed on the same screen for your experiment so that you can make any necessary reference in experiment. Start your experiment now!
-
View environmental information, confirm the hardware platform and operating system version
Excuting an order
1.1uname -m
Tips: Type the above command in the operation area on the right side of the window and press Enter to execute
Click()to automatically insert commands in the operation area, which is fasterConfirm that the hardware platform is s390x, s390x means that the system is based on IBM Z or LinuxONE hardware platform.
1.2cat /etc/redhat-release
Confirm that the operating system version is Red Hat 7.6 -
Install MariaDB
Excuting an order:
2.1 #yum list mariadb-server
View MariaDB installation package and installation status
2.2 #yum -y install mariadb-server
Start to install MariaDB package
2.3 #systemctl start mariadb
Start MariaDB database service
2.4 #systemctl status mariadb
Check the MariaDB service status and see the green font of active (running) indicating that the service has started successfully -
Test MariaDB
Excuting an order:
3.1 #mysql --version
View database software version
3.2 #mysql -u root
Connect to the database server
The following step commands must end with a semicolon(;)
MariaDB [(none)]>
3.3create database testdb;
Create a test database named testdb
MariaDB [(none)]>
3.4use testdb;
Select the testdb database just created
MariaDB [testdb]>
3.5create table customers (customer_id INT PRIMARY KEY, first_name TEXT, last_name TEXT);
Create a table named customers in the testdb database, and specify the column name (customer_id / first_name / lastname) and data type (INT PRIMARY KEY / TEXT) in the table
MariaDB [testdb]>
3.6show tables;
View the table just created
MariaDB [testdb]>
3.7insert into customers values (1,'Tom', 'Wang');
Insert a row of test data into the customer table
MariaDB [testdb]>
3.8select * from customers;
View the test data just inserted into the customer table
MariaDB [testdb]>
3.9exit;
Exit the database server
Contact IBM
Get the Price