How to get mysqy/mariadb to start on powerup.
I'm building an RPi3 system that is going to use mysql/mariadb. I've got everything installed, but mysqld is not starting. install_db.service does run on startup, but the mysqld.service file never gets triggered.
Is there something that I'm missing to get it to run? I've search online, but can't find anything that pertains to yocto.
Regards,
Greg Wilson-Lindberg
Quoted 8 lines · Greg Wilson-Lindberg
I'm building an RPi3 system that is going to use mysql/mariadb. I've got everything installed, but mysqld is not starting. install_db.service does run on startup, but the mysqld.service file never gets triggered.
Is there something that I'm missing to get it to run? I've search online, but can't find anything that pertains to yocto.
poke on the system with systemctl/journalctl to see whats going on
Quoted 14 lines
From: Khem Raj <[email protected]>
Sent: Thursday, March 15, 2018 1:54 PM
To: Greg Wilson-Lindberg
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 1 line
On Thu, Mar 15, 2018 at 1:38 PM, Greg Wilson-Lindberg
Quoted 5 lines · <[email protected]> wrote:
I'm building an RPi3 system that is going to use mysql/mariadb. I've got everything installed, but mysqld is not starting. install_db.service does run on startup, but the mysqld.service file never gets triggered.
Quoted 5 lines
Quoted 3 lines
Is there something that I'm missing to get it to run? I've search online, but can't find anything that pertains to yocto.
poke on the system with systemctl/journalctl to see whats going on
journalctl -u mysqld.service says no entries
systemctl status mysqld.service shows:
Loaded: loaded (/lib/systemd/system/mysqld.service; disabled; vendor preset: enabled)
Active: inactive (dead)
I've rebooted the system a couple of times to see if install_db needed to be run before mysql would run, no luck.
Quoted 24 lines
From: Greg Wilson-Lindberg
Sent: Thursday, March 15, 2018 02:16 PM
To: Khem Raj <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 17 lines
From: Khem Raj <[email protected]<mailto:[email protected]>>
Sent: Thursday, March 15, 2018 1:54 PM
To: Greg Wilson-Lindberg
Cc: [email protected]<mailto:[email protected]>
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 1 line
On Thu, Mar 15, 2018 at 1:38 PM, Greg Wilson-Lindberg
Quoted 8 lines · <[email protected]<mailto:[email protected]>> wrote:
I'm building an RPi3 system that is going to use mysql/mariadb. I've got everything installed, but mysqld is not starting. install_db.service does run on startup, but the mysqld.service file never gets triggered.
Is there something that I'm missing to get it to run? I've search online, but can't find anything that pertains to yocto.
Quoted 9 lines
Quoted 1 line
poke on the system with systemctl/journalctl to see whats going on
journalctl -u mysqld.service says no entries
systemctl status mysqld.service shows:
Loaded: loaded (/lib/systemd/system/mysqld.service; disabled; vendor preset: enabled)
Active: inactive (dead)I've rebooted the system a couple of times to see if
install_dbneeded to be run before mysql would run, no luck.
It's seems that maybe I need to add a bit about my understanding of the yocto system. I was assuming that if I included mysql in the build, that it would be started when the system powered up. If mysql is not normally started automatically that I can do what is necessary to start it, I just thought that I shouldn't need to do anything.
Greg
Quoted 51 lines · Greg Wilson-Lindberg
Quoted 42 lines
From: Greg Wilson-Lindberg
Sent: Thursday, March 15, 2018 02:16 PM
To: Khem Raj <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 18 lines
From: Khem Raj <[email protected]>
Sent: Thursday, March 15, 2018 1:54 PM
To: Greg Wilson-Lindberg
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 1 line
On Thu, Mar 15, 2018 at 1:38 PM, Greg Wilson-Lindberg
Quoted 7 lines · <[email protected]> wrote:
I'm building an RPi3 system that is going to use mysql/mariadb. I've got
everything installed, but mysqld is not starting. install_db.service does
run on startup, but the mysqld.service file never gets triggered.Quoted 6 lines
Quoted 4 lines
Is there something that I'm missing to get it to run? I've search online,
but can't find anything that pertains to yocto.poke on the system with systemctl/journalctl to see whats going on
journalctl -u mysqld.service says no entries
systemctl status mysqld.service shows:
Loaded: loaded (
/lib/systemd/system/mysqld.service; disabled; vendor
preset: enabled)Quoted 8 lines
Active: inactive (dead)
I've rebooted the system a couple of times to see if
install_dbneeded to be run before mysql would run, no luck.
Quoted 5 lines
It's seems that maybe I need to add a bit about my understanding of the yocto system. I was assuming that if I included mysql in the build, that it would be started when the system powered up. If mysql is not normally started automatically that I can do what is necessary to start it, I just thought that I shouldn't need to do anything.
Yes you are right. We try to do runtime testing as much as possible and you will see more and more focus on runtime testing in coming days and months. So far we have had lot of build related features and stability problems to work on so chances
of runtime bugs are still a bit higher. You can help in fixing this issue if you can root
cause it. eg. check in system logs using journalctl for possible causes of this service
not starting up. Often times you will get a decent hint and we can help as well on
that information
Quoted 65 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 11:55 AM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 50 lines · Greg Wilson-Lindberg
Quoted 41 lines
From: Greg Wilson-Lindberg
Sent: Thursday, March 15, 2018 02:16 PM
To: Khem Raj <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 17 lines
From: Khem Raj <[email protected]>
Sent: Thursday, March 15, 2018 1:54 PM
To: Greg Wilson-Lindberg
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 1 line
On Thu, Mar 15, 2018 at 1:38 PM, Greg Wilson-Lindberg
Quoted 6 lines · <[email protected]> wrote:
I'm building an RPi3 system that is going to use mysql/mariadb. I've got everything installed, but mysqld is not starting. install_db.service does run on startup, but the mysqld.service file never gets triggered.
Quoted 5 lines
Quoted 3 lines
Is there something that I'm missing to get it to run? I've search online, but can't find anything that pertains to yocto.
poke on the system with systemctl/journalctl to see whats going on
journalctl -u mysqld.service says no entries
systemctl status mysqld.service shows:
Loaded: loaded (/lib/systemd/system/mysqld.service; disabled;vendor
preset: enabled)Quoted 8 lines
Active: inactive (dead)
I've rebooted the system a couple of times to see if
install_dbneeded to be run before mysql would run, no luck.Quoted 5 lines
It's seems that maybe I need to add a bit about my understanding of the yocto system. I was assuming that if I included mysql in the build, that it would be started when the system powered up. If mysql is not normally started automatically that I can do what is necessary to start it, I just thought that I shouldn't need to do anything.
Quoted 7 lines
Yes you are right. We try to do runtime testing as much as possible and you will see more and more focus on runtime testing in coming days and months. So far we have had lot of build related features and stability problems to work on so chances of runtime bugs are still a bit higher. You can help in fixing this issue if you can root cause it. eg. check in system logs using journalctl for possible causes of this service not starting up. Often times you will get a decent hint and we can help as well on that information
I've run journalctl on both install_db.service & mysqld.service. mysqld comes back with no entries. install_db comes back with a line each for Starting and Started Install MySQL Community Server Database.
systemctl status returns exited success for install_db, for mysqld it reports Active: inactive (dead).
systemctl list-unit-files shows install_db as enabled and mysqld as disabled.
I was able to start mysqld with systemctl start and it showed running with systemctl status & ps. But it did not restart after a reboot.
If there is anything else that I can do to help understand what is going on please let me know.
Greg
Quoted 73 lines · Greg Wilson-Lindberg
Quoted 65 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 11:55 AM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 50 lines · Greg Wilson-Lindberg
Quoted 41 lines
From: Greg Wilson-Lindberg
Sent: Thursday, March 15, 2018 02:16 PM
To: Khem Raj <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 17 lines
From: Khem Raj <[email protected]>
Sent: Thursday, March 15, 2018 1:54 PM
To: Greg Wilson-Lindberg
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 1 line
On Thu, Mar 15, 2018 at 1:38 PM, Greg Wilson-Lindberg
Quoted 6 lines · <[email protected]> wrote:
I'm building an RPi3 system that is going to use mysql/mariadb. I've got everything installed, but mysqld is not starting. install_db.service does run on startup, but the mysqld.service file never gets triggered.
Quoted 5 lines
Quoted 3 lines
Is there something that I'm missing to get it to run? I've search online, but can't find anything that pertains to yocto.
poke on the system with systemctl/journalctl to see whats going on
journalctl -u mysqld.service says no entries
systemctl status mysqld.service shows:
Loaded: loaded (/lib/systemd/system/mysqld.service; disabled;vendor
preset: enabled)Quoted 8 lines
Active: inactive (dead)
I've rebooted the system a couple of times to see if
install_dbneeded to be run before mysql would run, no luck.Quoted 5 lines
It's seems that maybe I need to add a bit about my understanding of the yocto system. I was assuming that if I included mysql in the build, that it would be started when the system powered up. If mysql is not normally started automatically that I can do what is necessary to start it, I just thought that I shouldn't need to do anything.
Quoted 7 lines
Yes you are right. We try to do runtime testing as much as possible and you will see more and more focus on runtime testing in coming days and months. So far we have had lot of build related features and stability problems to work on so chances of runtime bugs are still a bit higher. You can help in fixing this issue if you can root cause it. eg. check in system logs using journalctl for possible causes of this service not starting up. Often times you will get a decent hint and we can help as well on that information
Quoted 7 lines
I've run journalctl on both install_db.service & mysqld.service. mysqld comes back with no entries.
install_dbcomes back with a line each for Starting and Started Install MySQL Community Server Database.systemctl status returns exited success for
install_db, for mysqld it reports Active: inactive (dead).systemctl list-unit-files shows
install_dbas enabled and mysqld as disabled.I was able to start mysqld with systemctl start and it showed running with systemctl status & ps. But it did not restart after a reboot.
can you try
systemctl enable mysqld
this should enable it to start on boot.
Quoted 4 lines
If there is anything else that I can do to help understand what is going on please let me know.
Greg
Quoted 16 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 02:16 PM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 7 lines · Greg Wilson-Lindberg
Quoted 7 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 11:55 AM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.
....
....
....
Quoted 10 lines
Quoted 2 lines
I've run journalctl on both install_db.service & mysqld.service. mysqld comes
back with no entries.
install_dbcomes back with a line each for Starting and Started Install MySQL Community Server Database.Quoted 2 lines
systemctl status returns exited success for
install_db, for mysqld it reports Active:inactive (dead).
Quoted 3 lines
systemctl list-unit-files shows
install_dbas enabled and mysqld as disabled.
Quoted 8 lines
Quoted 1 line
I was able to start mysqld with systemctl start and it showed running with
systemctl status & ps. But it did not restart after a reboot.
can you try
systemctl enable mysqld
this should enable it to start on boot.
That did create a link and it started on reboot.
I take it that something is happening in install_db and among other things that link is not getting created?
Greg
Quoted 6 lines
Quoted 3 lines
If there is anything else that I can do to help understand what is going on please let
me know.
Quoted 2 lines
Greg
Quoted 32 lines · Greg Wilson-Lindberg
Quoted 16 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 02:16 PM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 7 lines · Greg Wilson-Lindberg
Quoted 7 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 11:55 AM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.....
....
....Quoted 13 lines
Quoted 2 lines
I've run journalctl on both install_db.service & mysqld.service. mysqld comes
back with no entries.
install_dbcomes back with a line each for Starting and Started Install MySQL Community Server Database.Quoted 2 lines
systemctl status returns exited success for
install_db, for mysqld it reports Active:inactive (dead).
Quoted 4 lines
systemctl list-unit-files shows
install_dbas enabled and mysqld as disabled.I was able to start mysqld with systemctl start and it showed running with
systemctl status & ps. But it did not restart after a reboot.
Quoted 8 lines
Quoted 5 lines
can you try
systemctl enable mysqld
this should enable it to start on boot.
That did create a link and it started on reboot.
OK thats expected see ./meta-oe/recipes-dbs/mysql/mariadb.inc
SYSTEMD_PACKAGES = "${PN}-server ${PN}-setupdb"
SYSTEMD_SERVICE_${PN}-server = "mysqld.service"
SYSTEMD_AUTO_ENABLE_${PN}-server ?= "disable"
its disabled on install. you can set it to be enabled via a bbappend in your layer
Quoted 1 line
I take it that something is happening in
install_dband among other things that link is not getting created?
its calling
mysql-systemd-start pre
but it depends on mysqld.service so I wonder if it was not working because mysqld.service was disabled
so may be now it works
Quoted 55 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 02:51 PM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 21 lines · Greg Wilson-Lindberg
Quoted 17 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 02:16 PM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.Quoted 7 lines · Greg Wilson-Lindberg
Quoted 7 lines
-----Original Message-----
From: Khem Raj [mailto:[email protected]]
Sent: Friday, March 16, 2018 11:55 AM
To: Greg Wilson-Lindberg <[email protected]>
Cc: [email protected]
Subject: Re: [yocto] How to get mysqy/mariadb to start on powerup.....
....
....Quoted 1 line
Quoted 1 line
Quoted 6 lines
Quoted 6 lines
Quoted 2 lines
I've run journalctl on both install_db.service & mysqld.service. mysqld comes
back with no entries.
install_dbcomes back with a line each for Starting and Started Install MySQL Community Server Database.Quoted 2 lines
systemctl status returns exited success for
install_db, for mysqld it reportsActive:
Quoted 8 lines
Quoted 8 lines
inactive (dead).
Quoted 5 lines
systemctl list-unit-files shows
install_dbas enabled and mysqld as disabled.I was able to start mysqld with systemctl start and it showed running with
systemctl status & ps. But it did not restart after a reboot.
Quoted 8 lines
Quoted 5 lines
can you try
systemctl enable mysqld
this should enable it to start on boot.
That did create a link and it started on reboot.
Quoted 7 lines
OK thats expected see ./meta-oe/recipes-dbs/mysql/mariadb.inc
SYSTEMD_PACKAGES= "${PN}-server ${PN}-setupdb"
SYSTEMD_SERVICE_${PN}-server = "mysqld.service"
SYSTEMD_AUTO_ENABLE_${PN}-server ?= "disable"its disabled on install. you can set it to be enabled via a bbappend in your layer
So it seems that I should do a .bbappend with it enabled then. Thanks,
Greg
Quoted 10 lines
Quoted 2 lines
I take it that something is happening in
install_dband among other things that linkis not getting created?
its calling
mysql-systemd-start pre
but it depends on mysqld.service so I wonder if it was not working because mysqld.service was disabled so may be now it works
Hi, all!
I'm having the same issue. I'm dummy with yocto, How I can create the bbappend file? I added the file mariadb_%.bbappend in my layer folder/recipes-dbs/mysql and add the line:
SYSTEMD_AUTO_ENABLE_${PN}-server ?= "enable"
But nothings occurred, What I'm doing wrong?
Regads,