Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #247804 > unrolled thread

mariadb does not run

Started byLucio Crusca <lucio@sulweb.org>
First post2022-05-02 11:10 +0200
Last post2022-05-03 12:10 +0200
Articles 17 — 6 participants

Back to article view | Back to linux.debian.user


Contents

  mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-02 11:10 +0200
    Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-02 14:40 +0200
      Re: mariadb does not run <tomas@tuxteam.de> - 2022-05-02 15:50 +0200
        Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-02 17:40 +0200
          Re: mariadb does not run Larry Martell <larry.martell@gmail.com> - 2022-05-02 17:50 +0200
            Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-02 22:50 +0200
              Re: mariadb does not run <tomas@tuxteam.de> - 2022-05-03 07:10 +0200
                Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-03 08:40 +0200
                  Re: mariadb does not run tomas@tuxteam.de - 2022-05-03 09:50 +0200
                    Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-03 10:20 +0200
                      Re: mariadb does not run tomas@tuxteam.de - 2022-05-03 11:30 +0200
                        Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-03 11:40 +0200
                          Re: mariadb does not run tomas@tuxteam.de - 2022-05-03 12:10 +0200
                            Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-03 13:00 +0200
                              [WORKED AROUND] Re: mariadb does not run Lucio Crusca <lucio@sulweb.org> - 2022-05-03 16:30 +0200
                                Re: [WORKED AROUND] Re: mariadb does not run Greg Wooledge <greg@wooledge.org> - 2022-05-03 16:40 +0200
                          Re: mariadb does not run Stephan Seitz <stse+debian@rootsland.net> - 2022-05-03 12:10 +0200

#247804 — mariadb does not run

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-02 11:10 +0200
Subjectmariadb does not run
Message-ID<EiAe6-cEXp-9@gated-at.bofh.it>
Until yesterday I had mariadb 10.6 running on my system (bookworm/sid). 
It was behaving strangely, so I decided to stop it, uninstall it, remove 
all databases during uninstall (it's a developer system, so no real data 
to save there) and install it again.

Before reinstalling it, I checked that /var/lib/mysql did not exist 
anymore. I even manually removed /etc/mysql along with all the contained 
files and purged dbconfig-common (just in case it matters), then I 
rebooted the system and finally I installed mariadb-server with its 
dependencies using aptitude. Installation went through without errors, 
but it did not ask me to set a password for the mariadb root user (maybe 
that's ok, I'm not sure).

However now mariadb does not run anymore, complaining with:

# systemctl status mariadb
× mariadb.service - MariaDB 10.6.7 database server
      Loaded: loaded (/lib/systemd/system/mariadb.service; enabled; 
vendor preset: enabled)
      Active: failed (Result: exit-code) since Mon 2022-05-02 10:45:24 
CEST; 8min ago
        Docs: man:mariadbd(8)
              https://mariadb.com/kb/en/library/systemd/
     Process: 4879 ExecStartPre=/usr/bin/install -m 755 -o mysql -g root 
-d /var/run/mysqld (code=exited, status=0/SUCCESS)
     Process: 4880 ExecStartPre=/bin/sh -c systemctl unset-environment 
_WSREP_START_POSITION (code=exited, status=0/SUCCESS)
     Process: 4882 ExecStartPre=/bin/sh -c [ ! -e 
/usr/bin/galera_recovery ] && VAR= ||   VAR=`cd /usr/bin/..; 
/usr/bin/galera_recovery`; [ $? -eq 0 ]   && systemctl set-environment 
_WSREP_START_POSITION=$VAR || exit 1 (code=exited, status=0/SUCCESS)
     Process: 4890 ExecStart=/usr/sbin/mariadbd $MYSQLD_OPTS 
$_WSREP_NEW_CLUSTER $_WSREP_START_POSITION (code=exited, status=1/FAILURE)
    Main PID: 4890 (code=exited, status=1/FAILURE)
      Status: "MariaDB server is down"
         CPU: 136ms

