Novell is now a part of Micro Focus

Developer Pointers

Articles and Tips: article

01 May 1996


Novell Directory Services Q & A

This month's issue of NDS Q&A focuses on the enhancements to the NetWare Directory Services API that allow connections to multiple NDS trees simultaneously. These APIs will be released to the production area of the NetWare SDK Release 7. The capability to connect to multiple trees must be supported by the underlying client software in order for these APIs to function successfully.

Q. I've heard Client 32 supports the capability to connect to multiple NDS trees simultaneously. What changes do I need to make to my NDS code to support multiple NDS tree logins?

A. The key to managing connections to multiple NDS trees simultaneously is setting a new context variable within the NDS context. The context handle (typed as NWDSContextHandle) references state information relevant to reading and writing information to and from NDS via the NDS APIs. An additional context variable named DCK_TREE_NAME has been added to allow the developer to specify the tree that the context handle references. This tree name variable is used to identify the tree to which all NDS requests will be sent.

Managing connections to multiple NDS trees involves creating a context handle (NWDSCreateContextHandle()) and setting the DCK_TREE_NAME for each context to the appropriate tree. The developer is responsible for managing the context handles and using them appropriately to ensure that NDS requests are directed to the appropriate NDS tree. Figure 1 is an example of how to set this context variable.

Figure 1: How to set the context variable

dscCode = NWDSCreateContextHandle(

        /* Context handle   */ &dContext&
        );



dscCode = NWDSSetContext(

        /* Context Handle   */ dContext,

        /* Key          */ DCK_TREE_NAME,

        /* Set Flag Value   */ "NDS_Tree_Name"

        );

Q. Now that Client 32 supports connections to multiple NDS trees, how can I enumerate the trees the client is currently connected to?

A. A new function has been added to the NWDS APIs called NWDSScanConnsForTrees()that provides this capability. This function will return a list of all NDS trees the client is connected to. The list does not include duplicates and is sorted according to the defined collation table. Figure 2 is an example of how to implement this function.

Figure 2: How to enumerate trees a client is connected to

dscCode = NWDSScanConnsForTrees(

        /* context          */ dContext,

        /* num of tree ptrs */ numOfPtrs,

        /* returned tree count  */ &numOfTrees,&
        /* array of tree names  */ NDSTrees

        );

Q. Can a default name context be associated with each tree in this multi-tree environment?

A. Yes. A new function has been added to the NWDS APIs called NWDSSetDefNameContext()that provides this capability. The context handle passed as the first parameter must have the DCK_TREE_NAME variable set to the appropriate tree.

A default name context will be associated with the tree referenced in the context handle. Figure 3 is an example of how to implement this function.

Figure 3: How to associate a default name context with each tree

dscCode = NWDSSetDefNameContext(

        /* context handle       */ dContext,

        /* name context length      */ strlen("O=NOVELL"),

        /* name context */ "O=NOVELL"

        );

Q. Is it necessary to obtain a connection to a file server (using NWCCOpenConnByName or NWCCOpenConnByAddress()) in the desired NDS tree before calling NWDSLogin()?

A. No. The Client 32 Requester uses the DCK_TREE_NAME value set in the context handle (passed as the first parameter to NWDSLogin()) to establish a connection to a server in the specified tree. Figure 4 is an example of the steps necessary to authenticate to an NDS tree.

Figure 4: How to authenticate to an NDS tree

dscCode = NWDSCreateContextHandle(

        /* Context handle   */ &dContext&
        );

/*-------------------------------

** Set the NDS tree value for THIS context

*/



dscCode = NWDSSetContext(

        /* Context Handle   */ dContext,

        /* Key          */ DCK_TREE_NAME,

        /* Set Flag Value   */ "NOVELL_INC"

        );



dscCode = NWDSSetDefNameContext(

        /* context handle   */ dContext,

        /* name context len */ strlen("O=NOVELL"),

        /* name context     */ "O=NOVELL"

        );



/*-------------------------------

** Set the Name Context for this context handle. Remember

** that NWDSSetDefNameContext() sets the default name

** context for the specified NDS TREE, while setting the

** DCK_NAME_CONTEXT sets the name context for this

** context handle.

*/



