If you have root access, do 'mysqladmin -u... -h... ping'

----- Original Message -----
From: "Daniel da Veiga" <[EMAIL PROTECTED]>
To: mysql@lists.mysql.com
Sent: Thursday, February 15, 2007 1:08:49 PM (GMT-0500) Auto-Detected
Subject: Re: How can I detect if MySql is already installed?

On 2/15/07, Duncan Hill <[EMAIL PROTECTED]> wrote:
> On Thursday 15 February 2007 11:12:11 Juan Eduardo Moreno wrote:
> > Linux :
> >
> > $ rpm -qa |grep -i mysql
> >
> > Regards,
> > Juan
> >
> > On 2/14/07, Zsolt Csillag <[EMAIL PROTECTED]> wrote:
> > > Hello,
> > >
> > > I would like to create a setup program for my demo version that uses
> > > MySql database.
> > >
> > > I need to detect if the target computer has already got the MySql
> > > installed
> > > because I don't want to ruin an existing database.
>

Why do you need to detect if MySQL is already installed? You can
simply but all files at another location (your program's folder) and
write the my.ini/my.cnf file on the fly, changing the datadir and
other options for it to work wherever your program will be located.
You can also use sockets or named pipes instead of TCP/IP to ensure
you won't block any port or mess with the network, starting your
server without networking support.

> That only works for the limited case of
> * System supports RPM
> * Admin installed MySQL as an RPM
>
> Without knowing what platform you intend your demo to run on, giving an
> accurate answer will be hard.
>
> Furthermore, it's very possible to have multiple installs of MySQL on a server
> without conflict, so done correctly, you won't trash any other MySQL
> installs.

Agreed completely.

You simply can't bet someone is using a rpm/deb/portage based system
and expect your consumers to deal with it... Also the OP never
mentioned the OS, version of MySQL, etc, and that makes it VERY
difficult to get an answer.

-- 
Daniel da Veiga
Computer Operator - RS - Brazil
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCM/IT/P/O d-? s:- a? C++$ UBLA++ P+ L++ E--- W+++$ N o+ K- w O M- V-
PS PE Y PGP- t+ 5 X+++ R+* tv b+ DI+++ D+ G+ e h+ r+ y++
------END GEEK CODE BLOCK------

-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to