| Author | Message | 
		
		  | morpheus | 
			  
				|  Posted: Fri Oct 17, 2003 6:41 am    Post subject: connection to server using mqcilent |   |  | 
		
		  |  Acolyte
 
 
 Joined: 08 Mar 2003Posts: 72
 Location: Austin, TX
 
 | 
			  
				| I am trying to connect to my local machine from a Unix server using a application and MQClient. 
 My local NT machine has Queue Manager and all objects including Client Channel and Server Connection channel.
 
 As per the IBM documentation, having the ServerConn channel and Client Conn channel (same name) is enough to communicate.
 
 Can anyone PLEASE HELP as this is not working.
 
 regards to ALl
 MQGuy
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | mrlinux | 
			  
				|  Posted: Fri Oct 17, 2003 7:01 am    Post subject: |   |  | 
		
		  |  Grand Master
 
 
 Joined: 14 Feb 2002Posts: 1261
 Location: Detroit,MI USA
 
 | 
			  
				| What are using to setup the client  MQSERVER variable or are you using Channel tables ???
 _________________
 Jeff
 
 IBM Certified Developer MQSeries
 IBM Certified Specialist MQSeries
 IBM Certified Solutions Expert MQSeries
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | xxx | 
			  
				|  Posted: Fri Oct 17, 2003 8:21 am    Post subject: |   |  | 
		
		  | Centurion
 
 
 Joined: 13 Oct 2003Posts: 137
 
 
 | 
			  
				| I assume 
 NT is the client and Unix Qmanager is the server,
 
 There is a issue with NT that it cannot have both the Server and Client,
 
 Else if you r connecting from the UNX client to NT,
 For Java Applications you need to specfy MQSERVER Variable or
 define a SERVERconn on the NT server
 
 Other way If it is a C++ or VB application you need to define svrconn and clinetconn on NT box and copy clientchannel table
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | morpheus | 
			  
				|  Posted: Fri Oct 17, 2003 8:38 am    Post subject: |   |  | 
		
		  |  Acolyte
 
 
 Joined: 08 Mar 2003Posts: 72
 Location: Austin, TX
 
 | 
			  
				| Thanks for your reply. 
 Server is NT and client is Unix.
 
 Reg "What are using to setup the client MQSERVER variable or are you using
 Channel tables ??? "
 
 I created 2 channels on the server(ServerConn and Client Conn ) on the server (NT ). Both with same name.
 
 Is that not enough. Do we need to do anything else?
 
 
 regards
 MQGuy
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | bower5932 | 
			  
				|  Posted: Fri Oct 17, 2003 9:28 am    Post subject: |   |  | 
		
		  |  Jedi Knight
 
 
 Joined: 27 Aug 2001Posts: 3023
 Location: Dallas, TX, USA
 
 | 
			  
				| You can connect from the client either using the environment variable or the client connection table.  Assuming that you have a listener running on your UNIX box, you could try the following from a command prompt on Windows: 
 set MQSERVER=SYSTEM.DEF.SVRCONN/TCP/unix-hostname
 amqsputc SYSTEM.DEFAULT.LOCAL.QUEUE your-qmgr-name
 
 This will set the environment variable and then attempt to run the sample as a client against the UNIX box.  It uses a SVRCONN connection.  The client table uses the CLNTCONN connections.
 
 What language is your program written in?
 
 I'm also not sure that I understand:
 
 
   
	| Quote: |  
	| There is a issue with NT that it cannot have both the Server and Client
 
 |  since I have both installed on my system and run this way all of the time.
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | mrlinux | 
			  
				|  Posted: Fri Oct 17, 2003 9:29 am    Post subject: |   |  | 
		
		  |  Grand Master
 
 
 Joined: 14 Feb 2002Posts: 1261
 Location: Detroit,MI USA
 
 | 
			  
				| You may need to do more. 
 1) Are you using the standard MQCONN call or are you using the MQCONNX ???
 Using the standard MQCONN Call you need to set some env variables
 to point at the channel table.
 export MQCHLLIB=/var/mqm/qmgrs/QMGR_NAME/@ipcc  (default location)
 export MQCHLTAB=AMQCLCHL.TAB  (default filename)
 2) MQCONNX call will specify the details.
 _________________
 Jeff
 
 IBM Certified Developer MQSeries
 IBM Certified Specialist MQSeries
 IBM Certified Solutions Expert MQSeries
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  | Keka | 
			  
				|  Posted: Fri Oct 17, 2003 10:18 am    Post subject: |   |  | 
		
		  | Voyager
 
 
 Joined: 28 Dec 2002Posts: 96
 
 
 | 
			  
				| For Java you should not be using MQSERVER. If you are wtitting a Java application you should be setting the Environment.host etc variables. MQSERVER is only for C and C++ applications. As for how to set this up,
 here is an example for Unix. Same will work with NT except for the fact that you have to add this environement variable in system environment variables.
 
 Unix:
 syntax
 export MQSERVER=channelname/TCP/'IPaddress:portnumber'.
 example:
 export MQSERVER=samplechanel/TCP/'207.10.68.101:1416'
 
 hope this helps
 _________________
 Keka
 |  | 
		
		  | Back to top |  | 
		
		  |  | 
		
		  |  |