dscCode = NWDSSetContext(

        /* Context Handle   */ dContext,

        /* Key          */ DCK_NAME_CONTEXT,

        /* Set Flag Value   */ "O=NOVELL"

        );



dscCode = NWDSLogin(

        /* > Context        */ dContext,

        /* > Options flg    */ 0L,

        /* > object name    */ objectName,

        /* > password       */ "Happy Day",

        /* > Valid period   */ 0L

        );

Q. Will an application I've written using these new NWDS APIs for multiple NDS tree support still work when run on a machine that has the NetWare DOS Requester (VLMs) loaded?

A. Yes. These APIs function in identical fashion to the NWDS API functions that were designed for a single NDS tree environment and can be used to replace them. The NetWare DOS Requester software will establish a connection to an NDS server based on the PREFERRED TREE statement in the NET.CFG file. The first connection established to a NetWare 4.x server will be used. Only this NDS tree will be referenced by these new functions. Additional connections to NDS trees will not be allowed by the client software, so any attempts to do so using these new APIs will fail.

Q. What platforms are these multiple NDS tree APIs available on?

A. These APIs are available on Windows 95 with the Novell Client 32 software loaded, DOS/Windows 3.x with the Novell Client 32 software loaded, Windows NT with Novell Requester for NT software loaded, and NLM clients using modular CLIB. Client 32 for Windows 95 and the Novell Requester for Windows NT are available now. Client 32 for DOS/Windows is in beta. The modular CLIB that contains these new functions is slated for release on Release 8 of the Novell NetWare SDK.

Q. Does the NetWare DOS Requester (VLMs) support multiple NDS tree connections?

A. No.

Q. Which tree will legacy NDS applications use when running in an environment that supports multiple NDS tree connections?

A. Legacy NDS applications will use the current preferred NDS tree. The preferred NDS tree is initially established when client software (Client 32) loads. The value for the preferred NDS tree is read from the system registry (Client 32 for Windows 95 or the NetWare Requester for Windows NT) or from the Net.cfg (Client 32 for DOS/Windows 3.x). The preferred NDS tree can be changed using the function NWSetPreferredDSTree().

Q. Is there a function that will tell me whether the client is already authenticated to an NDS tree?

A. Yes. NWDSCanDSAuthenticate()can be used to determine whether authentication credentials exist for the DCK_TREE_NAME variable the context handle references. The credentials are established by calling NWDSLogin().

Q. Is there a function that can be used to enumerate all of the available NDS trees on the network?

A. Yes. NWDSScanForAvailableTrees()can be used to build a list of all the NDS trees available on the network.

Q. What function should I use to authenticate to a specific server in an NDS tree after I have already logged in to an NDS tree using NWDSLogin()?

A. The NWDS API function NWDSAuthenticateConn()should be used to authenticate to a specific server. The context handle, passed as the first parameter, is used to indicate which tree to use in authenticating the supplied connection handle. Figure 5 is an example of how to implement this function.

Figure 5: How to authenticate to a specific server when already logged in to a tree

if(NWDSCanDSAuthenticate(

        /* context handle       */ dContext

        ))

    {

    cCode = NWCCOpenConnByName (

        /* NWCONN_HANDLE        */ 0,

        /* pnstr8 -  server name    */  "Server_Happy_Day",

        /* NWCCNameFormat       */ NWCC_NAME_FORMAT_BIND,

        /* NWCCOpenState        */ NWCC_OPEN_LICENSED,

        /* NWCCReserved         */ NWCC_RESERVED,

        /* NWCONN_HANDLE        */ &connHandle&
        );



    dscCode = NWDSAuthenticateConn(

        /* context handle       */ dContext,

        /* connection handle        */ connHandle

        );

    }

Novell Completes Agreement with Sun Microsystems To Integrate Java with NetWare

Novell has finalized an agreement with Sun Microsystems, Inc. to license its Java platform for use with NetWare. As part of the agreement, Novell is authorized to offer its developers and customers access to the complete Java platform, including the core power of Java, the Java Virtual Machine.

