Re: mac osx server and mysql
Thanks for responding Ryan I've actually installed everything fine; the problem is it's on macosx server, and it's more stringent with it's permissions. It seems that I can't create the database file or write to it as user mysql (which is what mysql would be saving as, correct?) I thought I could find the directory and chmod 777 it? On Mar 30, 2007, at 2:47 AM, Ryan Schmidt wrote:
On Mar 30, 2007, at 01:29, grimmwerks wrote:
Hey - trying desperately to get subversion, mysql, ruby and retrospectiva working on osx server, but it's much more painful than the other installs I've done...
where does mysql save it's db? Seems I don't have write access....
I believe the default location for MySQL 5 databases installed by MacPorts is /opt/local/var/db/mysql5
...does anyone know of any tutorials to handle what I want to do/
What doesn't work for you? For example, if you want to run a MySQL 5 server, you should be able to say
sudo port install mysql5 +server
and then follow the instructions printed when it's done regarding how to create the initial databases.
For Subversion, you should be able to say
sudo port install subversion
and get Subversion. What problems are you encountering?
--
To reply to the mailing list, please use your mailer's Reply To All function
On Mar 30, 2007, at 12:37, grimmwerks wrote:
I've actually installed everything fine; the problem is it's on macosx server, and it's more stringent with it's permissions. It seems that I can't create the database file or write to it as user mysql (which is what mysql would be saving as, correct?)
In which way is Mac OS X Server more stringent with its permissions? I have not used Mac OS X Server in the past several years, so maybe something has changed that I don't know about, but Mac OS X Server certainly used to be exactly the same as Mac OS X client, just with a few more apps and services installed.
I thought I could find the directory and chmod 777 it?
Wouldn't it be much better just to assign the ownership to the mysql user? sudo chown mysql:mysql /opt/local/var/db/mysql5 In fact I was under the impression that this was done automatically for you when you initially create the database using the command printed at the end of the mysql5 port installation. Did this not happen for you? Are you seeing error messages? If so, what are they?
On Mar 30, 2007, at 4:33 PM, Ryan Schmidt wrote:
Wouldn't it be much better just to assign the ownership to the mysql user?
sudo chown mysql:mysql /opt/local/var/db/mysql5
It's already set: drwxr-xr-x 13 mysql mysql 442 Mar 29 21:05 mysql5
In fact I was under the impression that this was done automatically for you when you initially create the database using the command printed at the end of the mysql5 port installation. Did this not happen for you?
It did create the inital db; I also created a user (retrospectiva) and 2 databases (couldn't do it through mysql manager gui, I had to do it in the command line as root). I assigned the retrospectiva permissions to edit retrospectiva and retrospectiva_dev dbs. I edited the retrospectiva conf.yml file to this info, so next....
Are you seeing error messages? If so, what are they?
When I try to run rake: subversion:/opt/apache2/htdocs/retrospectiva admin$ rake RAILS_ENV=production db:retro:load --trace (in /opt/apache2/htdocs/retrospectiva) ** Invoke db:retro:load (first_time) ** Invoke environment (first_time) ** Execute environment Rails Error: Unable to access log file. Please ensure that /opt/ apache2/htdocs/retrospectiva/config/../log/production.log exists and is chmod 0666. The log level has been raised to WARN and the output directed to STDERR until the problem is fixed. ** Execute db:retro:load ** Invoke db:retro:load_schema (first_time) ** Invoke environment ** Execute db:retro:load_schema ===== Load the database schema ** Invoke db:schema:load (first_time) ** Invoke environment ** Execute db:schema:load -- create_table("attachments", {:force=>true}) rake aborted! Access denied for user 'retrospectiva'@'localhost' (using password: YES) /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/mysql_adapter.rb:389:in `real_connect' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/mysql_adapter.rb:389:in `connect' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/mysql_adapter.rb:152:in `initialize' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/mysql_adapter.rb:82:in `new' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/mysql_adapter.rb:82:in `mysql_connection' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/abstract/ connection_specification.rb:262:in `send' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/abstract/ connection_specification.rb:262:in `connection_without_query_cache=' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/query_cache.rb:54:in `connection=' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/abstract/ connection_specification.rb:230:in `retrieve_connection' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/connection_adapters/abstract/ connection_specification.rb:78:in `connection' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/migration.rb:275:in `method_missing' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/migration.rb:259:in `say_with_time' /opt/local/lib/ruby/1.8/benchmark.rb:293:in `measure' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/migration.rb:259:in `say_with_time' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/migration.rb:273:in `method_missing' ./db/schema.rb:7 /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/schema.rb:43:in `instance_eval' /opt/local/lib/ruby/gems/1.8/gems/activerecord-1.15.3/lib/ active_record/schema.rb:43:in `define' ./db/schema.rb:5 /opt/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/ active_support/dependencies.rb:488:in `load' /opt/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/ active_support/dependencies.rb:488:in `load' /opt/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/ active_support/dependencies.rb:342:in `new_constants_in' /opt/local/lib/ruby/gems/1.8/gems/activesupport-1.4.2/lib/ active_support/dependencies.rb:488:in `load' /opt/local/lib/ruby/gems/1.8/gems/rails-1.2.3/lib/tasks/ databases.rake:31 /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `call' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `each' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:369:in `invoke' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:362:in `synchronize' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:362:in `invoke' /opt/apache2/htdocs/retrospectiva/config/../lib/tasks/database.rake:12 /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `call' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `each' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:369:in `invoke' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:362:in `synchronize' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:362:in `invoke' /opt/apache2/htdocs/retrospectiva/config/../lib/tasks/database.rake:5 /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `call' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `each' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:399:in `execute' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:369:in `invoke' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:362:in `synchronize' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:362:in `invoke' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:1935:in `run' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:1935:in `each' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/lib/rake.rb:1935:in `run' /opt/local/lib/ruby/gems/1.8/gems/rake-0.7.2/bin/rake:7 /opt/local/bin/rake:16:in `load' /opt/local/bin/rake:16
participants (2)
-
grimmwerks
-
Ryan Schmidt