Commit graph

23 commits

Author SHA1 Message Date
anozdrin/alik@ibm.
bbb1b64b95 Fix for BUG#28030: test im_instance_conf fails with an assert.
The problem was a race condition on shutdown -- when IM got shutdown
request while a guarded mysqld is starting. In this case the Guardian
thread tried to stop the mysqld, but might fail if the mysqld hadn't
created pid-file so far. When this happened, the mysqld-monitor thread
didn't stop, so the assert in Thread_registry happened.

The fix is to make several attempts to stop mysqld if it is active.
2007-07-27 17:39:01 +04:00
malff/marcsql@weblab.(none)
0055056c91 Merge weblab.(none):/home/marcsql/TREE/mysql-5.1-base
into  weblab.(none):/home/marcsql/TREE/mysql-5.1-merge
2007-01-02 14:18:13 -07:00
kent@kent-amd64.(none)
be15e3bc15 Merge mysql.com:/home/kent/bk/main/mysql-5.0
into  mysql.com:/home/kent/bk/main/mysql-5.1
2006-12-23 20:20:40 +01:00
kent@mysql.com/kent-amd64.(none)
226a5c833f Many files:
Changed header to GPL version 2 only
2006-12-23 20:17:15 +01:00
anozdrin/alik@booka.
b534ca4bc0 Fix for the following bugs:
- BUG#22306: STOP INSTANCE can not be applied for instances in Crashed,
    Failed and Abandoned;
  - BUG#23476: DROP INSTANCE does not work
  - BUG#23215: STOP INSTANCE takes too much time

BUG#22306:
The problem was that STOP INSTANCE checked that mysqld is up and running.
If it was not so, STOP INSTANCE reported an error. Now, STOP INSTANCE
reports an error if the instance has been started (mysqld can be down).

BUG#23476:
The problem was that DROP INSTANCE tried to stop inactive instance. The fix is
trivial.

BUG#23215:
The problem was that locks were not acquired properly, so the
instance-monitoring thread could not acquire the mutex, holded by the
query-processing thread.

The fix is to simplify locking scheme by moving instance-related information to
Instance-class out of Guardian-class. This allows to get rid of storing a
separate list of Instance-information in Guardian and keeping it synchronized
with the original list in Instance_map.
2006-11-30 12:23:55 +03:00
kostja@bodhi.local
2fc4562d63 Port cleanups, trivial refactoring and code rearrangements from
Alik's patch for BUG#22306: STOP INSTANCE can not be applied for 
instances in Crashed, Failed and Abandoned" to ease review process.
Evaluate global variable linuxthreads before starting threads to avoid
a race.
2006-11-18 01:34:44 +03:00
anozdrin/alik@alik.
f40a9d2ece Fix for BUG#17486: IM: race condition on exit.
The problem was that IM stoped guarded instances on shutdown,
but didn't wait for them to stop.

The fix is to wait for guarded instances to stop before exitting
from the main thread.

The idea is that Instance-monitoring thread should add itself
to Thread_registry so that it will be taken into account on shutdown.
However, Thread_registry should not signal it on shutdown in order to
not interrupt wait()/waitpid().
2006-10-24 18:23:16 +04:00
anozdrin@mysql.com
c1113af15c This is an implementation of two WL items:
- WL#3158: IM: Instance configuration extensions;
  - WL#3159: IM: --bootstrap and --start-default-instance modes

The following new statements have been added:
  - CREATE INSTANCE;
  - DROP INSTANCE;

The behaviour of the following statements have been changed:
  - SET;
  - UNSET;
  - FLUSH INSTANCES;
  - SHOW INSTANCES;
  - SHOW INSTANCE OPTIONS;
2006-05-18 18:57:50 +04:00
jani@a193-229-222-105.elisa-laajakaista.fi
8d3036c35e Some minor fixes revealed as warnings by
Intel compiler.
2005-09-23 21:28:56 +03:00
konstantin@mysql.com
344144ad14 Cleanup the instance manager code. 2005-08-29 23:29:35 +04:00
konstantin@mysql.com
c75cfc358e Fix a -ansi -pedantic compile failure. 2005-08-22 18:59:47 +04:00
petr@mysql.com
5605117d4d Fix for BUG#10957 "stop instance, issued after flush instances causes IM to crash"
Recommited with post-review fixes
2005-08-19 17:19:12 +04:00
reggie@fedora.(none)
f3de5d6b69 initial import of Windows port of IM. 2005-07-20 10:55:40 -05:00
petr@mysql.com
65d79b9d83 post-review fixes 2005-06-07 15:47:02 +04:00
petr@mysql.com
b072eaa3da Fix for AIX compilation failure: sacred knowledge of my_global.h nature (it should be
included before any other include) was hidden from me.
2005-03-22 02:04:14 +03:00
petr@mysql.com
912dfdfa34 post-review fixes + cleanup + some minor fixes 2005-02-27 18:41:34 +03:00
petr@mysql.com
dbc0937dd0 made IM to work with --defaults-file smoothly 2005-02-18 14:58:30 +03:00
petr@mysql.com
59d8e51150 some more cleanups and fixes 2005-02-15 04:38:33 +03:00
petr@mysql.com
6b50b5b087 Post-review fixes + some bugs fixed + several minor features 2005-02-11 14:21:59 +03:00
petr@mysql.com
63acf2a8be Various fixes (cleanups, valgrind, makefiles, ...) 2005-02-03 20:48:58 +03:00
petr@mysql.com
84d5b3a332 more fixes for IM to substitude mysqld_safe in startup scripts 2005-01-31 23:54:08 +03:00
petr@mysql.com
ee08b749dd IM mostly fixed according to Brian's directions. Will need to do some additional option handling and cleanups 2005-01-25 13:54:56 +03:00
petr@mysql.com
a8e2db4ecd Intermediate commit - just to make new files visible to bk in the new
tree
2004-10-23 11:32:52 +04:00