Novell will use the Sun technology to create an execution environment on NetWare servers for Java applications that can be accessed and distributed across business intranets and the global Internet, regardless of the client platform.

Sun has expanded its licensing model for Java to allow licensees the right to provide full Java functional-ity to third-party software application developers. Novell will embed the Java Virtual Machine into Novell's NetWare operating system. As a result, Novell can provide the functionality of Java to its third-party software developers who in turn can create Java applications in NetWare.

"Java and NetWare make a powerful blend," said Drew Major, Novell's chief scientist. "NetWare and Java will provide developers with a complete foundation of network services on which to build distributed applications. Our ability to distribute the complete Java platform as an integrated part of the Novell Operations system will position us as the leader in offering exciting new options and opportunities to our developer community. Java will provide the next-generation application execution environment for NetWare, and NetWare will provide the next major application platform for Java."

By integrating the Java Virtual Machine and class libraries with NetWare, Novell becomes the source for Java Virtual Machine functionality for its developers and customers who are writing for NetWare.

Novell and Sun are exploring ways to extend Java class libraries, allowing application developers to include NetWare Directory Services (NDS), IPX, and other Novell network services in their distributed applications. Novell plans to integrate Java applications with NDS to support a client-network architecture in which application components, or objects, can be distributed across intranets and the Internet and accessed transparently.

"Novell's vision of Java applications hosted and accessed everywhere through NetWare servers is impressive," said Alan Baratz, president of JavaSoft, an operating company of Sun Microsystems, Inc. "With this agreement, Novell becomes one of the leaders in bringing the power of Java to business intranets."

Novell plans to incorporate Java in operating system and software development products during 1996.

JavaSoft is headquartered in Cupertino, Calif. The company's mission is to develop, market and support the Java technology and products based on it. JavaSoft develops applications, tools and systems platforms to further enhance Java as the programming standard for complex networks such as the Internet and corporate intranets.

JavaOne: Sun's Worldwide Java Developer Conference Sponsored by JavaSoft and Co-Sponsored by Novell When: May 29-31, 1996 Where: San Francisco's Moscone Center Cost: $995 Advance Registration $1195 On-site Registration How to register: Visit: http://java.sun.com/javaone Call: (USA) 415-578-6893 x6893 (ask for Adam Nie for group rates) (USA) 800-488-2883 x6893 (Intl) 415-578-6900 General Sessions will feature JavaSoft and Sun, with speakers such as Scott McNealy, Sun President and CEO. The program will include such sessions as the following: Technical Sessions Java Internals 1.0 Libraries Technical Overview Java in the Enterprise Cryptography & Security Future Java Technologies Advanced Tutorial: AWT Embedded Java Electronic Commerce Design Sessions Designing Reusable Applets VRML and Java UI Design JavaScript Multiuser Java Design for Client/Server Business and Strategy Sessions JavaSoft Business Roadmap Java & the Internet Desktop The Internet Players Java Markets: Entertainment Publishing Java Markets: Education Network Appliances: Strategy & Issues Revolutionizing Software Distribution

Novell Announces First Net2000 Deliverables

During its annual technical development conference, Novell. announced the first deliverables from its Net2000 developer initiative:

  • New Basic language scripting capabilities (see the accompanying article for details)

  • NetWare Directory Services (NDS) components that expose directory functionality

  • Component management services to distribute Object Linking and Embedding (OLE) components and Sun Microsystems' Java applets across global networks

With these Net2000 technologies, developers can easily create NetWare applications using popular scripting and common objects, then find and share those applications and objects across networks, including intranets and the Internet.

NDS Components Expose Directory Functionality

As part of Net2000, Novell is exposing its rich NDS functionality through OLE object custom controls, Visual Basic controls, and Delphi controls to increase object developers' access to core directory services.

Novell is providing sample utilities written in Visual Basic that demonstrate how to access NDS from the Net2000 NDS browser control to simplify directory and resource management. Sample utilities let network administrators change multiple passwords at once, update user login scripts, and change directory schema.

Discover and Access OLE Objects and Java Applets Across Networks

Through the Net2000 component management services based on NDS, security, and licensing technology, Novell will help developers access, secure, and manage distributed logic such as OLE objects, including Microsoft's ActiveX, and Java applets across networks. By registering components in the component management services, developers can easily share and publish logic across enterprise networks, including the Internet.

