Danke Fijoldar für Deine Rückantwort.
Leider hat deine Methode nicht geholfen. Die Installation der MariaDB läuft bei mir wie folgt ab:
-------------------------------------------------------------------------------------------------------------------------------------------------
[sr@srarch ~]$ sudo pacman -S mariadb
[sudo] Passwort für sr:
Löse Abhängigkeiten auf...
Suche nach in Konflikt stehenden Paketen...
Pakete (5) jemalloc-1:5.0.1-3 libevent-2.1.8-1 libmariadbclient-10.1.25-1
mariadb-clients-10.1.25-1 mariadb-10.1.25-1
Gesamtgröße der installierten Pakete: 229,23 MiB
:: Installation fortsetzen? [J/n] J
(5/5) Prüfe Schlüssel im Schlüsselring [######################] 100%
(5/5) Überprüfe Paket-Integrität [######################] 100%
(5/5) Lade Paket-Dateien [######################] 100%
(5/5) Prüfe auf Dateikonflikte [######################] 100%
(5/5) Überprüfe verfügbaren Festplattenspeicher [######################] 100%
:: Verarbeite Paketänderungen...
(1/5) Installiere libmariadbclient [######################] 100%
(2/5) Installiere jemalloc [######################] 100%
Optionale Abhängigkeiten für jemalloc
perl: for jeprof [Installiert]
(3/5) Installiere mariadb-clients [######################] 100%
(4/5) Installiere libevent [######################] 100%
Optionale Abhängigkeiten für libevent
python2: to use event_rpcgen.py [Installiert]
(5/5) Installiere mariadb [##############################################] 100%
:: You need to initialize the MariaDB data directory prior to starting
the service. This can be done with mysql_install_db command, e.g.:
mysql_install_db --user=mysql --basedir=/usr --datadir=/var/lib/mysql
Optionale Abhängigkeiten für mariadb
galera: for MariaDB cluster with Galera WSREP
perl-dbd-mysql: for mysqlhotcopy, mysql_convert_table_format and mysql_setpermission
:: Starte post-transaction hooks...
(1/3) Updating system user accounts...
(2/3) Creating temporary files...
(3/3) Arming ConditionNeedsUpdate...
[sr@srarch ~]$
-----------------------------------------------------------------------------------------------------------------------------------------
wenn ich jetzt deine Methode anwende, bekomme ich diese Meldung:
-----------------------------------------------------------------------------------------------------------------------------------------
ohne "sudo":
[sr@srarch ~]$ mysqld --initialize-insecure --usr=mysql --datadir=/var/lib/mysql/data
2017-07-23 21:41:48 140091962113984 [Note] mysqld (mysqld 10.1.25-MariaDB) starting as process 1306 ...
2017-07-23 21:41:48 140091962113984 [Warning] Can't create test file /var/lib/mysql/data/srarch.lower-test
mysqld: Can't change dir to '/var/lib/mysql/data/' (Errcode: 13 "Permission denied")
2017-07-23 21:41:48 140091962113984 [ERROR] Aborting
mit "sudo":
[sr@srarch ~]$ sudo mysqld --initialize-insecure --usr=mysql --datadir=/var/lib/mysql/data
[sudo] Passwort für sr:
2017-07-23 21:42:40 139812217794496 [Note] mysqld (mysqld 10.1.25-MariaDB) starting as process 1311 ...
2017-07-23 21:42:40 139812217794496 [Warning] Can't create test file /var/lib/mysql/data/srarch.lower-test
mysqld: Can't change dir to '/var/lib/mysql/data/' (Errcode: 2 "No such file or directory")
2017-07-23 21:42:40 139812217794496 [ERROR] Aborting
[sr@srarch ~]$
----------------------------------------------------------------------------------------------------------------------------------
Beide Vorgänge werden abgebrochen.
Wende ich die offizielle Vorgehensweise vom Wiki an, erfolgt folgende Meldung:
----------------------------------------------------------------------------------------------------------------------------------
[sr@srarch ~]$ sudo mysql_install_db --user=mysql --basedir=/usr --datadir=/var/lib/mysql
[sudo] Passwort für sr:
Installing MariaDB/MySQL system tables in '/var/lib/mysql' ...
2017-07-23 21:50:24 139860452007872 [Note] /usr/sbin/mysqld (mysqld 10.1.25-MariaDB) starting as process 1395 ...
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: innodb_empty_free_list_algorithm has been changed to legacy because of small buffer pool size. In order to use backoff, increase buffer pool at least up to 20MB.
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Using mutexes to ref count buffer pool pages
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: The InnoDB memory heap is disabled
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Compressed tables use zlib 1.2.11
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Using Linux native AIO
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Using SSE crc32 instructions
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Completed initialization of buffer pool
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Highest supported file format is Barracuda.
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: 128 rollback segment(s) are active.
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Waiting for purge to start
2017-07-23 21:50:24 139860452007872 [Note] InnoDB: Percona XtraDB (
http://www.percona.com) 5.6.36-82.0 started; log sequence number 1638576
2017-07-23 21:50:25 139859809597184 [Note] InnoDB: Dumping buffer pool(s) not yet started
OK
Filling help tables...
2017-07-23 21:50:27 140007291293632 [Note] /usr/sbin/mysqld (mysqld 10.1.25-MariaDB) starting as process 1426 ...
2017-07-23 21:50:27 140007291293632 [Note] InnoDB: innodb_empty_free_list_algorithm has been changed to legacy because of small buffer pool size. In order to use backoff, increase buffer pool at least up to 20MB.
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Using mutexes to ref count buffer pool pages
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: The InnoDB memory heap is disabled
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Compressed tables use zlib 1.2.11
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Using Linux native AIO
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Using SSE crc32 instructions
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Completed initialization of buffer pool
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Highest supported file format is Barracuda.
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: 128 rollback segment(s) are active.
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Waiting for purge to start
2017-07-23 21:50:28 140007291293632 [Note] InnoDB: Percona XtraDB (
http://www.percona.com) 5.6.36-82.0 started; log sequence number 1638586
2017-07-23 21:50:28 140006655174400 [Note] InnoDB: Dumping buffer pool(s) not yet started
OK
Creating OpenGIS required SP-s...
2017-07-23 21:50:30 140395607084992 [Note] /usr/sbin/mysqld (mysqld 10.1.25-MariaDB) starting as process 1457 ...
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: innodb_empty_free_list_algorithm has been changed to legacy because of small buffer pool size. In order to use backoff, increase buffer pool at least up to 20MB.
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Using mutexes to ref count buffer pool pages
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: The InnoDB memory heap is disabled
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Compressed tables use zlib 1.2.11
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Using Linux native AIO
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Using SSE crc32 instructions
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Completed initialization of buffer pool
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Highest supported file format is Barracuda.
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: 128 rollback segment(s) are active.
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Waiting for purge to start
2017-07-23 21:50:31 140395607084992 [Note] InnoDB: Percona XtraDB (
http://www.percona.com) 5.6.36-82.0 started; log sequence number 1638596
2017-07-23 21:50:31 140394970965760 [Note] InnoDB: Dumping buffer pool(s) not yet started
OK
To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system
PLEASE REMEMBER TO SET A PASSWORD FOR THE MariaDB root USER !
To do so, start the server, then issue the following commands:
'/usr/bin/mysqladmin' -u root password 'new-password'
'/usr/bin/mysqladmin' -u root -h srarch password 'new-password'
Alternatively you can run:
'/usr/bin/mysql_secure_installation'
which will also give you the option of removing the test
databases and anonymous user created by default. This is
strongly recommended for production servers.
See the MariaDB Knowledgebase at
http://mariadb.com/kb or the
MySQL manual for more instructions.
You can start the MariaDB daemon with:
cd '/usr' ; /usr/bin/mysqld_safe --datadir='/var/lib/mysql'
You can test the MariaDB daemon with mysql-test-run.pl
cd '/usr/mysql-test' ; perl mysql-test-run.pl
Please report any problems at
http://mariadb.org/jira
The latest information about MariaDB is available at
http://mariadb.org/.
You can find additional information about the MySQL part at:
http://dev.mysql.com
Consider joining MariaDB's strong and vibrant community:
https://mariadb.org/get-involved/
[sr@srarch ~]$
---------------------------------------------------------------------------------------------------------
Bei dieser Ausgabe finde ich aber keinen Hinweis auf das Passwort. Einzig und allein sehe ich nur den Hinweis, dass ich nicht vergessen soll, ein Root-Passwort zu setzen. Die Eingabe:
'/usr/bin/mysqladmin' -u root password 'new-password' oder
'/usr/bin/mysqladmin' -u root -h srarch password 'new-password'
lässt sich auch nicht tätigen. Bekomme dabei jedesmal eine Abweisung:
--------------------------------------------------------------------------------------------------------
[sr@srarch ~]$ '/usr/bin/mysqladmin' -u root password 'new-password'
/usr/bin/mysqladmin: connect to server at 'localhost' failed
error: 'Access denied for user 'root'@'localhost' (using password: NO)'
--------------------------------------------------------------------------------------------------------
Ich weiß einfach nicht, was ich hier falsch mache.