Dears,
Thanks for your advice, the problem has been solved. However,
the following php statement still cannot connect to the specific database mydb,
line 4: $db=mysql_connect("local","root");
line 5: mysql_select_db("mydb",$db);
the error message prompts out
Warning: Supplied argument is not valid mysql result resource in /home/simon/public_html/first.php on line 5.
Before that,I have tested the existence of the database, mydb, in the computer under linux terminal by using the following commands.
shell > mysql
mysql> use mydb;
mysql> select * from employees
the data are then displayed out.
Please give me some solutions on the configuration setting, thanks.
Sincerely yours,
Simon
skip wrote:
A MySQL newbie myself.
I just went through this lastnight.
Make sure that after you run mysql_install_db, you go in and chown the folders and file under /var/lib/mysql to the mysql user and group that was created when you installed the RPM.
Also doing a "ps -A | grep 'mysql'" will let you know if mysqld is actualy running. When it is started at boot it returns [OK] but dies moments later if it can't open it's database.
Good Luck!