1
votes

The app I'm working with is well established and uses a pretty standard CakePHP ACL set up with the usual ACO/ARO tables. I usually use the cakephp console (./cake acl ....) to add acos when I create a new action in a controller, and as recently as last week I was doing this just fine for a new controller I'd created.

This morning however when running the console utility I get a very lengthy delay and eventually get (my company DB URL removed):

./cake acl create aco Statistics data

Warning: mysql_connect(): [2002] Operation timed out (trying to connect via tcp://[db url]:3306) in /dev/docs/cake/libs/model/datasources/dbo/dbo_mysql.php on line 552

Warning: mysql_connect(): Operation timed out in /dev/docs/cake/libs/model/datasources/dbo/dbo_mysql.php on line 552

Warning: mysql_select_db() expects parameter 2 to be resource, boolean given in /dev/docs/cake/libs/model/datasources/dbo/dbo_mysql.php on line 558

Warning: mysql_get_server_info() expects parameter 1 to be resource, boolean given in /dev/docs/cake/libs/model/datasources/dbo/dbo_mysql.php on line 566

Warning: mysql_query() expects parameter 2 to be resource, boolean given in /dev/docs/cake/libs/model/datasources/dbo/dbo_mysql.php on line 600 Error: Missing database table 'aros' for model 'Aro'

There is no isse with load time when using the app from the browser, nor with using any of the other DB-intensive actions I created last week. This dev copy of the app does not use Cake's cacheing, so that's not the problem. Really just seems to be choking somewhere specifically in adding the new aco.

I'd think it were an issue with the DB server if not for the fact that it is otherwise responding fine in the app. Any ideas where in Cake's guts this sort of a misstep could occur?

1

1 Answers

1
votes

For the one in a million chance that someone is in my position, remember that when working in a large instiution there are these little things called firewalls, and if you're going to run a cake console, you'd better be SSH'd on to the webserver to run your ACO commands or anything involving a connection to your database server, instead of being mapped on to a shared drive as I decided to do this week.