Re: INFORMIX 5 : is there a SQLHOSTS file ?
Posted in 1997
Jonathan Leffler wrote: > > }From: "Billy Wheeler" <billy@west.co.za> > }Date: Thu, 4 Sep 1997 08:24:43 +0200 > }X-Informix-List-Id: <list.16341> > } > }On 3 Sep 97 at 17:02, Peries, Chaminda wrote: > }> In the $INFORMIXDIR/etc directory there is no SQLHOSTS file. > Instead > }> there is a TBCONFIG file. > } > }TBCONFIG is the equivalent of ONCONFIG. > } > }> Where do I get The SERVICE NAME for the database from ? I found > }> the database server name in the TBCONFIG file. > } > }You have to create an entry in /etc/services. AFAIK, the name used > }there is the service name. > } > }> When I called up Informix tech support they said to create a file > }> called SQLHOSTS with similar info as in Informix 7 in this > }> directory. but this didn't work . > } > }I'm not entirely surprised. Online 5 has no concept of an SQLHOSTS > file... > > On the contrary, OnLine 5 does use an sqlhosts (lower case) file, but > only with I-Net or I-Star. In fact, I-Net and I-Star version 4.x used > an sqlhosts file, though the contents of the file was different. > > The version 5 sqlhosts file uses the same format as the more recent > versions, but there are fewer connectivity types (oltlitcp, seipcpip, > olsoctcp, etc; no olipcshm or olipcstr). > > Under Version 6 and later, the sqlhosts file is mandatory. Under > version 5, the sqlhosts file is optional; it is only needed if you are > using I-Net or I-Star. Not even then. I think this is where some of the confusion comes from. If you use I-Star (or I-Net) and you don't create an sqlhosts file the service name defaults to "sqlexec". As long as this is a valid service in /etc/services, then you have your port number. With no sqlhosts file, the following command: DATABASE mydb@myhost would look for the database mydb on hostname myhost and talk to the port defined for the sqlexec service. Notice this skips the DBServer name lookup. You must use an sqlhosts file for the following: 1. If a single remote server will be running multiple sqlexecd daemons. 2. If the DBServer name for your remote server is not the same as the hostname for the remote server. 3. If the service name specified by the sqlexecd daemon is not sqlexec. Hope that helps, -- Mark. +----------------------------------------------------------+-----------+ |Mark D. Stock - Informix SA http://www.informix.com |//////// /| |mailto:mdstock@informix.com FAQ http://www.iiug.org |///// / //| | +-----------------------------------+//// / ///| | Tel: +27 11 807 0313 |If it's slow, the users complain. |/// / ////| | Fax: +27 11 807 2594 |If it's fast, the users keep quiet.|// / /////| |Cell: +27 83 250 2325 |Therefore, "No news: travels fast"!|/ ////////| +----------------------+-----------------------------------+-----------+