mag 02 10:45:24 t470 mariadbd[4890]: 2022-05-02 10:45:24 0 [ERROR] Could 
not open mysql.plugin table: "Table 'mysql.plugin' doesn't exist". Some 
plugins may be not loaded
mag 02 10:45:24 t470 mariadbd[4890]: 2022-05-02 10:45:24 0 [ERROR] Can't 
open and lock privilege tables: Table 'mysql.servers' doesn't exist
mag 02 10:45:24 t470 mariadbd[4890]: 2022-05-02 10:45:24 0 [Note] Server 
socket created on IP: '0.0.0.0'.
mag 02 10:45:24 t470 mariadbd[4890]: 2022-05-02 10:45:24 0 [Note] Server 
socket created on IP: '::'.
mag 02 10:45:24 t470 mariadbd[4890]: 2022-05-02 10:45:24 0 [ERROR] Fatal 
error: Can't open and lock privilege tables: Table 'mysql.db' doesn't exist
mag 02 10:45:24 t470 mariadbd[4890]: 2022-05-02 10:45:24 0 [ERROR] Aborting
mag 02 10:45:24 t470 mariadbd[4890]: Warning: Memory not freed: 280
mag 02 10:45:24 t470 systemd[1]: mariadb.service: Main process exited, 
code=exited, status=1/FAILURE
mag 02 10:45:24 t470 systemd[1]: mariadb.service: Failed with result 
'exit-code'.
mag 02 10:45:24 t470 systemd[1]: Failed to start MariaDB 10.6.7 database 
server.

Any clues?

[toc] | [next] | [standalone]


#247807

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-02 14:40 +0200
Message-ID<EiDvj-cGZW-7@gated-at.bofh.it>
In reply to#247804
Il 02/05/22 12:54, mick crane ha scritto:
> I don't know anything about this but
> https://dba.stackexchange.com/questions/184283/mariadb-10-1-galera-cluster-error 
> 
> says The source of this error

Thanks but... it's not the same error, nor the same context.

[toc] | [prev] | [next] | [standalone]


#247809

From<tomas@tuxteam.de>
Date2022-05-02 15:50 +0200
Message-ID<EiEB3-cHDJ-1@gated-at.bofh.it>
In reply to#247807

[Multipart message — attachments visible in raw view] — view raw

On Mon, May 02, 2022 at 02:34:56PM +0200, Lucio Crusca wrote:
> Il 02/05/22 12:54, mick crane ha scritto:
> > I don't know anything about this but
> > https://dba.stackexchange.com/questions/184283/mariadb-10-1-galera-cluster-error
> > 
> > says The source of this error
> 
> Thanks but... it's not the same error, nor the same context.

Have you tried to start the mariadb server by hand?

Cheers
-- 
t

[toc] | [prev] | [next] | [standalone]


#247814

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-02 17:40 +0200
Message-ID<EiGjv-cIS9-1@gated-at.bofh.it>
In reply to#247809
Il 02/05/22 15:46, tomas@tuxteam.de ha scritto:
> Have you tried to start the mariadb server by hand?

Yes, I've tried with:

# mysqld_safe

but it exits almost immediately and it logs the same errors reported by 
`systemd status mariadb`

[toc] | [prev] | [next] | [standalone]


#247819

FromLarry Martell <larry.martell@gmail.com>
Date2022-05-02 17:50 +0200
Message-ID<EiGtb-cIVC-11@gated-at.bofh.it>
In reply to#247814
On Mon, May 2, 2022 at 11:38 AM Lucio Crusca <lucio@sulweb.org> wrote:
>
> Il 02/05/22 15:46, tomas@tuxteam.de ha scritto:
> > Have you tried to start the mariadb server by hand?
>
> Yes, I've tried with:
>
> # mysqld_safe
>
> but it exits almost immediately and it logs the same errors reported by
> `systemd status mariadb`

mysqld_safe is a shell script - you could try running it with sh -x to
see what it's doing and/or how it fails.

[toc] | [prev] | [next] | [standalone]


#247828

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-02 22:50 +0200
Message-ID<EiL9v-cLQ4-1@gated-at.bofh.it>
In reply to#247819
Il 02/05/22 17:43, Larry Martell ha scritto:
> mysqld_safe is a shell script - you could try running it with sh -x to
> see what it's doing and/or how it fails.

Here's to you:


