Currently Being ModeratedJun 5, 2012 6:30 PM (in response to capaho)
Thanks so much capaho....I downloaded the workbench application and I get the following error
ERROR 1046 (3D000) at line 29: No database selected
It is also the same error I get when I tried to use the Terminal App to load it by following some directions from a few other threads but thought I was doing something wrong. It looks like I am missing a database or something.
Do you know if I need to create an emty database?
Currently Being ModeratedJun 5, 2012 7:07 PM (in response to J Moore)
If it's just a table then you would need to import it into an existing database. If you don't have any databases you would need to create one and then import the file into it.
mysql -u root -p database_name < import_file_name.sql
If you use the command line, you will need to specify the full path to the import file.
Currently Being ModeratedJun 5, 2012 7:21 PM (in response to capaho)
Thank you for helping me with the command line. It looks like I need to create a database. I just inserted the name on the command line for the database called webdata.
mysql -u root -p webdata < /private/var/mysql/422763_golive.sql
ERROR 1049 (42000): Unknown database 'webdata'
I have never created a database and I do think the .sql file is most likely a table. Can I create a database from the command line?
Currently Being ModeratedJun 5, 2012 8:40 PM (in response to J Moore)
Log into mysql:
mysql -u root -p
Then from the mysql command line:
create database new_database_name;
Then set priveleges:
grant all on new_database_name.* to 'root'@'localhost';
Then exit from the mysql command line and import the file as previously discussed.
If you're not familiar with mysql commands you might want to check the documentation on mysql.com.
Currently Being ModeratedJun 6, 2012 5:10 AM (in response to J Moore)
SequelPro is a Cocoa-based Mac-style tool for MySQL. This is a native equivalent to the MySQL Workbench stuff. This if you're not managing the database from the command line.
Do not install the available MySQL-related web-based management tools (eg: mysqladmin) in a web-facing directory (and certainly not unprotected against remote access) as many of the web-gremlins actively probe for the various known-weaknesses in those. These tools have various vulnerabilities, and are widely targeted.
MySQL is not available in Lion Server. You'll need to manage your own MySQL installation and patches starting on OS X Server 10.7 and later, or migrate your database to SQLite or PostgreSQL.
Currently Being ModeratedJun 6, 2012 7:23 AM (in response to MrHoffman)
The problem specifically is phpMyAdmin, which is fraught with security problems. Miscreants scan for it continually, so I highly recommend against it.
All PHP web apps have inherent vulnerabilities, so anyone using PHP of any variety on a web server should also be using the Apache security module (modsecurity). Unfortunately, Apple does not support modsecurity in OS X Server and installing it is a complicated process. It's an inexcusable lapse in Apple's security philosphy. Running a web server without modsecurity is an unacceptable risk. Shame on Apple for such a serious omission in OS X Server security.