LM_PERROR(3)

NAME
lm_perror, lm_errstring, _lm_errno - lm_client error messages

SYNOPSIS
lm_perror(s)
char *s;

char *lm_errstring(err)
int err;

int _lm_errno;

DESCRIPTION
lm_perror() produces a short error message on standard error describing the last error encountered during a call to a FLEXlm client function. lm_perror() prints a message in the same format as the standard system call perror() : the string pointed to by s (if not NULL), a colon and space, the error message (based on _lm_errno), and a newline.

lm_errstring() returns the error string corresponding to the err parameter. This is the same string as is printed by lm_perror. The error string is either a FLEXlm or a Unix error string.

If _lm_errno is a positive number, this represents a Unix error, and the corresponding Unix error string is printed. If _lm_errno is a negative number, this represents a FLEXlm error, and the corresponding FLEXlm error string is printed.

NOTES

The _lm_errno variable is set when an error occurs, but is not cleared when functions succeed. If you are going to check _lm_errno after calling a FLEXlm function, you should first clear _lm_errno before calling the function.
FLEXlm status return values
-1	NOCONFFILE
	"cannot find license file",
	The license file cannot be opened.  FLEXlm will attempt
	to open the standard file (/usr/local/flexlm/licenses/license.dat),
	or the file specified by the vendor (via lm_setup() or
	lm_set_attr()), or the file specified by the user
	in LM_LICENSE_FILE.
-2	BADFILE
	"invalid license file syntax",
	A feature name is > MAX_FEATURE_LEN.
	A daemon name is > MAX_DAEMON_LEN.
	A server name is > MAX_SERVER_NAME.
	A feature specifies no hostid and # of licenses is <= 0.
-3	NOSERVER
	"cannot connect to a license server",
	The daemon name specified in the license file FEATURE line
	does not match the vendor daemon name.
-4	MAXUSERS
	"licensed number of users already reached",
	The licenses number of users has been reached.
-5	NOFEATURE
	"no such feature exists",
	The feature could not be found in the license file.
	A call was made to one of the software license working
	group usage metering functions (um_xxx_record()).
-6	NOSERVICE
	"no TCP "license" service exists",
	This happens if a SERVER line does not specify a TCP/IP
	port number, and the TCP license service does not exist
	in /etc/services.
-7	NOSOCKET
	"no socket connection to license manager server",
	lm_disconn() was called after the process had been disconnected
	from the socket.  This error can also occur if an internal
	error happens within l_sndmsg() or l_rcvmsg().
-8	BADCODE
	"encryption code in license file is inconsistent",
	The code in a license file line does not match the other data
	in the license file.  This is usually the result of not
	building all the software components with the same
	encryption code.  Check create_license.c, ls_vendor.c,
	and your application code carefully to insure that
	they are all built with the same vendor code.
-9	NOTTHISHOST
	"invalid host",
	The hostid specified in the license file does not match the
	node on which the software is running.
-10	LONGGONE
	"feature has expired",
	The feature has expired, i.e., today's date is after the
	expiration date in the license file.
-11	BADDATE
	"invalid date format in license file",
	The start or expiration date in the license file is invalid.
-12	BADCOMM
	"invalid returned data from license server",
	The port number returned from lmgrd is invalid.
	An attempted connection to a vendor daemon did not result in
	a correct acknowledgement from the daemon.
	The daemon did not send back a message within the timeout interval.
	A message from the daemon had an invalid checksum.
	An lm_userlist() request did not receive the correct data.
-13	NO_SERVER_IN_FILE
	"no SERVER lines in license file",
	There is no SERVER line in the license file.  All non-zero
	license count features need at least one SERVER line.
-14	BADHOST
	"cannot find SERVER hostname in network database",
	The gethostbyname() system call failed for the SERVER nodename
	in the license file.
-15	 CANTCONNECT
	"cannot connect to license server",
	The connect() system call failed, while attempting to connect
	to the daemon.
	The attempt to connect to the vendor daemon on all SERVER
	nodes was unsuccessful.
	lm_status() returns CANTCONNECT if the feature had been checked
	out but the program is in the process of reconnecting.
	If reconnection fails, the final status return is CANTCONNECT.
-16	CANTREAD
	"cannot read data from license server",
	The process cannot read data from the daemon within the
	timeout interval.
	The connection was reset by the daemon (usually because the
	daemon exited) before the process attempted to read data.
-17	CANTWRITE
	"cannot write data to license server",
	The process could not write data to the daemon after the
	connection was established.
-18	NOSERVSUPP
	"license server does not support this feature",
	The feature has expired (on the server node), or has not
	yet started, or the version is greater than the highest
	supported version.
-19	SELECTERR
	"error in select system call",
	The select() system call failed.  This should never happen in
	a client program.
-20	SERVBUSY
	"license server busy (no majority)",
	The license server is busy establishing a quorum of server
	nodes so that licensing can start.  This request should
	be retried.