For example, a developer could create an object custom control to open a database and compile corporate sales figures. After the developer registered the object custom control in NDS, other developers throughout the company could find that object in NDS and bind it to their own application, adding new functionality without having the object reside on their local workstations.

Combining Net2000 and NDS to manage and access components, objects, and applets across networks delivers on the promise of NDS by enabling developers to track and manage logic as easily as files and resources.

Novell's JumpStart CD-ROM contains technical information about Net2000 (including BrainShare '96 presentations and white papers), as well as sample object custom controls, Basic scripts, and Net2000 component interfaces. It also includes a full copy of the NetWare Web Server with a 45-day Web Server license. Novell DeveloperNet subscribers will receive a copy of the CD-ROM. For more information, contact DeveloperNet at 1-800-RED-WORD or visit the Net2000 World Wide Web site (http://developer.novell.com/net2000).

Novell Enhances NetWare as a Development Platform

As part of its Net2000 developer initiative to deliver universal network access, Novell announced it is enhancing NetWare as a development platform by providing support for Basic scripting languages.

Using popular Basic scripting languages, including Visual Basic and NetBasic, developers and network administrators can create NetWare applications, NetWare Loadable Modules, and administration utilities and manage them across networks, including the Internet.

For the first time, developers and network administrators can use popular Basic scripting languages to take advantage of Novell's industry-leading NetWare Directory Services (NDS) and create NDS-enabled applications and administrative utilities. By giving developers access to NDS through scripting, Novell is delivering on its promise to ease access to NDS and to simplify application development.

Create New NetWare Applications

With Basic scripts, network administrators and developers can quickly build new network applications and NLMs that reside on NetWare servers.

For example, a network administrator could create a simple NLM to monitor NetWare server utilization and file usage. If utilization rises above a preset level, the NLM could page, fax and E-mail the administrator to highlight the potential utilization issue.

Basic scripts can also be created to query a database, such as an Oracle SQL DB, for specific information that can be returned to a user via an Internet browser or a Visual Basic application.

Manage and Automate NetWare Applications and NLMs

In addition to providing support for Basic development, Novell has enhanced the NetWare platform by licensing the Net2000 Network Management Extension (NMX) from HiTecSoft Corp. Net2000 NMX gives developers and administrators the capability to manage and automate script execution across all networks, including the Internet.

With Net2000 NMX, network administrators and developers can create custom logic that leverages existing NLMs. Using the Net2000 NMX, an administrator can automate specific network tasks by writing Basic scripts to query data-bases, monitor network servers, and load and unload NLMs. For example, a network administrator could build a script to query NDS and perform a specific backup service for a network user at a given time.

Extend the NetWare Web Server as a Development Platform

Through Net2000 NMX and the NetWare Web Server, developers and administrators can write Basic scripts to access NetWare Directory Services, databases, and NLMs across the Internet.

Developers can use any Web browser interface to access authorized NetWare servers to load, unload, update, and manage NLMs and execute custom Basic scripts across the Internet. This capability simplifies remote site network management by taking advantage of the Internet's infrastructure.

The Net2000 NMX component, HiTecSoft's NetBasic development tools, and Novell sample application and management utility scripts are available now on the Net2000 JumpStart CD-ROM. Developers can use this software on NetWare 3 and NetWare 4 platforms to begin building Basic scripts to automate NLM applications.

Novell and BEA Announce Strategic TUXEDO Partnership

Novell, Inc. and BEA Systems, Inc. of Sunnyvale, CA. have announced a strategic partnership to develop and distribute the TUXEDO System, the leading open transaction management software used by businesses to develop and deploy multi-tier, client/server applications.

Both companies will invest development resources to enhance and expand the TUXEDO product line. Novell's development focus will be to integrate TUXEDO with NetWare, including NDS and NetWare Connect Service for managed Internet services. BEA will be responsible for developing the features and utilities needed for enterprise line-of-business solutions running on UNIX, NT, and all other non-NetWare platforms.

Because traditional TUXEDO users on UNIX or NT develop custom line-of-business solutions, Novell chose to partner with BEA because they will dedicate the resources required from both a consulting and channel perspective.

Founded in 1995, BEA's mission is to deliver a distributed application framework, using enhanced transaction processing monitor technology, and professional services, to enable distributed mission-critical applications that can seamlessly work with both legacy and client/server environments.

Novell TUXEDO System Gains Support by Centura from Gupta Corporation

Novell recently announced support for the TUXEDO System by Centura Team Developer, a new application development tool for three-tier (client, application server, and data-base server), enterprise client/server applications from Gupta Corporation. Centura Team Developer, a new high-end development environment, incorporates wizard technology (pre-programmed routines for accomplishing a series of tasks) specifically designed to simplify the development of graphical applications accessing the services of three-tier client/server environments such as Novell's TUXEDO System. Together, TUXEDO System and Centura automate access to the services of enterprise applications for end users needing to more quickly and easily develop and deploy mission-critical applications.

Three-tier client/server computing is the preferred architectural approach for implementing reliable, scalable distributed applications. In a three-tier TUXEDO System environment, application service components are "advertised" and can be accessed by authorized requesters, such as desktop client applications. Centura simplifies access to these TUXEDO managed service components by automatically generating the interface and communication code connecting the client and service tiers. Centura's three-tier wizard, and the complementary Centura TUXEDO Deployment Suite, automate the generation of messages, service invocations, and underlying network connections, freeing developers to concentrate on business logic and the user's interface to the application.

Centura Team Developer is a development environment that enables customers to rapidly build high-end, graphical client applications. Increasingly, client applications are designed to access a wide array of mission-critical applications across public and private networks. Centura directly supports transparent integration with TUXEDO environments.

Automatic NetWare Crash Handler Released by Alexander LAN, Inc.

Alexander LAN, Inc. has begun shipping version 2.00 of the Alexander SPK (Server Protection Kit) for NetWare 3.11-Netware 4.1. Release 2.00 of the kit adds Edna 1.02, which automates the process of running diagnostics on a crashed server, restarting it, and creating an E-mail crash file for remote support. NetCheck and Dexter, also part of the kit, have been updated and now integrate with Edna.

The new Alexander SPK 2.00 is an automated NetWare server crash handler. It is comprised of three integrated products that protect NetWare 3.11-Netware 4.1 servers. Each product can be used independently. Together, however, they provide a comprehensive crash-prevention and diagnostic kit for NetWare servers.

This version of the Alexander SPK takes over the server when it crashes, runs diagnostics, restarts NetWare (optionally), and makes all crash details available for you to review, or to E-mail to Novell or a remote support engineer.

The three products comprising the Alexander SPK 2.00 are the following:

Edna 1.02

Edna (Emergency Diagnostics for the Network Administrator) automatically takes over the file server after a crash, runs diagnostics, and creates an .ECF (Edna Crash File) that contains details about the condition of the server at the time of the crash. An optional switch enables Edna to automatically restart the server, call upon vrepair if needed, and reestablish files server services. Edna will also create an optional E-mail filecomplete with a windows viewerthat you can send to Novell or another support provider for additional analysis.

Dexter 1.20

Dexter (Debugger EXTendER) provides post-mortem symbolic stack walking in addition to enabling you to explore the inner workings of the NetWare network operating system (NOS). It will show you the calls and events that led up to a crash, as well as what tasks were performed at those addresses.

NetCheck 2.10

NetCheck (originally created by Nu-Mega Technologies, Inc.) automatically traps memory corrupting NLMs, drivers, and NOS kernel code that would otherwise cause a server crash. Alexander LAN, Inc. has re-engineered NetCheck to support NetWare 3.11-NetWare 4.1 and to integrate with both Dexter and Edna.

Alexander SDK 2.00 runs on Intel 80386, 80486, and Pentium-based personal computers running Novell NetWare 3.11-NetWare 4.1. The SPK ensures high server performance: overhead is typically less than half of 1% and uses less the 250KB of RAM.

The Alexander SPK 2.00 sells for $698.00 (US) per server. It is available directly from Alexander LAN, Inc. or from resellers. For more information, call (603) 880-8800, or send E-mail to dirk@alexander.com.

Note: When NetWare users experience an emergency, they can contact Alexander LAN, Inc. directly and arrange to purchase the kit, which can then be E-mailed, complete with all files, over the Internet or CompuServe in minutes. The physical product will arrive, usually the next day, via Federal Express.

Novell Announces Network Telephony Development Tools

Novell recently announced the beta availability of a network telephony-based interactive voice response (IVR) development tool. As a result of the recently announced partnership with Voysys Corporation, Novell is delivering a tool set that simplifies development of turn-key, semi-custom, and custom voice solutions. These tools enable value added resellers (VARs) and system integrators (SIs) to develop and deliver voice solutions that allow customers to use their existing information systems through the telephone with an enhanced level of reliability and performance due to network telephony integration.

Small and medium-sized businesses can take advantage of VAR-generated applications to automate telephone delivery of common information such as product availability, store hours, price quotes, account balances, order status, and marketing programs. Departments within larger companies can create voice solutions for departmental purposes, without having to rely on central information system resources to create and maintain voice applications.

Novell is delivering the first IVR development tool, code-named Infomator, combining a visual application design environment with the Open Database Connectivity (ODBC) access standard and the Telephony Services API (TSAPI) call control standard. Applications are created using a form-oriented Windows environment that guides the developer through use of tool pallets and simple dialogue windows.

The final application is then generated into fully modifiable Visual Basic code that may be optionally enhanced by more sophisticated developers before final creation of the windows-based executable application. Because the final voice application utilizes a client/server model to access voice hardware and call control services, departments can maintain and update departmental voice applications while allowing corporate IS to manage shared call control and voice hardware.

Final product naming, packaging, pricing, and availability will be announced in the second quarter of 1996. To participate in the beta program, contact Novell through the corporate programs section of Novell's home page at http://www.novell.com.

Technical Insights

Q. What's happening with GWLIST-US?

A. The technology group LS-DEV-PERFECTFITSDK has been deleted and a new one, LS-DEV-GROUPWARE has been created.

Q. Will NetWare 4.1 handle the year 2000 date rollover correctly?

A. Yes. Check this column in the future for more information on this subject.

Q. What's happening with Btrieve and related products?

A. Btrieve Technologies Inc. (BTI) now owns Btrieve, XQL, Xtrieve, and NetWare SQL (which is now called Scalable SQL). BTI has a web site at http://www.btrieve.com.

Scheduling NLMs Across Multiple CPUs

NetWare SMP and NLMs

Q. Is it true that any multithreaded NLM can be scheduled across multiple CPUs without having been written as an "SMP-aware" application?

A. No. You may find that NLMs that do not take advantage of SMP do have very slightly better performance, but it is not because they are running on processors other than 0. Developers need to do a considerable amount of work to make NLMs scale to potential performance on SMP NetWare, and many areas will not currently allow NLMs to scale with significant performance increases. There are specific calls to migrate threads to secondary processors, to coordinate simultaneous access to memory resources, and to yield to the SMP kernel (still non-preemptive on specific processors.) Because semaphores are handled by SMP directly, you may see in MONITOR that threads from a non-SMP-aware application are migrating, or waiting on a semaphore. This is because SMP dictates that applications use SMP semaphores as opposed to NetWare semaphores when SMP is available. CLIB handles this dynamically with its semaphore calls. Otherwise, you would have two types of semaphores on two different kernels. So, while a thread is blocked on a semaphore, it will wait on the SMP kernel; however, as soon as the thread is released, the thread continues to run on the NetWare kernel on processor 0.

In order for a thread to be migrated to a processor other than 0, the thread must make the thr_yield_to_mp()API call (in CLIB, NWSMPThreadToMP()maps to this call). After a thread is migrated, it will be scheduled to run on a secondary processor; no control exists as to which processor the thread will be scheduled on through CLIB, but the OS has some support for binding threads to a specific processor. Once running on a secondary processor, the thread must still yield the processor to other processes by calling thr_yield()(in CLIB, ThreadSwitch()maps to this call).

SMP NetWare essentially provides two scheduling kernels on multi-processor hardware. The LAN driver portion of NetWare takes advantage of additional SMP resources including dynamically distributed interrupts and atomic memory access for LAN drivers written to the latest LSL specification. However, NCP, IPX, STREAMS, IP, and Disk Cache are not enabled in NetWare 4.10 SMP, but rather marshalledmeaning that every one of these processes runs strictly on processor 0 on the NetWare kernel. If a thread makes a call to these types of services, the thread is migrated back to the NetWare kernel to fullfill the request and then is rescheduled back to SMP. Additional services that have been enabled are IPXRTR.NLM from the MPR kit. Some areas of NetWare didn't make sense to enable, namely the disk driver (because the bottleneck is on the disk hardware channel).

There are many places where NLMs can be performance bound, either on I/O, disk, memory access, or CPU. Certain APIs available in CLIB can help NLMs that are bound on CPU or memory access, allowing NLMs that can benefit from their own cache management or processing to scale greatly on SMP.

In the case where an NLM is memory access bound, there are a few APIs that SMP-enabled applications can take advantage of. It could be that the NLM manages its database records in its own cache using direct FS calls to fill the cache and bypass NetWare's disk cache. In this way, database pages can be flushed and read into cache at the NLM's control. In SMP, a reader/writer lock can be used to increase performance to memory access because it allows multiple readers and single writer access at any given time period. Using a reader/writer lock, a database application could read several records into memory, and multiple readers could be looking up information. A separate process could handle indexing of the records, and access control is granted through the lock. When a writer needs to change a record, it asserts a writer access. It then waits until all readers are out of the protected memory area, makes the write, and then allows multiple readers back in. This provides multiple access/single write and scales performance. There are other types of locks to allow other types of memory access to be performed with atomic access in an efficient manner. When NLMs take advantage of these locks appropriately, they can utilize SMP resources better and get better scaling.

In the case of CPU-bound NLMs, each thread that needs to handle number crunching can be scheduled, and results can be passed back, with multiple CPUs crunching numbers at the same time. These could be key generators for example.

Mark Oberg DeveloperNet NLM Engineer

SNADS Gateway Synchronization on AS/400s

SNADS Gateway

Q. We can currently support directory synchronization with the use of the AS 400's shadowing capability. This lets me send messages to all of the users on the 400 side using that machine as a gateway (for naming purposes). The problem is that this is resource intensive on the 400 side. Can I get the SNADS Gateway to view multiple LUs (hence it will talk to the 400s individually in order to get the names and assume the burden of the synchronization process)? I seem to only be able to enter a single LU; thus I have to use that machine's shadowing capability to get all of the addresses.

A. This is working as designed. As you have noted, the gateway is architected to communicate with a single AS/400 and relies on shadowing to send and sync with other AS/400s. For most customers, scheduling directory sync in the "wee hours" avoids impacting normal message traffic. In very large configurations, it may be advantageous to install additional gateways to distribute this load.

Correlation DB Taking Hours to Check and Purge

SNADS Gateway

Q. There is a component of the SNADS Gateway called a Correlation DB. It is currently taking 1.1 hours to check it and 1.2 hours to purge every morning on my customer's system. I am trying to find out if they need it and if so, how to adjust its settings. The manual's description of it is as follows: Message Correlation is used to keep track of the status of incoming messages from foreign systems. Can you help?

A. This database is used by the gateway to correlate status messages between GroupWise and the foreign system. In ADmin, under Optional Gateway Settings, you'll find Message Correlation options. Correlation may be disabled or the correlation age value may be adjusted to allow the customer determine how many days worth of this data is retained. On very busy systems, it may be necessary to reduce the time entries are kept. If final status hasn't been "correlated" before the correlation entries expire, no real harm will occur; the message status simply won't be updated. The default values of Enabled and 14 days may result in the accumulation of too much data in busy systems. If the database is causing problems, it may be deleted with no side effect except the loss of status correlation for messages with pending status.


Disclaimer

The origin of this information may be internal or external to Novell. While Novell makes all reasonable efforts to verify this information, Novell does not make explicit or implied claims to its validity.

© Copyright Micro Focus or one of its affiliates