View Full Version : How to install mysql
luoleiCN
2008-08-05, 10:46 AM CDT
i am a newer to linux
yum list mysql
i got so many,
mysql.i386 5.0.51a-1.fc9 installed
mysql-libs.i386 5.0.51a-1.fc9 installed
mysql-server.i386 5.0.51a-1.fc9 installed
Available Packages
MySQL-python.i386 1.2.2-7.fc9 updates
mysql++.i386 3.0.4-1.fc9 updates
mysql++-devel.i386 3.0.4-1.fc9 updates
mysql++-manuals.i386 3.0.4-1.fc9 updates
mysql-administrator.i386 5.0r12-8.fc9 updates
mysql-bench.i386 5.0.51a-1.fc9 fedora
mysql-connector-java.i386 1:3.1.12-5.fc9 fedora
mysql-connector-odbc.i386 3.51.24r1071-1.fc9 fedora
mysql-devel.i386 5.0.51a-1.fc9 fedora
mysql-gui-common.i386 5.0r12-8.fc9 updates
mysql-gui-tools.i386 5.0r12-8.fc9 updates
mysql-proxy.i386 0.6.1-1.fc9 fedora
mysql-query-browser.i386 5.0r12-8.fc9 updates
mysql-test.i386 5.0.51a-1.fc9 fedora
mysqltuner.noarch 0.9.8-1 updates
which should i choose ,and i need gui
oneofmany
2008-08-05, 10:52 AM CDT
"yum install mysql" should be all you need but the basic server requires the top 3 in your list which are apready installed. everything else is just access libraries and development utilities.
to start it up, you'll need to do the following..
su -
chkconfig mysqld on
service mysqld start
the first time it is started, it will initialise the database and give you the following 2 lines in order to set your root access password ...
/usr/bin/mysqladmin -u root password 'new-password'
/usr/bin/mysqladmin -u root -h your.host.name password 'new-password'
you can ignore the information about how to start the daemon :)
luoleiCN
2008-08-05, 06:14 PM CDT
many thanks , i came to linux just 10 days ago
i got it
yum intall mysql.i386
yum intall mysql-server.i386
yum install mysql-gui-common.i386
yum install mysql-gui-tools.i386
i also got gui.
and this can start mysql service
/sbin/chkconfig --add mysqld
/sbin/chkconfig mysqld on
/sbin/service mysqld start
ps: i am Chinese, my eglish is so poor that sometimes i cannot pass the egllish exam. but i hope this can help to install mysql.
arshad3m
2008-08-06, 08:42 AM CDT
hallo friends,
i installed the above mentioned application. it asks to connect to a server. i wonder where can i find a server since i have only one computer in my home. this is the window i get. and i dont know what password it asks for.
http://i36.tinypic.com/1zmfgv7.png
furthermore, i used to work in microsoft sql server 2005, do all those commands and queries can be applied here also??
thanks you very much.
oneofmany
2008-08-06, 08:43 AM CDT
if you installed and started the mysql server, try localhost :)
pete_1967
2008-08-06, 08:47 AM CDT
If you have MySQL installed on your desktop, you just need to add its details.
Hostname would be localhost
Username would be what ever user you added (root) by default
Password is password for the user (unless you configured root to use password <--- you should have!) else leave empty.
MSSQL and MySQL are not 100% compatible, actually no SQL server (PostGRE, Oracle etc etc) use same SQL syntax than others.
Only if your tables and queries are very simple and basic you may be in luck to get away with just replicating one DB SQL to another.
arshad3m
2008-08-06, 08:53 AM CDT
thank you, but,,,,,
i have installed it but i cant find it anywhere. in application>>programming>> i have only 'mysql Administrator' and 'mysql query browser'.
http://i38.tinypic.com/1zp61hv.png
as you said, i just typed local host and clicked connect. this is what the message i got.
http://i38.tinypic.com/b3rl7d.png
luoleiCN
2008-08-06, 08:54 AM CDT
hi ,arshad3m
i agree with pete
set root(root of mysql not fedora) code:
mysqladmin -u root password 'newpassword'
you can do this to make your mysql safer:
mysql> DROP DATABASE test;
mysql> DELETE FROM mysql.user WHERE user = '';
mysql> FLUSH PRIVILEGES;
i hope it will help
oneofmany
2008-08-06, 08:54 AM CDT
from a terminal window..
su -
chkconfig mysqld on
service mysqld start
luoleiCN
2008-08-06, 08:57 AM CDT
you must start mysql service first
/sbin/chkconfig --add mysqld
/sbin/chkconfig mysqld on
/sbin/service mysqld start
then connect again
arshad3m
2008-08-06, 09:01 AM CDT
thank you very much 'oneofmany' and 'luoleiCN' it worked now. but i wonder why u gave 'mysqld' ? cant we give any prefix other than 'd' after mysql??
thanks
oneofmany
2008-08-06, 09:02 AM CDT
luoleiCN, you shouldn't require the --add line
oneofmany
2008-08-06, 09:03 AM CDT
thank you very much 'oneofmany' and 'luoleiCN' it worked now. but i wonder why u gave 'mysqld' ? cant we give any prefix other than 'd' after mysql??
thanks
the "d" refers to "daemon" which is the unix name for a "service" which is what the mysql server is.
arshad3m
2008-08-06, 09:10 AM CDT
thank you very much. :)
arshad3m
2008-08-06, 10:18 AM CDT
hai i tried to create a simple table. but even after i execute i cant view the result. please tell me where to see the output.
thank you very much.
http://i36.tinypic.com/21eviqc.png
pete_1967
2008-08-06, 10:25 AM CDT
http://dev.mysql.com/tech-resources/articles/mysql_intro.html
http://dev.mysql.com/doc/refman/5.0/en/tutorial.html
arshad3m
2008-08-06, 11:24 AM CDT
thank you for the info. but i am looking for entering quering in the interface not in command prompt. is there any way?
thanks. :)
oneofmany
2008-08-06, 02:58 PM CDT
lots. phpmyadmin for one; its web based :)
arshad3m
2008-08-06, 08:48 PM CDT
sorry guys. it worked for me. thank you. the thing is not all the commands are same as in microsoft sql :mad:
luoleiCN
2008-08-08, 08:29 AM CDT
its the time of olympic
forget fedora
enjoy olympic now
luoleiCN
2008-08-08, 08:29 AM CDT
its the time of olympic
forget fedora
enjoy olympic now
haha
vBulletin® v3.7.3, Copyright ©2000-2009, Jelsoft Enterprises Ltd.