# bash -x mysqld_safe
+ KILL_MYSQLD=1
+ MYSQLD=
+ niceness=0
+ nowatch=0
+ mysqld_ld_preload=
+ mysqld_ld_library_path=
+ flush_caches=0
+ numa_interleave=0
+ wsrep_on=0
+ dry_run=0
+ defaults_group_suffix=
+ logging=init
+ want_syslog=0
+ syslog_tag=
+ user=mysql
+ group=mysql
+ pid_file=
+ err_log=
+ err_log_base=
+ skip_err_log=0
+ syslog_tag_mysqld=mysqld
+ syslog_tag_mysqld_safe=mysqld_safe
+ trap '' 1 2 3 15
+ umask 007
+ UMASK=0640
++ echo 0640
++ sed -e 's/[^0246]//g'
+ fmode=0640
++ echo 0640
++ cut -c1
+ octalp=0
++ echo 0640
++ wc -c
++ sed -e 's/ //g'
+ fmlen=5
+ '[' x0 '!=' x0 -o x0640 '!=' x0640 -o x5 '!=' x5 ']'
++ cut -c3-4
++ echo 0640
+ fmode=40
+ fmode=640
+ '[' x0640 '!=' x0640 ']'
+ defaults=
+ case "$1" in
+ wsrep_start_position_opt=
++ dirname mysqld_safe
+ MY_PWD=.
++ cd ./..
++ pwd
+ MY_PWD=/
+ test -n '' -a -d ''
+ test -x //bin/mariadbd
+ test -x //libexec/mariadbd
+ test -x //sbin/mariadbd
+ MY_BASEDIR_VERSION=/
+ ledir=//sbin
++ find_in_bin mariadbd-safe-helper
++ test -x //bin/mariadbd-safe-helper
++ echo //bin/mariadbd-safe-helper
+ helper=//bin/mariadbd-safe-helper
++ find_in_bin my_print_defaults
++ test -x //bin/my_print_defaults
++ echo //bin/my_print_defaults
+ print_defaults=//bin/my_print_defaults
+ command -v //bin/mariadbd-safe-helper --help
+ helper_exist=0
+ test -d //data/mysql
+ test -d //var/mysql
+ DATADIR=/var/lib/mysql
+ test -z ''
+ test -r /var/lib/mysql/my.cnf
+ MYSQL_HOME=/
+ export MYSQL_HOME
+ args=
+ SET_USER=2
++ //bin/my_print_defaults --loose-verbose --mysqld
+ parse_arguments
+ test 2 -eq 2
+ SET_USER=0
+ unrecognized_handling=complain
++ //bin/my_print_defaults --loose-verbose mysqld_safe safe_mysqld 
mariadb_safe mariadbd-safe
+ parse_arguments
+ unrecognized_handling=collect
+ parse_arguments
+ '[' -n '' ']'
+ for dir in lib64/mysql/plugin lib64/plugin lib/mysql/plugin lib/plugin
+ '[' -d //lib64/mysql/plugin ']'
+ for dir in lib64/mysql/plugin lib64/plugin lib/mysql/plugin lib/plugin
+ '[' -d //lib64/plugin ']'
+ for dir in lib64/mysql/plugin lib64/plugin lib/mysql/plugin lib/plugin
+ '[' -d //lib/mysql/plugin ']'
+ plugin_dir=//lib/mysql/plugin
+ break
+ '[' -z //lib/mysql/plugin ']'
+ plugin_dir=//lib/mysql/plugin
+ '[' 0 -eq 1 ']'
+ '[' 0 -eq 1 ']'
+ '[' -n '' -o 0 -eq 0 ']'
+ '[' -n '' ']'
+ '[' -n '' ']'
++ uname -n
+ err_log=/var/lib/mysql/t470.err
+ append_arg_to_args --log-error=/var/lib/mysql/t470.err
++ shell_quote_string --log-error=/var/lib/mysql/t470.err
++ echo --log-error=/var/lib/mysql/t470.err
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ args=' --log-error=/var/lib/mysql/t470.err'
+ '[' 0 -eq 1 ']'
+ log_notice 'Logging to '\''/var/lib/mysql/t470.err'\''.'
+ log_generic daemon.notice 'Logging to '\''/var/lib/mysql/t470.err'\''.'
+ '[' 0 -eq 1 ']'
+ priority=daemon.notice
+ shift
++ date '+%y%m%d %H:%M:%S'
+ msg='220502 22:36:41 mysqld_safe Logging to 
'\''/var/lib/mysql/t470.err'\''.'
+ echo '220502 22:36:41 mysqld_safe Logging to 
'\''/var/lib/mysql/t470.err'\''.'
220502 22:36:41 mysqld_safe Logging to '/var/lib/mysql/t470.err'.
+ case $logging in
+ logging=file
+ USER_OPTION=
+ test -w / -o root = root
+ test mysql '!=' root -o 0 = 1
+ USER_OPTION=--user=mysql
+ GROUP_OPTION=--group=mysql
+ test -n ''
+ test -n ''
+ safe_mysql_unix_port=/run/mysqld/mysqld.sock
++ dirname /run/mysqld/mysqld.sock
+ mysql_unix_port_dir=/run/mysqld
+ '[' '!' -d /run/mysqld -a 0 -eq 0 ']'
+ test -z ''
+ MYSQLD=mariadbd
+ test '!' -x //sbin/mariadbd
+ test -z ''
++ uname -n
+ pid_file=t470.pid
+ append_arg_to_args --pid-file=t470.pid
++ shell_quote_string --pid-file=t470.pid
++ echo --pid-file=t470.pid
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ args=' --log-error=/var/lib/mysql/t470.err --pid-file=t470.pid'
+ case "$pid_file" in
+ pid_file=/var/lib/mysql/t470.pid
+ test -n ''
+ test -n ''
+ test 0 -eq 0
+ NOHUP_NICENESS=nohup
+ nohup nice
++ nice
+ normal_niceness=0
++ nohup nice
+ nohup_niceness=0
+ numeric_nice_values=1
+ for val in $normal_niceness $nohup_niceness
+ case "$val" in
+ for val in $normal_niceness $nohup_niceness
+ case "$val" in
+ test 1 -eq 1
++ expr 0 - 0
+ nice_value_diff=0
+ test 1 -eq 0
+ test -n ''
+ test -f /var/lib/mysql/t470.pid
+ true
+ test 0 -eq 1
+ test 0 -eq 1
++ mysqld_ld_preload_text
++ text=
++ '[' -n '' ']'
++ '[' -n '' ']'
++ echo ''
+ cmd=nohup
+ '[' 0 -eq 1 ']'
+ true
+ test 0 -eq 1
+ test 0 -eq 1
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string //sbin/mariadbd
++ echo //sbin/mariadbd
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd'
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string ''
++ echo ''
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd '
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string ''
++ echo ''
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd  '
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string --basedir=/
++ echo --basedir=/
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd   --basedir=/'
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string --datadir=/var/lib/mysql
++ echo --datadir=/var/lib/mysql
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql'
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string --plugin-dir=//lib/mysql/plugin
++ echo --plugin-dir=//lib/mysql/plugin
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin'
+ for i in "$ledir/$MYSQLD" "$defaults_group_suffix" "$defaults" 
"--basedir=$MY_BASEDIR_VERSION" "--datadir=$DATADIR" 
"--plugin-dir=$plugin_dir" "$USER_OPTION"
++ shell_quote_string --user=mysql
++ echo --user=mysql
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin --user=mysql'
+ cmd='nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid'
+ '[' 0 -eq 1 ']'
+ test -n nohup
+ cmd='nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid < /dev/null'
+ log_notice 'Starting mariadbd daemon with databases from /var/lib/mysql'
+ log_generic daemon.notice 'Starting mariadbd daemon with databases 
from /var/lib/mysql'
+ '[' 0 -eq 1 ']'
+ priority=daemon.notice
+ shift
++ date '+%y%m%d %H:%M:%S'
+ msg='220502 22:36:41 mysqld_safe Starting mariadbd daemon with 
databases from /var/lib/mysql'
+ echo '220502 22:36:41 mysqld_safe Starting mariadbd daemon with 
databases from /var/lib/mysql'
220502 22:36:41 mysqld_safe Starting mariadbd daemon with databases from 
/var/lib/mysql
+ case $logging in
+ '[' 0 -eq 0 ']'
+ echo '220502 22:36:41 mysqld_safe Starting mariadbd daemon with 
databases from /var/lib/mysql'
+ //bin/mariadbd-safe-helper mysql log /var/lib/mysql/t470.err
+ fast_restart=0
+ max_fast_restarts=5
+ have_sleep=1
+ expr hxB : '.*x'
+ :
+ max_wsrep_restarts=0
+ true
+ rm -f /var/lib/mysql/t470.pid
++ date +%M%S
+ start_time=3641
+ test 0 -eq 1
+ eval_log_error 'nohup //sbin/mariadbd   --basedir=/ 
--datadir=/var/lib/mysql --plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid < /dev/null'
+ local 'cmd=nohup //sbin/mariadbd   --basedir=/ 
--datadir=/var/lib/mysql --plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid < /dev/null'
+ case $logging in
+ '[' 0 -eq 0 ']'
++ shell_quote_string //bin/mariadbd-safe-helper
++ echo //bin/mariadbd-safe-helper
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
++ shell_quote_string /var/lib/mysql/t470.err
++ echo /var/lib/mysql/t470.err
++ sed -e 's,\([^a-zA-Z0-9/_.=-]\),\\\1,g'
+ cmd='nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid < /dev/null 2>&1 
| //bin/mariadbd-safe-helper mysql log /var/lib/mysql/t470.err'
+ test 0 -eq 1
+ eval 'nohup //sbin/mariadbd   --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid < /dev/null 2>&1 
| //bin/mariadbd-safe-helper mysql log /var/lib/mysql/t470.err'
++ nohup //sbin/mariadbd --basedir=/ --datadir=/var/lib/mysql 
--plugin-dir=//lib/mysql/plugin --user=mysql 
--log-error=/var/lib/mysql/t470.err --pid-file=t470.pid
++ //bin/mariadbd-safe-helper mysql log /var/lib/mysql/t470.err
++ date +%M%S
+ end_time=3641
+ test '!' -f /var/lib/mysql/t470.pid
+ break
+ log_notice 'mysqld from pid file /var/lib/mysql/t470.pid ended'
+ log_generic daemon.notice 'mysqld from pid file 
/var/lib/mysql/t470.pid ended'
+ '[' 0 -eq 1 ']'
+ priority=daemon.notice
+ shift
++ date '+%y%m%d %H:%M:%S'
+ msg='220502 22:36:41 mysqld_safe mysqld from pid file 
/var/lib/mysql/t470.pid ended'
+ echo '220502 22:36:41 mysqld_safe mysqld from pid file 
/var/lib/mysql/t470.pid ended'
220502 22:36:41 mysqld_safe mysqld from pid file /var/lib/mysql/t470.pid 
ended
+ case $logging in
+ '[' 0 -eq 0 ']'
+ echo '220502 22:36:41 mysqld_safe mysqld from pid file 
/var/lib/mysql/t470.pid ended'
+ //bin/mariadbd-safe-helper mysql log /var/lib/mysql/t470.err


