Enabling mysql Event scheduler on server restarts
Enabling mysql Event scheduler on server restarts
I am running phpmyadmin and installed apache server on my personal computer. My problem is that I am trying to set MySQL event_scheduler
to always be enabled even when the server restarts. I was reading that by setting the following command line in the server configuration file (my.cnf
or my.ini
) it should work: event_scheduler=DISABLED
. However, where do I locate this my.cnf
or my.ini
file, and also should the command line be event_scheduler=DISABLED
or event_scheduler=ENABLED
seeing that I want it to always be enabled?
Answer by Devart for Enabling mysql Event scheduler on server restarts
You should set 'ON' value (not ENABLED).
In the configuration file in [mysqld] section specify 'event-scheduler' option (not event_scheduler).
Also, you can start your MySQL server with '--event-scheduler' option, e.g. -
shell> mysqld --event-scheduler=ON
More information - event_scheduler system variable.
Answer by netkiller for Enabling mysql Event scheduler on server restarts
set GLOBAL event_scheduler=ON; add to my.cnf file. event_scheduler=on restart your mysql server. check status. mysql> select @@GLOBAL.event_scheduler; +--------------------------+ | @@GLOBAL.event_scheduler | +--------------------------+ | ON | +--------------------------+ 1 row in set (0.00 sec) mysql> SHOW VARIABLES LIKE 'event_scheduler'; +-----------------+-------+ | Variable_name | Value | +-----------------+-------+ | event_scheduler | ON | +-----------------+-------+ 1 row in set (0.01 sec)
Answer by AndrewD for Enabling mysql Event scheduler on server restarts
For WAMP:
Edit your my.ini file and under the [mysqld] section, add this:
event-scheduler=on
restart all services
verify by running this query:
select @@event_scheduler
;
To get to your my.ini file, just click the WAMP tray icon and hover over the 'MySQL' menu, and click 'my.ini'.
Answer by Mohan Kumar for Enabling mysql Event scheduler on server restarts
Here the path for my.ini
on XAMPP:
xampp\mysql\bin\my.ini
Open my.ini
and add the following
[mysqld] event_scheduler=ON
then restart MySQL service.
To check the status use the below MySQL query:
SELECT @@event_scheduler
Answer by Aurovrata for Enabling mysql Event scheduler on server restarts
FOR MAMP on OS X:
the default installation does not include a my.cnf
file so you need to create one and set up your default configuration. Therefore, to enable the the scheduler on an OS X MAMP stack, you need to,
- stop your MySQL server
create a
my.cnf
file in your/Applications/MAMP/conf/
folder, you will need root access to do this (open a terminal window),sudo touch /Applications/MAMP/conf/my.cnf
sudo nano /Applications/MAMP/conf/my.cnf
the 2nd cmd will open the nano editor, paste the following in your file,
[mysqld]
event_scheduler=ON
Save (
^O
) and exit (^X
) the nano editorrestart your MySQL server.
Fatal error: Call to a member function getElementsByTagName() on a non-object in D:\XAMPP INSTALLASTION\xampp\htdocs\endunpratama9i\www-stackoverflow-info-proses.php on line 72
0 comments:
Post a Comment