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 » Mainframe, CICS, TXSeries » LDAP on mainframe

Post new topic  Reply to topic
 LDAP on mainframe « View previous topic :: View next topic » 
Author Message
RogerLacroix
PostPosted: Mon Mar 19, 2007 2:26 pm    Post subject: LDAP on mainframe Reply with quote

Jedi Knight

Joined: 15 May 2001
Posts: 3253
Location: London, ON Canada

All,

I'm porting some code to z/OS that does LDAP API calls. I have the z/OS C header libraries 'LDAP.SGLDHDRC' and it compiles fine but I get linker errors about missing modules.

I've done a lot of searches and there is very little on the subject, but I did find the following IBM posting:
http://www-1.ibm.com/support/docview.wss?uid=isg1II13026

If you scroll down to section # 5, it sounds like a solution to my problem.

I added the PreLink DD and PreLink Sysin include statement. But it did not help. I checked the PreLinker's output and I can see my 'INCLUDE SYSLIB(GLDCLDPX)' statement and there are no PreLink errors. So, I am stumped.

I must have missed something obvious but I don't know what it could be.

Does anyone have sample JCL and Sysin member(s) for compiling and linking a simple client LDAP application for the mainframe?

Any help would be appreciated.

Regards,
Roger Lacroix
_________________
Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter
Back to top
View user's profile Send private message Visit poster's website
HenriqueS
PostPosted: Thu Dec 12, 2013 1:39 pm    Post subject: Reply with quote

Master

Joined: 22 Sep 2006
Posts: 235

Hello Roger,

I don´t like to bring an older post back, but I am facing similar challenges. After compiling, prelinking and linking with success I still get ABEND=S0C1 U0000 REASON=00000001 when I try to run the module.

Code:

CEE3201S The system detected an operation exception (System Completion Code=0C1)
         From entry point main at compile unit offset -16F00050 at entry offset
         Possible Bad Branch:  Statement:   Offset: +00000080                   


The ugly part I cleared the code, now it is just a printf, there is no ldap specific code at all. After the linking with ldap objects I get a useless executable. If I strip the SYS1.SIEALNKE
(GLDCLDAP) mention on the JCL linker STEP (tried IEWL and HEWL), then the program runs perfect.

I think I am including correctly the side deck definitions (they rename a bunch of longname functions) from HLQ.SGLDEXPC(
GLDCLDPX) - I tried EUVCLDAP also - in the prelinker step.

I followed also the instructions on these IBM posts, putting using all #pragmas and #defines, but no sucess so far. Also I doubt they were going to change something, since they are compile time definitions.

The JCLs for this sort of compile are very bad documented on the IBM Information Center.

How did you deal with this issue?

Best Regards,
Back to top
View user's profile Send private message
RogerLacroix
PostPosted: Thu Dec 12, 2013 5:02 pm    Post subject: Reply with quote

Jedi Knight

Joined: 15 May 2001
Posts: 3253
Location: London, ON Canada

Hi,

Is this for:

- Simple LDAP program (no MQ code) that makes client LDAP calls
- A program that uses MQ and client LDAP calls
- An MQ Exit that is attempting to make client LDAP calls

Regards,
Roger Lacroix
Capitalware Inc.
_________________
Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter
Back to top
View user's profile Send private message Visit poster's website
HenriqueS
PostPosted: Thu Dec 12, 2013 5:36 pm    Post subject: Reply with quote

Master

Joined: 22 Sep 2006
Posts: 235

First case, trying on batch mode.[/code]
Back to top
View user's profile Send private message
RogerLacroix
PostPosted: Thu Dec 12, 2013 6:03 pm    Post subject: Reply with quote

Jedi Knight

Joined: 15 May 2001
Posts: 3253
Location: London, ON Canada

Hi,

Here is a bunch of JCL from my testing back in 2007.
Here is the compile JCL:
Code:
//ROGERC1 JOB (05,555,55555,55555),'CPL MYBIND',
//             CLASS=A,MSGCLASS=H,MSGLEVEL=(1,1),
//             USER=ROGER,NOTIFY=&SYSUID,
//             REGION=0M,TIME=1440
//*
//PROC  JCLLIB ORDER=(ROGER.TEST.PROCLIB)
//*
//STEP1 EXEC CCNC,CREGSIZ=0M
//*
//SYSIN   DD DISP=SHR,DSN=ROGER.TEST.C(MYBIND)
//OPTIONS DD DISP=SHR,DSN=ROGER.TEST.C(CBCC1)
//SYSLIB  DD DISP=SHR,DSN=WMQ.V6R0.SCSQC370
//*
//PLKED.SYSLIB DD
//             DD DSN=LDAP.SGLDEXPC,DISP=SHR
//PLKED.SYSIN2  DD *
 INCLUDE SYSLIB(GLDCLDPX)