Seems to me the script is doing what it is supposed to do, but mariadb 
exits immediately.

[toc] | [prev] | [next] | [standalone]


#247836

From<tomas@tuxteam.de>
Date2022-05-03 07:10 +0200
Message-ID<EiSXn-cR3z-1@gated-at.bofh.it>
In reply to#247828

[Multipart message — attachments visible in raw view] — view raw

On Mon, May 02, 2022 at 10:44:58PM +0200, Lucio Crusca wrote:
> Il 02/05/22 17:43, Larry Martell ha scritto:
> > mysqld_safe is a shell script - you could try running it with sh -x to
> > see what it's doing and/or how it fails.
> 
> Here's to you:
> 

According to this huge mess, the log file is somewhere in
/var/lib/mysql/t470.err (the number '470' is the process
ID, aka PID, so it will change at every start).

Have you had a look at this?

Cheers
-- 
t

[toc] | [prev] | [next] | [standalone]


#247837

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-03 08:40 +0200
Message-ID<EiUmt-cRP0-13@gated-at.bofh.it>
In reply to#247836
Il 03/05/22 07:04, tomas@tuxteam.de ha scritto:
> According to this huge mess, the log file is somewhere in
> /var/lib/mysql/t470.err (the number '470' is the process
> ID, aka PID, so it will change at every start).
> 

