Bug #26884 Instance manager tests potentially take an hour when run as root
Submitted: 6 Mar 2007 16:20 Modified: 5 Oct 2007 15:45
Reporter: Scott MacVicar Email Updates:
Status: Unsupported Impact on me:
None 
Category:Instance Manager Severity:S3 (Non-critical)
Version:5.0.40-BK, 5.0.36 OS:Linux (RHEL4)
Assigned to: CPU Architecture:Any
Tags: Contribution

[6 Mar 2007 16:20] Scott MacVicar
Description:
When you run the test suite as root the instance manager throws an error and never starts, each test waits 600 seconds for the process to start leading to a test run  taking over an hour.

This quick fix helps skips those tests.

How to repeat:
Run the test suite as root.

Suggested fix:
--- mysql-test/include/im_check_env.inc.orig       2007-03-06 10:15:13.000000000 -0600
+++ mysql-test/include/im_check_env.inc    2007-03-06 10:16:49.000000000 -0600
@@ -12,6 +12,9 @@

 --source include/not_windows.inc

+# The instance manager will not start as root
+--source include/not_as_root.inc
+
 --connection default

 # Let IM detect that mysqld1 is online. This delay should be longer than
[10 Apr 2007 14:20] Valeriy Kravchuk
Thank you for a bug report. Although running tests as root is not recommended, I did verify this slow execution with 5.0.40-BK:

mysql-test-run: WARNING: Process 24849 died
help                           [ fail ]

ERROR: Failed to start master mysqld 0

Stopping All Servers
Shutting-down Instance Manager
Restoring snapshot of databases
Resuming Tests

mysql-test-run: WARNING: Waited 60 seconds for /home/openxs/dbs/5.0/mysql-test/v
ar/run/mysqld_1.pid to be created, still waiting for 340 seconds...
mysql-test-run: WARNING: Waited 120 seconds for /home/openxs/dbs/5.0/mysql-test/
var/run/mysqld_1.pid to be created, still waiting for 280 seconds...
mysql-test-run: WARNING: Waited 180 seconds for /home/openxs/dbs/5.0/mysql-test/
var/run/mysqld_1.pid to be created, still waiting for 220 seconds...
mysql-test-run: WARNING: Waited 240 seconds for /home/openxs/dbs/5.0/mysql-test/
var/run/mysqld_1.pid to be created, still waiting for 160 seconds...
mysql-test-run: WARNING: Waited 300 seconds for /home/openxs/dbs/5.0/mysql-test/
var/run/mysqld_1.pid to be created, still waiting for 100 seconds...
mysql-test-run: WARNING: Waited 360 seconds for /home/openxs/dbs/5.0/mysql-test/
var/run/mysqld_1.pid to be created, still waiting for 40 seconds...
Killing Possible Leftover Processes
Sleep 1 second waiting for processes to die
mysqld[0] has not created PID file in 400 secs.
im_daemon_life_cycle           [ fail ]

ERROR: Failed to start Instance Manager.

Stopping All Servers
Shutting-down Instance Manager
Restoring snapshot of databases
Resuming Tests

mysql-test-run: WARNING: Waited 60 seconds for /home/openxs/dbs/5.0/mysql-test/v
ar/run/mysqld_1.pid to be created, still waiting for 340 seconds...
mysql-test-run: WARNING: Waited 120 seconds for /home/openxs/dbs/5.0/mysql-test/
var/run/mysqld_1.pid to be created, still waiting for 280 seconds...
mysql-test-run: WARNING: got INT signal, cleaning up.....
Stopping All Servers
Shutting-down Instance Manager
mysql-test-run: *** ERROR: We die from ^C signal from user
[5 Oct 2007 15:38] Konstantin Osipov
We plan to discontinue the instance manager in the future.
[5 Oct 2007 15:45] Konstantin Osipov
The instance manager will be discontinued.