/*
//PLKED.SYSMOD   DD  DISP=SHR,DSN=ROGER.TEST.OBJECT(MYBIND)
//*

Here are the Options used:
Code:
 SEARCH('SYS1.SCEEH.+',
        'SYS1.SCEEH.SYS.+',
        'SYS1.SIEAHDR.H',
        'WMQ.V6R0.SCSQC370',
        'SYS1.SAMPLIB',
        'LDAP.SGLDHDRC',
        'ROGER.TEST.H' )
 SO NOSHOWINC EXP NOSTART LIST CSECT XREF

Here is the CCNCL PROC:
Code:
//*
//CBCCLG PROC INFILE=,                    < INPUT ... REQUIRED
//   CRUN=,                               < COMPILER RUNTIME OPTIONS
//   CPARM='OPTFILE(DD:OPTIONS)',         < COMPILER OPTIONS
//   CREGSIZ='0M',                        < COMPILER REGION SIZE
//   LIBPRFX=CEE,
//   LNGPRFX=CBC,
//*  CLBPRFX='CBC',                      < PREFIX FOR CLASS LIBRARIES
//   CLANG='EDCMSGE',
//   CXXLANG='CBCMSGE',
//   PLANG='EDCPMSGE',                    < PRE-LINKER MESSAGE NAME
//   PREGSIZ='2048K',                     < PRE-LINKER REGION SIZE
//   PPARM='MAP,NOER',                    < PRE-LINKER OPTIONS
//   LPARM='AMODE=31,MAP,RENT',           < LINKAGE EDITOR OPTIONS
// OUTFILE='&&GSET(GO),DISP=(NEW,PASS),UNIT=SYSDA,SPACE=(TRK,(7,7,1))'
//*-------------------------------------------------------------------
//*  COMPILE STEP:
//*-------------------------------------------------------------------
//COMPILE EXEC PGM=CCNDRVR,REGION=&CREGSIZ,
//    PARM=('&CRUN/CXX &CPARM')
//STEPLIB  DD  DSN=&LIBPRFX..SCEERUN,DISP=SHR
//         DD  DSN=&LNGPRFX..SCCNCMP,DISP=SHR
//SYSMSGS  DD  DUMMY,DSN=&LNGPRFX..SCBC3MSG(&CLANG),DISP=SHR
//SYSXMSGS DD  DUMMY,DSN=&LNGPRFX..SCBC3MSG(&CXXLANG),DISP=SHR
//SYSIN    DD  DSN=&INFILE,DISP=SHR
//SYSLIN   DD  DSN=&&LOADSET,UNIT=SYSDA,
//             DISP=(MOD,PASS),SPACE=(512,(50,20)),
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=3200)
//SYSPRINT DD  SYSOUT=*
//SYSOUT   DD  SYSOUT=*
//SYSCPRT  DD  SYSOUT=*
//OPTIONS  DD  DSN=SYSPROG.PARMLIB(CBCC1),
//             DISP=SHR
//SYSUT1   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=3200)
//SYSUT4   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=3200)
//SYSUT5   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=3200,BLKSIZE=12800)
//SYSUT6   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=3200,BLKSIZE=12800)
//SYSUT7   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=3200,BLKSIZE=12800)
//SYSUT8   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=3200,BLKSIZE=12800)
//SYSUT9   DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=VB,LRECL=137,BLKSIZE=882)
//SYSUT10  DD  SYSOUT=*
//SYSUT14  DD  UNIT=SYSDA,SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=3200,BLKSIZE=12800)
//SYSUT15  DD  SYSOUT=*
//*
//*-------------------------------------------------------------
//* PRE-LINKEDIT STEP:
//*-------------------------------------------------------------
//PLKED  EXEC PGM=EDCPRLK,REGION=&PREGSIZ,COND=(8,LE,COMPILE),
//       PARM='&PPARM'
//*TEPLIB  DD  DSN=&LIBPRFX..SCEERUN,DISP=SHR,UNIT=SYSDA,VOL=SER=SYSRX2
//SYSMSGS  DD  DSN=&LIBPRFX..SCEEMSGP(&PLANG),DISP=SHR
//SYSLIB   DD  DSN=&LIBPRFX..SCEECPP,DISP=SHR
//SYSIN    DD  DSN=*.COMPILE.SYSLIN,DISP=(MOD,PASS)
//*        DD  DSN=&CLBPRFX..SCLBSID(IOSTREAM),DISP=SHR
//*        DD  DSN=&CLBPRFX..SCLBSID(COMPLEX),DISP=SHR
//*        DD  DSN=&CLBPRFX..SCLBSID(ASCCOLL),DISP=SHR
//         DD  DDNAME=SYSIN2
//SYSMOD   DD  DSN=&&PLKSET,UNIT=SYSDA,DISP=(NEW,PASS),
//             SPACE=(32000,(30,30)),
//             DCB=(RECFM=FB,LRECL=80,BLKSIZE=3200)
//SYSDEFSD DD  DUMMY
//SYSOUT   DD  SYSOUT=*
//SYSPRINT DD  SYSOUT=*
//SYSIN2   DD  DUMMY
//*
//*-------------------------------------------------------------------
//* LINKEDIT STEP:
//*-------------------------------------------------------------------
//LKED   EXEC PGM=HEWL,REGION=1024K,COND=((8,LT,COMPILE),(8,LE,PLKED)),
//       PARM='&LPARM'
//*SYSLIB   DD  DSN=&LIBPRFX..SCEELKED,DISP=SHR
//SYSLIB   DD  DISP=SHR,DSN=&LIBPRFX..SCEELKED
//         DD  DISP=SHR,DSN=&LIBPRFX..SCEELKEX
//         DD  DISP=SHR,DSN=&LIBPRFX..SCEESPC
//         DD  DISP=SHR,DSN=&LIBPRFX..SCEERUN
//         DD  DISP=SHR,DSN=SYS1.CSSLIB
//SYSLIN   DD  DSN=*.PLKED.SYSMOD,DISP=(OLD,DELETE)
//         DD  DDNAME=SYSIN
//SYSLMOD  DD  DSN=&OUTFILE
//SYSUT1   DD  UNIT=SYSDA,SPACE=(32000,(30,30))
//SYSPRINT DD  SYSOUT=*
//SYSIN    DD  DUMMY
//*

Note: The PLINK member is empty and the LINK member just has 'NAME MYBIND(R)'.

Here is the JCL to run MYBIND:
Code:
//ROGERR1 JOB (05,555,55555,55555),'RUN BIND',
//             CLASS=A,MSGCLASS=H,MSGLEVEL=(1,1),
//             USER=ROGER,NOTIFY=&SYSUID,
//             REGION=56M,TIME=1440
//*
//H1     SET HOST='10.10.10.10'
//H2     SET HOSTPT='389'
//LGNDN  SET LOGINDN='cn=Barney Rubble,ou=people,dc=capitalware,dc=net'
//PWD    SET PASSWD='mypwd'
//*
//*
//RUN01    EXEC PGM=MYBIND,
//             PARM='&HOST &HOSTPT &LOGINDN &PASSWD'
//STEPLIB  DD DISP=SHR,DSN=ROGER.TEST.LOAD
//         DD DISP=SHR,DSN=SYS1.SIEALNKE
//SYSPRINT DD  SYSOUT=*
//*
//

Hope that helps.

Regards,
Roger Lacroix
Capitalware Inc.
_________________
Capitalware: Transforming tomorrow into today.
Connected to MQ!
Twitter
Back to top
View user's profile Send private message Visit poster's website
HenriqueS
PostPosted: Thu Dec 12, 2013 7:02 pm    Post subject: Reply with quote

Master

Joined: 22 Sep 2006
Posts: 235

Helped a lot!

In fact, IBM documentation made think on using SYS1.SIEALNKE(GLDCLDAP) on the link-editing, while it was only needed for runtime. This ended up corrupting the entry point of the executable.

Now I can focus on the logic.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » Mainframe, CICS, TXSeries » LDAP on mainframe
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.