Actually t470 is my hostname so it stays the same.

I had already looked at that logfile and I had already written here that 
the error messages in that logfile are the same of those shown by 
`systemctl status mariadb`:

https://lists.debian.org/debian-user/2022/05/msg00041.html

which are reported in my first post:

https://lists.debian.org/debian-user/2022/05/msg00027.html

but english is not my native language, maybe I did not express myself 
clearly enough. I hope it's now clear.

[toc] | [prev] | [next] | [standalone]


#247840

Fromtomas@tuxteam.de
Date2022-05-03 09:50 +0200
Message-ID<EiVsd-cSqE-7@gated-at.bofh.it>
In reply to#247837

[Multipart message — attachments visible in raw view] — view raw

On Tue, May 03, 2022 at 08:39:12AM +0200, Lucio Crusca wrote:
> Il 03/05/22 07:04, tomas@tuxteam.de ha scritto:
> > According to this huge mess, the log file is somewhere in
> > /var/lib/mysql/t470.err (the number '470' is the process
> > ID, aka PID, so it will change at every start).
> > 
> 
> Actually t470 is my hostname so it stays the same.

Ah, got it, thanks.

> I had already looked at that logfile and I had already written here that the
> error messages in that logfile are the same of those shown by `systemctl
> status mariadb`:
> 
> https://lists.debian.org/debian-user/2022/05/msg00041.html
> 
> which are reported in my first post:
> 
> https://lists.debian.org/debian-user/2022/05/msg00027.html
> 
> but english is not my native language, maybe I did not express myself
> clearly enough. I hope it's now clear.

