ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Installation/Configuration Support » CHAD exit not getting loaded

Post new topic  Reply to topic Goto page 1, 2  Next
 CHAD exit not getting loaded « View previous topic :: View next topic » 
Author Message
prince_mq
PostPosted: Fri Nov 10, 2006 1:47 am    Post subject: CHAD exit not getting loaded Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

Hi,

I have configured a channel autodefiniton exit on cluster sender. When I am trying to start the cluster sender, i am getting the following error.

11/10/06 09:29:22
AMQ6188: The system could not dynamically load the shared library
'/var/mqm/exits//chadexit' due to a problem with the library. The error
message was 'The system call does not exist on this system. (MQStart)'. The
queue manager will continue without this library.

EXPLANATION:
This message applies to AIX systems. The shared library
'/var/mqm/exits//chadexit' failed to load correctly due to a problem with
the library.
ACTION:
Check that the library exists and is in the correct place with the correct file
permissions etc. and has not been corrupted. Check that the entry point
'MQStart' has been exported from the library.
----- amqxufnx.c : 703 --------------------------------------------------------
11/10/06 09:29:22
AMQ9535: User exit not valid.

EXPLANATION:
Channel program 'xxx' ended because user exit
'chadexit(MY_MQ_CHANNEL_AUTO_DEF_EXIT)' is not valid.
ACTION:
Ensure that the user exit is specified correctly in the channel definition, and
that the user exit program is correct and available.
----- amqrexta.c : 4424 -------------------------------------------------------
11/10/06 09:29:22
AMQ9999: Channel program ended abnormally.

EXPLANATION:
Channel program 'xxx' ended abnormally.
ACTION:
Look at previous error messages for channel program 'xxx' in the
error files to determine the cause of the failure.


Can any one please let me know the error in this case.
Back to top
View user's profile Send private message
Gaya3
PostPosted: Fri Nov 10, 2006 2:14 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Hi

Please go to respective directory var/mqm/exits//chadexit and send us the ls -l chadexit and let us see the permission setting of it.


Let us know the details

Thanks and Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
Nigelg
PostPosted: Fri Nov 10, 2006 4:09 am    Post subject: Reply with quote

Grand Master

Joined: 02 Aug 2004
Posts: 1046

Quote:
'The system call does not exist on this system. (MQStart)


Well, that looks quite clear.
Do you have a function MQStart in your source code?
_________________
MQSeries.net helps those who help themselves..
Back to top
View user's profile Send private message
prince_mq
PostPosted: Fri Nov 10, 2006 4:43 am    Post subject: Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

Thanks gaya and nigel for your replies.

i have permissions of 777 for chadexit file but still its not working.

nigelg,

i have MQStart in my file. my code looks like


#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <cmqc.h>
#include <cmqxc.h>

/*for UNIX Systems*/
#ifdef _unix
void MQStart() {;} /* dummy entry point - for consistency only */
void MQENTRY MY_MQ_CHANNEL_AUTO_DEF_EXIT ( PMQCXP pChannelExitParms,PMQCD pChannelDef)
{

// do processing
}
#endif




/*for Windows Systems*/
#ifdef _WIN32

#include <windows.h>

BOOL APIENTRY DllMain( HMODULE hModule,DWORD ul_reason_for_call,LPVOID lpReserved)
{
return TRUE;
}

extern "C" __declspec(dllexport) void MQStart() {;} /* dummy entry point - for consistency only */
extern "C" __declspec(dllexport) void MQENTRY MY_MQ_CHANNEL_AUTO_DEF_EXIT ( PMQCXP pChannelExitParms,PMQCD pChannelDef)
{
//do processing


}

#endif



The command i am using for compiling chad exit is:

cc -e MQStart -bE:chadexit.exp -bM:SRE -o /var/mqm/exits/chadexit chadexit.c -I/usr/mqm/inc -L/usr/mqm/lib -lmqmzf

I have two doubts:

my .exp file looks like
#!
MQStart
MQENTRY

is this correct?

i am getting the following warnings when i compiled my chad exit which i ignored
ld: 0711-327 WARNING: Entry point not found: MQStart
ld: 0711-319 WARNING: Exported symbol not defined: MQStart
ld: 0711-319 WARNING: Exported symbol not defined: MY_MQ_CHANNEL_AUTO_DEF_EXIT
ld: 0711-244 ERROR: No csects or exported symbols have been saved.

pls let me know if i can ignore these warnings.

thanks in advance,
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Fri Nov 10, 2006 4:52 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

prince_mq wrote:
ld: 0711-327 WARNING: Entry point not found: MQStart
ld: 0711-319 WARNING: Exported symbol not defined: MQStart
ld: 0711-319 WARNING: Exported symbol not defined: MY_MQ_CHANNEL_AUTO_DEF_EXIT
ld: 0711-244 ERROR: No csects or exported symbols have been saved.


