You can check the permissions of the appxLoginMgr command by running the following command:cd /usr/local/appx/tools chown root appxLoginMgr chgrp appxgrp appxLoginMgr chmod 4775 appxLoginMgr
The recommended permissions should be as follows:ls -l appxLoginMgr
-rwsrwxr-x 1 root root 636843 Jul 11 07:31 appxLoginMgr
[root@tubes tools]# service appxd-8060 status up and running (process 13893 servicing port 8060)
-Umask=FILECREATIONMASKSynopsis - Service Configuration
The appxLoginMgr service configuration commands are used to create, configure, and remove an instance of an APPX Connection Service. appxLoginMgr -install -SockPort=[TCP-Port] [options]... [VARIABLE=VALUE]... appxLoginMgr -modify -serviceName=SERVICENAME [options]... [VARIABLE=VALUE]... appxLoginMgr -replace -serviceName=SERVICENAME [options]... [VARIABLE=VALUE]... appxLoginMgr -remove -serviceName=SERVICENAMEConfiguration - Commands
-install -name=SERVICENAME [options]... [VARIABLE=VALUE]... -install -port=PORT [options]... [VARIABLE=VALUE]...-modify -name=SERVICENAME [options]... [VARIABLE=VALUE]...The -install command is used to configure a new instance of an APPX Connection Service. Either form of the install command may be used.The first form of the -install command requires only that a service name be specified. All other options are optional including the TCP/IP port. Any option not specified will be configured with an appropriate default value. The second form of the -install command requires only that a TCP/IP port be specified. All other options are optional including the <nop>ServiceName. Any option not specified will be configured with an appropriate default value. Both forms of the -install command allow additional configuration options to be specified. The configuration options specified are stored in the service configuration file (ini). Both forms of the -install command optionally allow values to be specified for environment variables. If specified, the environment variables and their values are stored in the environment configuration file (env). The environment variables in the environment configuration file will be set for any APPX sessions which are started by the connection service. In addition to creating the service configuration file and the environment configuration file, the -install command also creates an operating system service that will be automatically started when the computer system is started. After creating the configuration files and the operating system service, the -install command starts the service.The -modify command is used to modify the configuration of an existing Connection Service. The specified options will be updated in the service configuration files. Any options not specified will not be changed. After updating the configuration files, the -modify command restarts the service. Note that when specifying variables on the command line, you must prefix them with a dash if you are referring to settings such as SSLmode, or without a dash if you are referring to environment variables, such as APPX_KEYMAP. Note that the -modify command updates the service configuration file and the environment configuration file by removing the old files and creating new files with the updated options and environment variables. Any comments that may have been manually added to these configuration files are not preserved.-replace -name=SERVICENAME [options]... [VARIABLE=VALUE]...The -replace command is used to replace an existing Connection Service with a new Connection Service with the same name. The -replace command is effectively the same as a -remove command followed by an -install command. After updating the configuration files, the -replace command restarts the service. Note that when specifying variables on the command line, you must prefix them with a dash if you are referring to settings such as SSLmode, or without a dash if you are referring to environment variables, such as APPX_KEYMAP.-remove -name=SERVICENAMEThe -remove command is used to remove an existing Connection Service. The -remove command will remove the configuration files (ini and env) and the corresponding operating system service. If the service is running when the -remove command is executed, the -remove command will first stop the service and then remove the service.Configuration - Options
-ImpersonateGID={true, false}Options - General
-name, -ServiceName=SERVICENAMEThe <nop>ServiceName uniquely identifies an APPX connection service. When creating (installing) a connection service, the SERVICENAME value may be any string value that conforms to the rules for valid filenames on your server. If this option is omitted when a connection service is being created, the connection service will be created with a default <nop>ServiceName based on the following template: "appxd-" followed by the specified TCP/IP port number, e.g "appxd-8060".-DisplayName=DISPLAYNAMEThe <nop>DisplayName is a "user-friendly" descriptive name for a connection service. The DISPLAYNAME value will appear in your system's Services control panel and will be displayed by the ps command. If you don't specify a DISPLAYNAME when a connection service is being created, the connection service will be created with a DISPLAYNAME based on the SERVICENAME.-engine, -AppxExecutable={../appx, PATHNAME}This option identifies the PATHNAME of the APPX engine that is to be run when initiating an APPX session. The specified PATHNAME may be alsolute or it may be relative to directory in which the service configuration file (ini) for the connection service is located. If this option is not specified, the default PATHNAME of "../appx" is used to initiate an APPX session.-LogDirectory={/tmp, LOGDIR}When the service is started, two log files are created in the LOGDIR directory - a connection service log file (.log) and a status file (.stat). Both log files have the same name as the <nop>ServiceName but one has a file extension of .log and the other has a file extension of .stat. If the <nop>LogDirectory option is not specified, the log files are created in the /tmp directory.-AM, -AuthenticationMethod={OS-User, Appx-User, HT-User(HTFILENAME)}This option identifies the method by which the user ID and the password are to be validated when a connection request is received. If 'OS-User' authentication is specified, the user ID and the password are validated by the connection service using the operating system's authentication service. If 'Appx-User' authentication is specified, the user ID and the password are validated by APPX using the user file which is maintained in APPX System Administration. If 'HT-User(HTFILENAME)' authentication is specified, the user ID and the password are validated by the connection service using the HTFILENAME file is maintained with the htpasswd utility. If you specify 'Appx-User' authentication or HT-User authentication, the user being validated does not need an OS user account. If no authentication method is specified, the default authentication method is OS-User.-ServiceType=LoginThe only valid value when configuring a Connection Service is "Login". If this option is not specified, the default value is Login.-ServiceDisable={true, false}This option can be used to temporarily disable or "turn off" the connection service. If set to true, the connection service will still run but it will not accept login requests.-ServiceDisableLogin={true, false}This option can be used to disable or "turn off" processing of login requests from interactive clients. If set to true, login requests from interactive clients will not be processed.-ServiceDisableFMS={true, false}This option can be used to disable or "turn off" processing of connection requests from APPX/Net connections including the Windows APPX/ODBC driver. If set to true, connection requests from APPX/Net clients will not be processed.-ServiceDisableAppxKeys={true, false}This option can be used to disable the ability to define an APPX keymap. If set to true, those interactive clients which support the ability to define an APPX keymap will not be allowed to do so.-initScript={lsb, <nop>RedHat}Used with -install option to specify the type of operating system that the service script is to be created for. If this option is not specified, appxLoginMgr will determine which type of service script to install.Options - Session Identity/Permissions
-ImpersonateUID={true, false}If this value is set to false, an APPX session which is initiated by the connection service will run as the user of the connection <nop>ServiceOwner. Set this value to true if you want the APPX session to run with the permissions of a user (impersonate) other than the user of the connection service. If this value is set to true, then the <nop>ImpersonateUser option determines which user the APPX session should impersonate.-ImpersonateUser={LogonUser, <nop>NamedUser(USERID), <nop>ServiceOwner}This option determines which O/S user the APPX session should impersonate (run as).If <nop>LogonUser is specified, the user ID of the APPX session will be set to the user ID that was provided by the client login. This user ID must be a valid O/S user. The connection service must be running with the permissions of the root user if the <nop>LogonUser option is specified. If <nop>NamedUser is specified, the user ID of the APPX session will be set to the specified USERID. This USERID must be a valid O/S user. The connection service must be running with the permissions of the root user if the <nop>NamedUser option is specified. If <nop>ServiceOwner is specified, the user ID of the APPX session will be the user ID that the connection service is running as.If this value is set to false, an APPX session which is initiated by the connection service will run with the group permissions of the connection <nop>ServiceOwner. Set this value to true if you want the APPX session to have group permissions based on the <nop>ImpersonateGroup option.-ImpersonateGroup={User, <nop>LogonUser, <nop>LogonGroup, <nop>NamedGroup(GROUPNAME), <nop>ServiceOwner, <nop>ServiceGroup}This option determines which group permissions the APPX session should run with.If User is specified, the APPX session will run with the group permissions of the user that the session is running as (impersonating). If <nop>LogonUser or <nop>LogonGroup is specified, the APPX session will run with the group permissions of the user ID that the client provided in conjunction with the connection request. The user ID must be a valid O/S user. If <nop>NamedGroup is specified, the group permissions of the APPX session will be set to the specified GROUPNAME. This GROUPNAME must be a valid O/S group. If <nop>ServiceOwner or <nop>ServiceGroup is specified.
When a file is created, the default permissions set by Unix/Linux are 666 (-rw-rw-rw-). When a directory is created, the default permissions set by Unix/Linux are 777 (drwxrwxrwx). If the umask option is specified, the FILECREATIONMASK value will modify the default permissions of files or directories that are created by the APPX session. The value of FILECREATIONMASK must be a decimal, hex, or octal number whose bits will be used to mask or turn off the corresonding bits of the default file creation permissions. For example, if you want files to be created with permissions of 644, the appropriate FILECREATIONMASK value would be 022 (octal). If you want files to be created with the default permissions of 666, the appropriate FILECREATIONMASK value would be 000 (octal). For more information on umask values, please refer to your Unix/Linux system documentation.If the umask option is not set, files and directories that are created by the APPX session will be given the default permissions of the Service Owner. -IncludeSystemEnv={true, false}
Set this option to true if you want the APPX sessions which are initiated by the connection service to inherit the environment of the connection service.
Set this option to true if you want to allow the client to specify a startup process. Set this option to false if you do not want to allow the client to specify a startup process. If set to true, then any APPX startup process that may have been specified by the client will be invoked when the connection with the APPX session is established. If set to true, then any startup process that is specified by the client will take precedence over any startup process that may have been specified in the connection service configuration. If the option is not specified, the default value is true.-AppxDatabase=DATABASEID
This option must be specified if the connection service is being configured to invoke a specific startup process when a client session is initiated. If specified, the DATABASEID must be valid, i.e. it must be defined in the Databases file in APPX System Administration.-AppxApplication=APPLICATIONID
This option must be specified if the connection service is being configured to invoke a specific startup process when a client session is initiated. If specified, the APPLICATIONID must be valid, i.e. it must be defined in the Applications file in APPX System Administration. The specified APPLICATIONID must also be identified in APPX System Administration as a related application for the specified DATABASEID.-AppxProcessType={Menu, Job, Input, Output, Update, Action, Inquiry, Query, Status, Subroutine}
This option must be specified if the connection service is being configured to invoke a specific startup process when a client session is initiated. This option identifies the type of process that is to be invoked when a client session is initiated.-AppxProcessName=PROCESSNAME
This option must be specified if the connection service is being configured to invoke a specific startup process when a client session is initiated. This option identifies the name of the process that is to be invoked when a client session is initiated. The PROCESSNAME must be of the type specified and must be defined in the specified APPX Application.
Configure the service to listen for connection requests on the specified TCP/IP PORT number. This option is required with the -install option. You may choose any TCP/IP PORT number that is not reserved or already being used on your system.-TCPNoDelay={true, false}
This option is used to tune the network performance of the APPX session. When set to true, TCP will send partially filled packets of data rather than wait for a packet to fill before sending it. This can result in improved interactive response time for the APPX session but will likely increase the number of data packets being transmitted over the network.-TCPEnableKeepAlive={true, false}
Set this option to true if you want an APPX session to be able to detect that the connection between an APPX session and an APPX client has been lost. If this option is set to true and an APPX session has been waiting for a response from an APPX client for the length of time specified by <nop>TCPKeepIdle, then the APPX session will attempt to contact the APPX client to see if it can still be reached. If the APPX client cannot be contacted, then the APPX session will attempt to contact the APPX client every <nop>TCPKeepInterval seconds up to <nop>TCPKeepCount times. After <nop>TCPKeepCount attempts, if the APPX client is unable to be contacted, then the APPX session terminates.-TCPKeepIdle={300, SECONDS}
This option is used to set the number of seconds that an APPX session is to wait for a response from an APPX client before checking to see if the client can still be contacted.-TCPKeepCount={8, COUNT}
This option is used to set the number of times that an APPX session is to attempt to contact a non-responsive APPX client before the APPX session should terminate.-TCPKeepInterval={60, SECONDS}
This option is used to set the number of seconds that an APPX session is to wait between attemps to contact a non-responsive APPX client.
This option is used to control whether or not APPX clients must use SSL connections.required - APPX clients must request an SSL connection disabled - APPX clients may only request a plain text connection -TrustedCAFile=CAFILENAMEoptional - APPX clients may request either an SSL connection or a plain text connection
This option identifies the pathname of the file that identifies which client certificates to trust (leave blank if client certificates are not required).-ServerCertificateFile=CERTFILENAME
This option identifies the pathname of the server's X509 certificate (leave blank for anonymous connections).-ServerPrivateKeyFile=KEYFILENAME
This option idenfies the pathname of server's private key file (unlocks the <nop>ServerCertificateFile).-RequireSSL={true, false}
This option is not needed and has not been implemented.-RequireSSLClientCertificates={true, false}
This option is not needed and has not been implemented.-ServerPrivateKeyPassphrase=PASSPHRASE
This option is not needed and has not been implemented.
VARIABLE=VALUEYou can include a space-separated list of environment variables at the end of the command line when you use the -install option. These environment variables will be saved in the env file that is created and will be given to the environment of the appx sessions that are started by the Login Manager. Note that when specifying variables on the command line, you do not prefix them with a dash if you are referring to environment variables.
appxLoginMgr [-start | -stop | -restart | -status] {SERVICENAME | -serviceName=SERVICENAME}MANAGEMENT OPTIONS
-start | < blank >-stopStart an instance of the Login Manager service using the configuration information in the SERVICENAME.ini and the SERVICENAME.env files.
Stop the instance of the Login Manager service that was started with the SERVICENAME.ini file.-restart
Restart (stop and then start) the instance of the Login Manager that was started with the SERVICENAME.ini file.-status
Report the status of the instance of the Login Manager that was started with the SERVICENAME.ini file.EXAMPLES Example 1: Configure and start a new instance of the Connection Service that will listen for connection requests on port 8060: appxLoginMgr -install -port=8060
appxLoginMgr -install -port=8060 -name=appx8060 -displayName="Appx-Production(8060)" -engine=/usr/local/appx/appx APPXPATH=c:\appx\data APPX_KEYMAP=WINDOWS Display the status of an instance of the Connection Service: appxLoginMgr -status appx8060 Shutdown a running instance of the Connection Service: appxLoginMgr -stop appx8060 Start a previously configured instance of the Connection Service: appxLoginMgr -start appx8060 Modify a setting and an environment variable of an existing service appxLoginMgr -modify -name=appx8060 -SSLMode=required APPX_KEYMAP=WindowsWarning - the engine that you named has the setuid bit enabled you may not want that bit set for the authentication method that you have chosen (OS-User) To turn off the setuid bit, chmod u-s ../appx Configuration written to: appxd-8060.ini Environment written to: appxd-8060.envtten to: /etc/rc.d/init.d/appxd-8060
# Appx connection manager configuration file # # You can change this file by hand, or # use the uappxd program for better results # # blank lines are ignored # # anything following a '#' is treated as a comment # # case is not important on the left-hand side # properties whose descriptions end in a '?' are # boolean and should be set to true or false # -------------------------------------------------- # AppxApplication = #startup application for spawned engines # AppxDatabase = #startup database for spawned engines AppxExecutable = /usr/local/appx/appx #pathname to Appx engine # AppxProcessName = #startup process name for spawned engines # AppxProcessType = #startup process type for spawned engines AuthenticationMethod = OS-User #authentication method (OS-User, Appx-User, HT-User(filename)) DisplayName = Login-8430 #descriptive name ImpersonateGID = true #change effective grouo ID for spawned engines? ImpersonateGroup = NamedGroup(appxgrp) #[LogonUser, NamedGroup(groupname), ServiceOwner] ImpersonateUID = true #change effective user ID for spawned engines? ImpersonateUser = NamedUser(appx) #[LogonUser, NamedUser(username), ServiceOwner] # IncludeSystemEnv = true #include service environment variables in spawned engines? # LogDirectory = /tmp #directory where log file should reside # LogNamePattern = /tmp/appxlog%N.xml #audit log filename pattern (see man strftime for details # LogRotationInterval = 86400 #number of seconds between audit log rotations # LogRotationSize = 1G #maximum audit log file size # RequireSSL = false #Require SSL-secured connections? # RequireSSLClientCertificates = false #require SSL-client certificates? # ServerCertificateFile = #pathname of server's X509 certificate (leave blank for anonymous connections # ServerPrivateKeyFile = #pathname of server's private key file (unlocks the ServerCertificateFile) # ServerPrivateKeyPassphrase = #passphrase that unlocks ServerPrivateKeyFile # ServiceDisable = false #disable this service? # ServiceDisableAppxKeys = false #disable keyboard mapping? # ServiceDisableFMS = false #disable AppxNET connections? # ServiceDisableLogins = false #disable interactive logins? # ServiceEnableCmds = true #allow client-side startup options? ServiceName = appxd-8430 #name of service ServiceType = login #service type (login or logmonitor) SockPort = 8430 #port number to service # SSLMode = optional #SSL connection type (optional, required, disabled) # TCPEnableKeepAlive = true #Enable TCP dead-connection detection # TCPKeepCount = 8 #Maximum number of keep-alive pings # TCPKeepIdle = 300 #Idle time before ping sent to client (in seconds) # TCPKeepInterval = 60 #Interval between keep-alive pings # TCPNoDelay = true #disable TCP packet filling delay? # TrustedCAFile = #determines which client certificates to trust # Umask = #umask (file creation mask) given to spawned engines
# Appx connection manager environment variables # # The entries in this file will become # environment variables in the engines # spawned by this service # # blank lines are ignored # # anything following a '#' is treated as a comment # # letter case IS important in this file # -------------------------------------------------- APPX_KEYMAP=WINDOWS
appxd-8430 running as process 28192 Effective User ID 0 Real User ID 0 Configuration values follow *Daemonize = true *DontForkEngine = false *InitScriptStyle = *SleepAfterFork = AppxApplication = AppxDatabase = AppxExecutable = ../appx AppxProcessName = AppxProcessType = AuthenticationMethod = OS-User DisplayName = appxd-8430 ImpersonateGID = true ImpersonateGroup = User ImpersonateUID = true ImpersonateUser = LogonUser IncludeSystemEnv = true LogDirectory = /tmp LogNamePattern = /tmp/appxlog%N.xml LogRotationInterval = 86400 LogRotationSize = 1G RequireSSL = false RequireSSLClientCertificates = false ServerCertificateFile = ServerPrivateKeyFile = ServerPrivateKeyPassphrase = ServiceDisable = false ServiceDisableAppxKeys = false ServiceDisableFMS = false ServiceDisableLogins = false ServiceDisableODBC = ServiceEnableCmds = true ServiceName = appxd-8430 ServiceType = login SockPort = 8430 SSLMode = Optional TCPEnableKeepAlive = true TCPKeepCount = 8 TCPKeepIdle = 300 TCPKeepInterval = 60 TCPNoDelay = true TrustedCAFile = Umask = Environment variables follow APPX_KEYMAP = WINDOWS
*Daemonize = true *DontForkEngine = false *InitScriptStyle = *SleepAfterFork = AppxApplication = AppxDatabase = AppxExecutable = ../appx AppxProcessName = AppxProcessType = AuthenticationMethod = OS-User DisplayName = appxd-8430 ImpersonateGID = true ImpersonateGroup = User ImpersonateUID = true ImpersonateUser = LogonUser IncludeSystemEnv = true LogDirectory = /tmp LogNamePattern = /tmp/appxlog%N.xml LogRotationInterval = 86400 LogRotationSize = 1G RequireSSL = false RequireSSLClientCertificates = false ServerCertificateFile = ServerPrivateKeyFile = ServerPrivateKeyPassphrase = ServiceDisable = false ServiceDisableAppxKeys = false ServiceDisableFMS = false ServiceDisableLogins = false ServiceDisableODBC = ServiceEnableCmds = true ServiceName = appxd-8430 ServiceType = login SockPort = 8430 SSLMode = Optional TCPEnableKeepAlive = true TCPKeepCount = 8 TCPKeepIdle = 300 TCPKeepInterval = 60 TCPNoDelay = true TrustedCAFile = Umask = createListener complete - listening on port 8430 CAppxD::Run starting handleClients - starting handleClients - waiting
Usage (service)
Synopsis - service Command
service [serviceName] [start|stop|restart|status]
ServerPrivateKeyFile =/usr/local/appx/tools/tubes.internal.appx.com.private.keyExample of openssl command to create private key:
openssl genrsa -out tubes.internal.appx.com.private.key 1024
ServerCertificateFile =/usr/local/appx/tools/tubes.internal.appx.com.crtExample of openssl command to create SSL certificate:
openssl req -new -days 365 -key tubes.internal.appx.com.private.key -x509 -out tubes.internal.appx.com.crt
Warning - the engine that you named has the setuid bit enabled, you may not want that bit set for the authentication method that you have chosen (OS-User) To turn off the setuid bit, chmod u-s ../appx
/etc/init.d/appxd-8060: line 39: success: command not found
/etc/init.d/appxd-8060: line 39: failure: command not found
/etc/init.d/appxd-8060: line 43: failure: command not found
(-) ./appxLoginMgr -modify appxd-8060 -TCPNodelay=false
Warn users not to move configuration files. A service script is created in the /etc/init.d system directory for each service installed by running the appxLoginMgr command. These scripts reference the corresponding service configuration files using a fully qualified absolute pathname. If you move the configuration files to another directory or rename them, the service scripts will no longer work. We should probably warn via screen notice on service creation, and document inside the .ini and .env files that if the .ini, .env and appxLoginMgr/appxAuditLogger are move or renamed, then the /etc/init.d system startup script will fail to work. The service scripts also reference the appxLoginMgr command using a fully qualified absolute pathname.
RequireSSL is not a valid parameter and should be removed from the configuration file.
RequireSSLClientCertificates is not a valid parameter and should be removed from the configuratoin file.
ServerPrivateKeyPassphrase is not a valid parameter and should be removed from the configuration file.