[slurm-users] mariadb refusing access

52 views
Skip to first unread message

Steven Jones via slurm-users

unread,
Mar 4, 2025, 8:25:55 PM3/4/25
to slurm...@schedmd.com
In the logs I am seeing,

root@vuwunicoslurmd3 mariadb]# tail -f mariadb.log
2025-03-04 19:01:32 12565 [Warning] Access denied for user 'slurm'@'localhost' (using password: YES)
2025-03-04 19:06:19 12566 [Warning] Access denied for user 'slurm'@'localhost' (using password: YES)

However   mysql -u slurm -p   works just fine so it seems to be a config error for slurmdbd

Any ideas please?

regards

Steven

Christopher Samuel via slurm-users

unread,
Mar 4, 2025, 8:53:49 PM3/4/25
to slurm...@lists.schedmd.com
On 3/4/25 5:23 pm, Steven Jones via slurm-users wrote:

> However   mysql -u slurm -p   works just fine so it seems to be a config
> error for slurmdbd

Try:

mysql -h 127.0.0.1 -u slurm -p

IIRC without that it'll try a UNIX domain socket and not try and connect
via TCP/IP.

--
Chris Samuel : http://www.csamuel.org/ : Berkeley, CA, USA

--
slurm-users mailing list -- slurm...@lists.schedmd.com
To unsubscribe send an email to slurm-us...@lists.schedmd.com

Steven Jones via slurm-users

unread,
Mar 4, 2025, 9:06:22 PM3/4/25
to slurm...@lists.schedmd.com, Christopher Samuel
I had already tried that but here it is, looks OK to me.

======
[root@vuwunicoslurmd3 slurm]# mysql -h 127.0.0.1 -u slurm -p
Enter password:
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 12583
Server version: 10.11.10-MariaDB MariaDB Server

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| slurm_acct_db      |
+--------------------+
2 rows in set (0.000 sec)

MariaDB [(none)]>
========

regards

Steven 


From: Christopher Samuel via slurm-users <slurm...@lists.schedmd.com>
Sent: Wednesday, 5 March 2025 2:51 pm
To: slurm...@lists.schedmd.com <slurm...@lists.schedmd.com>
Subject: [slurm-users] Re: mariadb refusing access
 
On 3/4/25 5:23 pm, Steven Jones via slurm-users wrote:

> However   mysql -u slurm -p   works just fine so it seems to be a config
> error for slurmdbd

Try:

mysql -h 127.0.0.1 -u slurm -p

IIRC without that it'll try a UNIX domain socket and not try and connect
via TCP/IP.

--

Ole Holm Nielsen via slurm-users

unread,
Mar 5, 2025, 3:27:55 AM3/5/25
to slurm...@lists.schedmd.com
It seems that you didn't select a suitable slurm user’s database password,
see
https://wiki.fysik.dtu.dk/Niflheim_system/Slurm_database/#set-up-mariadb-database

IHTH,
Ole

Sébastien VIGNERON via slurm-users

unread,
Mar 5, 2025, 11:48:10 AM3/5/25
to Steven Jones, slurm...@lists.schedmd.com, Christopher Samuel
Hi,

Check your /etc/hosts file for localhost definition. I would guess it is not only 127.0.0.1.
I think you have IPv6 ::1 address too.

If so, try connect using 172.0.0.1 and add a GRANT with the same password for 'slurm'@'::1';
That will allow connections using IPv4 and IPv6 loopback address.

Cordialement / Best regards,

Sébastien VIGNERON
CRIANN,
Ingénieur / Engineer
Technopôle du Madrillet
745, avenue de l'Université
76800 Saint-Etienne du Rouvray - France
tél.☎️ +33 2 32 91 42 91
fax. +33 2 32 91 42 92
http://www.criann.fr
mailto:sebastien...@criann.fr
support: sup...@criann.fr

> Le 5 mars 2025 à 03:04, Steven Jones via slurm-users <slurm...@lists.schedmd.com> a écrit :
>
> I had already tried that but here it is, looks OK to me.
>
> ======
> [root@vuwunicoslurmd3 slurm]# mysql -h 127.0.0.1 -u slurm -p
> Enter password:
> Welcome to the MariaDB monitor. Commands end with ; or \g.
> Your MariaDB connection id is 12583
> Server version: 10.11.10-MariaDB MariaDB Server
>
> Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
>
> Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
>
> MariaDB [(none)]> show databases;
> +--------------------+
> | Database |
> +--------------------+
> | information_schema |
> | slurm_acct_db |
> +--------------------+
> 2 rows in set (0.000 sec)
>
> MariaDB [(none)]>
> ========
>
> regards
> Steven

Steven Jones via slurm-users

unread,
Mar 5, 2025, 1:38:34 PM3/5/25
to Sébastien VIGNERON, slurm...@lists.schedmd.com, Christopher Samuel
Hi,

[root@vuwunicoslurmd3 ~]# cat /etc/hosts
127.0.0.1   localhost localhost.localdomain localhost4 localhost4.localdomain4
::1         localhost localhost.localdomain localhost6 localhost6.localdomain6
130.195.19.159  vuwunicoslurmd3.ods.vuw.ac.nz vuwunicoslurmd3
[root@vuwunicoslurmd3 ~]#


