List:General Discussion« Previous MessageNext Message »
From:Stefan Hinz Date:May 6 2003 8:59pm
Subject:Re[2]: localhost question
View as plain text  
Ya-Chun,

> Hi! Thanks for the explainations. I am running mysql on a 2000 server
> machine, so it has tcp/ip protocol running. does this mean it doesn't matter
> where I put my database(c: or d:) as long as they are assigned under
> localhost? Is this also involved changing port number?

No, and no. Look for the MySQL configuration file. It's called my.ini,
and it's located in c:\winnt\. (As an alternative, it could be called
my.cnf, which requires it to be located in c:\. Note that you
shouldn't have both of those files on the same machine.)

> Everything worked fine when I had Mysql on c drive.(cgi open the connection
> to db and makes changes), so I couldn't figure out why it doesn't work when
> mysql and its data are in D drive...

If you can't find either my.ini or my.cnf, create an empty file my.ini
in c:\winnt\. You should specify the location of your datadir (that's
the directory where all database are located), and you should specify
your basedir (that's MySQL's installation directory).

Let's say you have MySQL installed in d:\software\db\mysql\, and you
have the databases in d:\mydata\data\. In that case, here's what you
put in your my.ini:

[mysqld]
basedir = d:/software/db/mysql
datadir = d:/mydata/data
port    = 3306

The "port" option isn't necessary; it just tells MySQL to listen on
port 3306, which it would anyway. It's only necessary if you use some
other port on your machine.

Use slashes rather than backslashes. Restart the MySQL server. Read
this:

http://www.mysql.com/doc/en/Windows_prepare_environment.html

Regards,
--
  Stefan Hinz <hinz@stripped>
  iConnect GmbH <http://iConnect.de>
  Heesestr. 6, 12169 Berlin (Germany)
  Telefon: +49 30 7970948-0  Fax: +49 30 7970948-3

[filter fodder: sql, mysql, query]

Thread
Comparing two snapshots of a table to produce a change reportMike Hillyer5 May
  • Re: Comparing two snapshots of a table to produce a change reportZak Greant6 May
  • Re: Comparing two snapshots of a table to produce a change reportJeremy Zawodny6 May
RE: Comparing two snapshots of a table to produce a change reportDave Christensen6 May
  • Am using mysql and oscommerce, but i can't find my database that i created.David Jackson6 May
  • RE: Comparing two snapshots of a table to produce a change reportKyle Lange6 May
  • localhost questionYa-Chun Lin6 May
RE: Comparing two snapshots of a table to produce a change reportMike Hillyer6 May
Re: localhost questionJames Moe6 May
  • Re: localhost questionYa-Chun Lin6 May
    • Re[2]: localhost questionStefan Hinz6 May
  • Re: Re[2]: localhost questionYa-Chun Lin6 May
    • Re[4]: localhost questionStefan Hinz7 May
  • Re: Re[4]: localhost questionYa-Chun Lin7 May
  • import binary file?Ya-Chun Lin29 May