Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 0 additions & 10 deletions bash2_check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,18 @@ mysql --version
echo "*****************************************************************************"
sleep 6

# mysql -u root -e "show databases;"
mysql -u root <<EOT
Create user test1221@localhost identified by 'pass';
Grant all privileges on *.* to test1221@localhost identified by 'pass' with grant option;
#Grant all privileges on *.* to test1212@'%' identified by 'pass' with grant option;
#Create user 'test12'@'localhost' identified by 'pass';
#Grant Select on *.* to test12@localhost identified by 'pass';
#Grant Select on *.* to test12@'%' identified by 'pass';
Flush PRIVILEGES;
EOT
#mysql -u test12 -ppass -e "show databases;"
mysql -u test1221 -ppass -e "show grants for test1221@localhost;"
sleep 5
#mysql -u test1212 -ppass -e "show grants for test12@localhost;"
#sleep 3
mysql -u test1221 -ppass -e "use test; create table t1 ( column1 varchar(20), column2 varchar(20) );"
mysql -u test1221 -ppass -e "use test; insert into t1 (column1, column2) values ('data1', 'data2');"
mysql -u test1221 -ppass -e "use test; select * from t1;"
sleep 5
mysql -u test1221 -ppass -e "use test; drop table t1;"
mysql -u test1221 -ppass -e "show tables from test;"
#
#

echo "<< Mariadb is installed, and works. >>"