Sorry I missed that. It's most probably my bad attention spam,
not your English. That one is no worse than mine :-)

Looking at the mariadb entry in my process list (Debian Bullseye),
I see (breaking up the long line at spaces):

  mysql     2473  0.0  0.6 1608036 98724 ?       Sl   06:15   0:03
        /usr/sbin/mariadbd --basedir=/usr --datadir=/var/lib/mysql
          --plugin-dir=/usr/lib/mysql/plugin --user=mysql
          --skip-log-error --pid-file=/run/mysqld/mysqld.pid
          --socket=/run/mysqld/mysqld.sock

If I've read the output of your "-x" run correctly, it's trying
to start with "--basedir=/" instead of /usr. This, at least, looks
fishy to me.

Any chance you could try to run a command line as above and see
whether the daemon likes to start?

This would give us something to bisect the problem.

Cheers
-- 
t

[toc] | [prev] | [next] | [standalone]


#247841

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-03 10:20 +0200
Message-ID<EiVVg-cSQN-3@gated-at.bofh.it>
In reply to#247840
Il 03/05/22 09:47, tomas@tuxteam.de ha scritto:
> Any chance you could try to run a command line as above and see
> whether the daemon likes to start?

  # /usr/sbin/mariadbd --basedir=/usr --datadir=/var/lib/mysql 
--plugin-dir=/usr/lib/mysql/plugin --user=mysql --skip-log-error 
--pid-file=/run/mysqld/mysqld.pid --socket=/run/mysqld/mysqld.sock
2022-05-03 10:12:21 0 [Note] /usr/sbin/mariadbd (server 
10.6.7-MariaDB-3) starting as process 47102 ...
2022-05-03 10:12:21 0 [Note] InnoDB: Compressed tables use zlib 1.2.11
2022-05-03 10:12:21 0 [Note] InnoDB: Number of pools: 1
2022-05-03 10:12:21 0 [Note] InnoDB: Using crc32 + pclmulqdq instructions
2022-05-03 10:12:21 0 [Note] InnoDB: Using liburing
2022-05-03 10:12:21 0 [Note] InnoDB: Initializing buffer pool, total 
size = 134217728, chunk size = 134217728
2022-05-03 10:12:21 0 [Note] InnoDB: Completed initialization of buffer pool
2022-05-03 10:12:21 0 [Note] InnoDB: 128 rollback segments are active.
2022-05-03 10:12:21 0 [Note] InnoDB: Creating shared tablespace for 
temporary tables
2022-05-03 10:12:21 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 
MB. Physically writing the file full; Please wait ...
2022-05-03 10:12:21 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB.
2022-05-03 10:12:21 0 [Note] InnoDB: 10.6.7 started; log sequence number 
33110; transaction id 4
2022-05-03 10:12:21 0 [Note] InnoDB: Loading buffer pool(s) from 
/var/lib/mysql/ib_buffer_pool
2022-05-03 10:12:21 0 [Note] Plugin 'FEEDBACK' is disabled.
2022-05-03 10:12:21 0 [ERROR] Could not open mysql.plugin table: "Table 
'mysql.plugin' doesn't exist". Some plugins may be not loaded
2022-05-03 10:12:21 0 [Note] InnoDB: Buffer pool(s) load completed at 
220503 10:12:21
2022-05-03 10:12:21 0 [ERROR] Can't open and lock privilege tables: 
Table 'mysql.servers' doesn't exist
2022-05-03 10:12:21 0 [Note] Server socket created on IP: '0.0.0.0'.
2022-05-03 10:12:21 0 [Note] Server socket created on IP: '::'.
2022-05-03 10:12:21 0 [ERROR] Fatal error: Can't open and lock privilege 
tables: Table 'mysql.db' doesn't exist
2022-05-03 10:12:21 0 [ERROR] Aborting
Warning: Memory not freed: 280