regards

Steven



From: Sébastien VIGNERON <sebastien...@criann.fr>
Sent: Wednesday, 5 March 2025 9:29 pm
To: Steven Jones <steven...@vuw.ac.nz>
Cc: slurm...@lists.schedmd.com <slurm...@lists.schedmd.com>; Christopher Samuel <ch...@csamuel.org>
Subject: Re: [slurm-users] mariadb refusing access
 
[You don't often get email from sebastien...@criann.fr. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]


Hi,

Check your /etc/hosts file for localhost definition. I would guess it is not only 127.0.0.1.
I think you have IPv6 ::1 address too.

If so, try connect using 172.0.0.1 and add a GRANT with the same password for 'slurm'@'::1';
That will allow connections using IPv4 and IPv6 loopback address.

Cordialement / Best regards,

Sébastien VIGNERON
CRIANN,
Ingénieur / Engineer
Technopôle du Madrillet
745, avenue de l'Université
76800 Saint-Etienne du Rouvray - France
tél.☎️ +33 2 32 91 42 91
fax. +33 2 32 91 42 92

Steven Jones via slurm-users

unread,
Mar 5, 2025, 1:41:16 PM3/5/25
to slurm...@lists.schedmd.com, Ole Holm Nielsen
Sorry, I dont follow you,

Pass word works fine and grant looks OK.

[root@vuwunicoslurmd3 ~]# mysql -u slurm -p
Enter password:
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 208
Server version: 10.11.10-MariaDB MariaDB Server

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]> show grants;
+--------------------------------------------------------------------------------------------------------------+
| Grants for slurm@localhost                                                                                   |
+--------------------------------------------------------------------------------------------------------------+
| GRANT USAGE ON *.* TO `slurm`@`localhost` IDENTIFIED BY PASSWORD '*2F4EEC707189D8B5E329829B9303058EF7585569' |
| GRANT ALL PRIVILEGES ON `slurm_acct_db`.* TO `slurm`@`localhost`                                             |
+--------------------------------------------------------------------------------------------------------------+
2 rows in set (0.000 sec)

MariaDB [(none)]> 

Isnt there something about password encryption / password hash?




regards

Steven 



From: Ole Holm Nielsen via slurm-users <slurm...@lists.schedmd.com>
Sent: Wednesday, 5 March 2025 9:25 pm

To: slurm...@lists.schedmd.com <slurm...@lists.schedmd.com>
Subject: [slurm-users] Re: mariadb refusing access
On 3/5/25 02:23, Steven Jones via slurm-users wrote:
> In the logs I am seeing,
>
> root@vuwunicoslurmd3 mariadb]# tail -f mariadb.log
> 2025-03-04 19:01:32 12565 [Warning] Access denied for user
> 'slurm'@'localhost' (using password: YES)
> 2025-03-04 19:06:19 12566 [Warning] Access denied for user
> 'slurm'@'localhost' (using password: YES)
>
> However   mysql -u slurm -p   works just fine so it seems to be a config
> error for slurmdbd

It seems that you didn't select a suitable slurm user’s database password,
see

Steven Jones via slurm-users

unread,
Mar 5, 2025, 1:52:29 PM3/5/25
to slurm...@lists.schedmd.com
Yes that is set, and my settings are,

# slurmDBD info
DbdAddr=localhost
#DbdHost=localhost
DbdPort=6819
SlurmUser=slurm
#MessageTimeout=300
DebugLevel=verbose
#DefaultQOS=normal,standby
LogFile=/var/log/slurm/slurmdbd.log
PidFile=/var/run/slurmdbd/slurmdbd.pid
#PluginDir=/usr/lib/slurm
#PrivateData=accounts,users,usage,jobs
#TrackWCKey=yes
#
# Database info
StorageType=accounting_storage/mysql
#StorageHost=localhost
StorageHost=localhost
#StoragePort=1234
#StoragePort=3306
StoragePass=xxxxxxxx
StorageUser=slurm
StorageLoc=slurm_acct_db
#ssj


regards

Steven 



From: Sarlo, Jeffrey S <JSa...@Central.UH.EDU>
Sent: Thursday, 6 March 2025 7:42 am
To: Steven Jones <steven...@vuw.ac.nz>
Subject: RE: [slurm-users] Re: mariadb refusing access
 
You don't often get email from jsa...@central.uh.edu. Learn why this is important

Do you have the correct password listed in the slurmdbd.conf file?  That was toward the bottom of the Wiki that Ole sent.

 

Jeff

Steven Jones via slurm-users

unread,
Mar 5, 2025, 4:06:11 PM3/5/25
to slurm...@lists.schedmd.com, Steven Jones
The password ended in a !

Once removed it connects OK.  doh.


regards

Steven 



From: Steven Jones via slurm-users <slurm...@lists.schedmd.com>
Sent: Thursday, 6 March 2025 7:49 am
Reply all
Reply to author
Forward
0 new messages