Mailing List Archive



Back to the month index Back to the list index

Guirong Qin (qinguir@duc.auburn.edu)
Tue, 8 Apr 1997 10:00:06 -0500


Date: Tue, 8 Apr 1997 10:00:06 -0500
From: qinguir@duc.auburn.edu (Guirong Qin)
Message-Id: <199704081500.KAA26074@mallard.duc.auburn.edu>
Subject: Re: [mSQL] Access to localhost with port # 1114 only?

Hi, Glenn:

Thanks for your clear and helpful explanation!

David G. Qin

>
> Hi,
>
> The port that msql uses for TCP/IP connections is defined in
> src/common/site.h. If you are running msql as root, then it
> uses a low-numbered port; I think the default is 1112, but
> yours apparently uses 1114. If msql runs as a non-root user,
> it uses port 4333 by default. It sounds like msql was installed
> on one of your machines as root, but on the others as some
> other user. You can get around this by setting environment
> variable MSQL_TCP_PORT (I think; check the docs) to the number
> you need before making the query.
>
> I'm not sure, but you might also be confusing access via a UNIX
> socket (which you can do on the local machine only) and via a
> TCP socket (which you can do either on remote machines or on the
> local machine). You get the UNIX socket with the form
> msqlConnect(NULL) in the C API, or from the command line with
> just "msql DB"; you get TCP/IP with msqlConnect(host.address)
> or "msql -h host.address DB". I don't know the Lite equivalents,
> but they must be similar--so, I think you're using TCP when you
> use msqlConnect("myhost"). This should work, but the UNIX socket
> is much faster.
>
> Hope this helps,
> Glenn
>
>
> >Yesterday I posted one of the problems: unable to access local database
> >under port # 4333. Today I occationally change port# from 4333 to 1114.
> >It works! To make sure this is the case, I change port# several times,
> >1114 works, but 4333 gets "Connection Refused!" message. Since I didn't
> >find this similar case from this list or FAQ, I don't understand this
> >is due to our local network configuration problem or w3-msql configuration
> >problem.
> >
> >BTW, somebody once suggestted(from this list) using msqlConnect(0), or
> >msqlConnect(NULL), that doesn't work for msql/lite, maybe for C/API?
> >For msql/Lite, even msqlConnect() not work for my case, I have to
> >specify with msqlConnect("myhost")!
>
>

--------------------------------------------------------------------------
To remove yourself from the Mini SQL mailing list send a message containing
"unsubscribe" to "unsubscribe" to msql-list-request@bunyip.com. Send a message containing
"info msql-list" to majordomo@bunyip.com for info on monthly archives of
the list. For more help, mail owner-msql-list@bunyip.com NOT the msql-list!