prince_mq wrote:
Check that the entry point 'MQStart' has been exported from the library.


prince_mq wrote:
pls let me know if i can ignore these warnings.


http://www.mqseries.net/phpBB2/viewtopic.php?t=20523
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Gaya3
PostPosted: Fri Nov 10, 2006 5:17 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Hi

Don't ignore the Warnings that you are getting while compiling the exit programming.

Its not finding the entry point, MQ Start


So please try to make it correct and execute, it will work.

Thanks and Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
prince_mq
PostPosted: Fri Nov 10, 2006 5:24 am    Post subject: Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

jeff, thanks so much for the link. The link is really useful for windows user.

actually my code is working on Windows and Solaris

Now, i am testing it on AIX and i am running into the above problems.

if any has some inputs regarding the above problem , kindly let me know.

Thanks,
Back to top
View user's profile Send private message
prince_mq
PostPosted: Wed Nov 15, 2006 11:54 pm    Post subject: Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

Hi,

I have modified the above code and i am getting a syntax error when i am compiling the following code. Its actually a C question. But i guess there will be some one on this forum who can help me sort this out. The error i am getting is at the starting of open brace which is highlighted in Blue below. please help me.

/* entry point for Unix System */
#ifdef _unix
void MQStart() {;} /* dummy entry point - for consistency only */
void MQENTRY MY_MQ_CHANNEL_AUTO_DEF_EXIT ( PMQCXP pChannelExitParms,PMQCD pChannelDef)
#endif
{ //SYNTAX ERROR AT THE START OF THIS LINE
/* do processing */
/* do processing */

}

Thanks
Back to top
View user's profile Send private message
wschutz
PostPosted: Thu Nov 16, 2006 3:30 am    Post subject: Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

What error are you getting?
_________________
-wayne
Back to top
View user's profile Send private message Send e-mail AIM Address
prince_mq
PostPosted: Thu Nov 16, 2006 3:33 am    Post subject: Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

wayne,

line 24.1: 1506-046 (S) Syntax error.

I am on AIX.
Back to top
View user's profile Send private message
wschutz
PostPosted: Thu Nov 16, 2006 3:37 am    Post subject: Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

prince_mq wrote:
wayne,

line 24.1: 1506-046 (S) Syntax error.

I am on AIX.
I'm assuming that "_unix" IS defined ....

can you post the code from the top to that line ?
_________________
-wayne
Back to top
View user's profile Send private message Send e-mail AIM Address
prince_mq
PostPosted: Thu Nov 16, 2006 3:42 am    Post subject: Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

wayne, i haven't defined _unix. It worked for _WIN32, so i thought it should work for _unix. can you let me know where i should define this.
the complete code looks like:

#ifdef _WIN32
#include <windows.h>
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <cmqc.h>
#include <cmqxc.h>

#ifdef _WIN32
BOOL APIENTRY DllMain( HMODULE hModule,DWORD ul_reason_for_call,LPVOID lpReserved){return TRUE;}
extern "C" __declspec(dllexport) void MQStart() {;} /* dummy entry point - for consistency only */
extern "C" __declspec(dllexport) void MQENTRY MY_MQ_CHANNEL_AUTO_DEF_EXIT ( PMQCXP pChannelExitParms,PMQCD pChannelDef)
#endif
#ifdef _unix
void MQStart() {;} /* dummy entry point - for consistency only */
void MQENTRY MY_MQ_CHANNEL_AUTO_DEF_EXIT ( PMQCXP pChannelExitParms,PMQCD pChannelDef)
#endif

{
//do processing
//do processing

}
Back to top
View user's profile Send private message
wschutz
PostPosted: Thu Nov 16, 2006 3:48 am    Post subject: Reply with quote

Jedi Knight

Joined: 02 Jun 2005
Posts: 3316
Location: IBM (retired)

as a hack, put
"#define _unix" at the top of your program ....
_________________
-wayne
Back to top
View user's profile Send private message Send e-mail AIM Address
prince_mq
PostPosted: Thu Nov 16, 2006 4:01 am    Post subject: Reply with quote

Voyager

Joined: 10 Aug 2006
Posts: 76

Thanks alot Wayne, it Worked!

This time i didnt get any compilation errors.

I hope this code works well for all unix platforms like AIX, SOLARIS, HP-UX.

For _WIN32, it didnt throw any errors but for _unix it threw an error. any idea as to why this is happening?

Thanks again!
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu Nov 16, 2006 4:03 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Or use
#if def _WIN32..
.... windows stuff here
#else // assume unix here
.... unix stuff here
#endif
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Goto page 1, 2  Next Page 1 of 2

MQSeries.net Forum Index » IBM MQ Installation/Configuration Support » CHAD exit not getting loaded
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.