> This would give us something to bisect the problem.

I'm afraid it does not, at least it does not give me anything, since it 
shows the same error messages as before.

[toc] | [prev] | [next] | [standalone]


#247844

Fromtomas@tuxteam.de
Date2022-05-03 11:30 +0200
Message-ID<EiX0Z-cTsm-3@gated-at.bofh.it>
In reply to#247841

[Multipart message — attachments visible in raw view] — view raw

On Tue, May 03, 2022 at 10:14:55AM +0200, Lucio Crusca wrote:
> Il 03/05/22 09:47, tomas@tuxteam.de ha scritto:
> > Any chance you could try to run a command line as above and see
> > whether the daemon likes to start?
> 
>  # /usr/sbin/mariadbd --basedir=/usr --datadir=/var/lib/mysql
> --plugin-dir=/usr/lib/mysql/plugin --user=mysql --skip-log-error
> --pid-file=/run/mysqld/mysqld.pid --socket=/run/mysqld/mysqld.sock

[...]

> 2022-05-03 10:12:21 0 [ERROR] Could not open mysql.plugin table: "Table
> 'mysql.plugin' doesn't exist". Some plugins may be not loaded

[...]

> 2022-05-03 10:12:21 0 [ERROR] Can't open and lock privilege tables: Table
> 'mysql.servers' doesn't exist

[...]

> 2022-05-03 10:12:21 0 [ERROR] Fatal error: Can't open and lock privilege
> tables: Table 'mysql.db' doesn't exist

> I'm afraid it does not, at least it does not give me anything, since it
> shows the same error messages as before.

...but at least those seem clearer now to my slow brain :)

The way I interpret this is that mysql isn't finding some tables
it expects at start (possibly parts of the metaschema). I'd expect
those to come along with a new installation. Perhaps something went
astray during your last attempt.

Perhaps uninstalling your mariadb server and re-installing it
seems the best way forward (I think to remember you said you had
no valuable data).

Try `sudo apt purge mariadb-server', watch out for error messages,
then re-install. Perhaps that helps.

Cheers
-- 
tomás

[toc] | [prev] | [next] | [standalone]


#247845

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-03 11:40 +0200
Message-ID<EiXaF-cTvl-3@gated-at.bofh.it>
In reply to#247844
Il 03/05/22 11:28, tomas@tuxteam.de  scritto:
> Try `sudo apt purge mariadb-server', watch out for error messages,
> then re-install. Perhaps that helps.

I didn't mention that in my first post, but I've already tried purging 
and reinstalling several times. The one I reported is only the last one, 
e.g. the more comprehensive one that included manual removal of 
/etc/mysql and reboot before reinstalling. I always got the same results.

[toc] | [prev] | [next] | [standalone]


#247847

Fromtomas@tuxteam.de
Date2022-05-03 12:10 +0200
Message-ID<EiXDI-cTYl-3@gated-at.bofh.it>
In reply to#247845

[Multipart message — attachments visible in raw view] — view raw