-21	OLDVER
	"license file does not support this version",
	The version requested is greater than the highest version
	supported in the license file FEATURE line.
-22	CHECKINBAD
	"feature checkin failure detected at license server",
	The checkin request did not receive a proper reply from the
	vendor daemon (the license might still be considered in use).
-23	BUSYNEWSERV
	"license server temporarily busy (new server connecting)",
	The vendor daemon is in the process of establishing a quorum
	condition.  New requests from clients are deferred during this
	period.  This request should be retried.
-24	USERSQUEUED
	"users are queued for this feature",
	This error is similar to MAXUSERS, but supplies the additional
	information that there are other users in the queue for this
	feature.
-25	SERVLONGGONE
	"license server does not support this version of this feature",
	The version specified in the checkout request is greater than the
	highest version number the daemon supports.
-26	TOOMANY
	"request for more licenses than this feature supports",
	A checkout request was made for more licenses than are supported in
	the license file.  This request will never succeed.
-27	CANTREADKMEM
	"cannot read /dev/kmem",
	The file /dev/kmem is not readable on this system.  This error
	will only occur if using extended hostid checking.
-28	CANTREADVMUNIX
	"cannot read /vmunix",
	The file /vmunix is not readable on this system.  This error
	will only occur if using extended hostid checking.
-29	CANTFINDETHER
	"cannot find ethernet device",
	The ethernet device could not be located on this (VMS) system.
-30	NOREADLIC
	"cannot read license file",
	The license file could not be read (errno == EPERM or EACCES).
-31	TOOEARLY
	"feature not yet available",
	The feature is not enabled yet (current date is before the
	feature start date).
-32	NOSUCHATTR
	"No such attribute",
	A call to lm_get_attr() or lm_set_attr() specified an unknown
	attribute code.
-33	BADHANDSHAKE
	"Bad encryption handshake with daemon",
	The client performs an encryption handshake operation with
	the daemon prior to any licensing operations.  This handshake
	operation failed.
-34	CLOCKBAD
	"Clock difference too large between client and server",
	The date on the client system does not agree closely enough with
	the date on the server (daemon) system.  The amount of difference
	allowed is set by the software vendor with lm_set_attr by modifying
	the LM_A_MAX_TIMEDIFF parameter.
-35	FEATQUEUE
	"In the queue for this feature",
	This checkout request has resulted in the process being placed in
	the queue for this feature.  Subsequent calls to lm_status()
	will yield the status of this queued request.
-36	FEATCORRUPT
	"Feature database corrupted in daemon",
	The daemon's run-time feature data structures have become
	corrupted.  This is an internal daemon error.
-37	BADFEATPARAM
	"Duplicate selection mismatch for this feature",
	The checkout request for this feature has specified a duplicates
	mask that does not match the mask specified by an earlier
	checkout. This is probably the result of using different versions
	of your client software.
-38 	FEATEXCLUDE
	"User/host on EXCLUDE list for feature",
	The user/host/display has been excluded from this feature by
	an end-user's daemon option file.
-39 	FEATNOTINCLUDE
	"User/host not on INCLUDE list for feature",
	The user/host/display has NOT been included in this feature by
	an end-user's daemon option file.
-40 	CANTMALLOC
	"Cannot allocate dynamic memory",
	The malloc() call failed to return sufficient memory.  This can
	happen while reading the features from the license file (especially
	if the user has an extremely long LM_LICENSE_FILE path set).
-41 	NEVERCHECKOUT
	"Feature was never checked out"
	This code is returned by lm_status() if the feature requested
	has never been checked out.
-42	BADPARAM
	"Invalid parameter"
	A call to lm_set_attr() specified an invalid value for its attribute.
-43	NOKEYDATA
	"No FLEXlm key data supplied in lm_init() call",
	No FLEXlm key data was supplied to the lm_init() call.  Some FLEXlm
	functions will be disabled.
-44	BADKEYDATA
	"Invalid FLEXlm key data supplied",
	Invalid FLEXlm key data was supplied to the lm_init() call.  Some FLEXlm
	functions will be disabled.
-45	FUNCNOTAVAIL
	"FLEXlm function not available in this version",
	This FLEXlm function is not available.  This could be a result of a
	BADKEYDATA, NOKEYDATA, or DEMOKIT return from lm_init().
-46	DEMOKIT
	"FLEXlm software is demonstration version",
	lm_init() returns this code when the FLEXlm vendor keys supplied
	indicate that this is a DEMO kit.  Note that this means that FLEXlm
	functionality WILL EXPIRE.
-47	NOCLOCKCHECK
	"Clock setting check not available in daemon"
	lm_checkout() returns this code when the CLOCK SETTING check between
	client and daemon is not supported in this daemon.  Try calling:
			lm_set_attr(LM_A_MAX_TIMEDIFF, -1)
	to disable the clock check.