On Tue, May 03, 2022 at 11:39:12AM +0200, Lucio Crusca wrote:
> Il 03/05/22 11:28, tomas@tuxteam.de  scritto:
> > Try `sudo apt purge mariadb-server', watch out for error messages,
> > then re-install. Perhaps that helps.
> 
> I didn't mention that in my first post, but I've already tried purging and
> reinstalling several times. The one I reported is only the last one, e.g.
> the more comprehensive one that included manual removal of /etc/mysql and
> reboot before reinstalling. I always got the same results.

This is strange. What does dpkg -l "*mariadb*" say?

Cheers
-- 
t

[toc] | [prev] | [next] | [standalone]


#247850

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-03 13:00 +0200
Message-ID<EiYq5-cUik-5@gated-at.bofh.it>
In reply to#247847
Il 03/05/22 12:05, tomas@tuxteam.de ha scritto:
> What does dpkg -l "*mariadb*" say?

# LANG=en dpkg -l "*mariadb*" | grep ^ii
ii  libdbd-mariadb-perl        1.22-1       amd64        Perl5 database 
interface to the MariaDB/MySQL databases
ii  libmariadb3:amd64          1:10.6.7-3   amd64        MariaDB 
database client library
ii  mariadb-client             1:10.6.7-3   all          MariaDB 
database client (metapackage depending on the latest version)
ii  mariadb-client-10.6        1:10.6.7-3   amd64        MariaDB 
database client binaries
ii  mariadb-client-core-10.6   1:10.6.7-3   amd64        MariaDB 
database core client binaries
ii  mariadb-common             1:10.6.7-3   all          MariaDB common 
configuration files
ii  mariadb-server             1:10.6.7-3   all          MariaDB 
database server (metapackage depending on the latest version)
ii  mariadb-server-10.6        1:10.6.7-3   amd64        MariaDB 
database server binaries
ii  mariadb-server-core-10.6   1:10.6.7-3   amd64        MariaDB 
database core server files



Il 03/05/22 11:58, Stephan Seitz ha scritto:
 > Make sure that /var/lib/mysql is empty as well after the purge.

Already checked: it's more than empty, it does not exist anymore and it 
gets created again upon reinstall.

[toc] | [prev] | [next] | [standalone]


#247852 — [WORKED AROUND] Re: mariadb does not run

FromLucio Crusca <lucio@sulweb.org>
Date2022-05-03 16:30 +0200
Subject[WORKED AROUND] Re: mariadb does not run
Message-ID<Ej1Hj-cWv8-1@gated-at.bofh.it>
In reply to#247850
I ended up installing MariaDB 10.8 using the MariaDB unofficial Debian 
repository and it works...

That makes me suspect there's a problem with the official
mariadb-server-core-10.6 Debian package, but it's very strange no such 
bug has been filed yet (how could that happen only to me?).

Unfortunately I cannot afford keeping my dev system unusable for the 
time required to assist maintainers in bisecting the problem. Besides 
I'm on Sid, so such bugs are to be expected from time to time.

Thanks anyway for your assistance.

[toc] | [prev] | [next] | [standalone]


#247853 — Re: [WORKED AROUND] Re: mariadb does not run

FromGreg Wooledge <greg@wooledge.org>
Date2022-05-03 16:40 +0200
SubjectRe: [WORKED AROUND] Re: mariadb does not run
Message-ID<Ej1R0-cWy8-13@gated-at.bofh.it>
In reply to#247852
On Tue, May 03, 2022 at 04:26:13PM +0200, Lucio Crusca wrote:
> That makes me suspect there's a problem with the official
> mariadb-server-core-10.6 Debian package, but it's very strange no such bug
> has been filed yet (how could that happen only to me?).

For any given bug, *someone* has to be the first to encounter it.  If this
particular bug only happens on new installs of the package, and not on
upgrades from stable, it makes sense that relatively few people running
unstable/testing would encounter it.

(Most people running unstable/testing would have already had mariadb
installed and running from an older version, so this would just be an
upgrade.  Also, relatively few people who run a mariadb server would be
using unstable/testing.  One doesn't typically run a database on an
unstable platform, outside of development situations.)

[toc] | [prev] | [next] | [standalone]


#247848

FromStephan Seitz <stse+debian@rootsland.net>
Date2022-05-03 12:10 +0200
Message-ID<EiXDI-cTYl-13@gated-at.bofh.it>
In reply to#247845
Am Di, Mai 03, 2022 at 11:39:12 +0200 schrieb Lucio Crusca:
>Il 03/05/22 11:28, tomas@tuxteam.de  scritto:
>>Try `sudo apt purge mariadb-server', watch out for error messages,
>>then re-install. Perhaps that helps.
>I didn't mention that in my first post, but I've already tried purging 
>and reinstalling several times. The one I reported is only the last one, 

The package mariadb-server is a meta package. It depends on the current 
version of the server package, e.g. mariadb-server-10.5.

>e.g. the more comprehensive one that included manual removal of 
>/etc/mysql and reboot before reinstalling. I always got the same 
>results.

Make sure that /var/lib/mysql is empty as well after the purge.

	Stephan

-- 
|    If your life was a horse, you'd have to shoot it.    |

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.user


csiph-web