Auto Creation of Linux Home Directories for SAS Users

In a previous post I’ve described a method for configuring Active Directory Authentication for SAS® on Linux (with realmd). One of the packages that’s installed is oddjob-mkhomedir. This package normally handles any requirement for auto-creating home directories for those AD users on Linux. Unfortunately it doesn’t seem to get used by the SAS Object Spawner. I ran into this issue again today when logging into SAS Studio 4.2 as an AD user on the SAS Viya™ 3.2 platform. I wasn’t able to login because the AD user’s Linux home directory didn’t exist and hadn’t been auto created. After manually creating the home directory the login succeeded. I would rather get auto-creation working so I wouldn’t need to manually create home directories for each SAS user that was likely to use SAS Studio. Thankfully I was able to find a solution that I’ll describe in this post. Continue reading “Auto Creation of Linux Home Directories for SAS Users”

SAS Environment Manager Service Architecture: emi_init

Today, whilst trying to troubleshoot why a SAS Environment Manager Service Architecture configuration was no longer collecting and processing logs, I discovered a handy status option for the emi_init command. I’m posting the help output and status output here to remind me in future 🙂

Here’s the output from the emi_init help option showing all the other available options:

[sas@sas94m3lnx01 bin]$ ./emi_init.sh -h
usage: emi_init [options] [(--enable|--disable) ]
Initializes Service Architecture and/or enables components
Options:
 -d,--debug                     Enable debug output
    --disable <[APM,ACM,ALL]>   Components to disable (can't be used with
                                --enable)
    --enable <[APM,ACM,ALL]>    Components to enable (can't be used with
                                --disable)
 -f,--force                     Re-initialize and overwrite settings
 -h,--help                      Show usage information
 -i,--initialize                Initialize Service Architecture
 -k,--loadKits                  Load kits
    --resetDB                   Reset the Data Mart, purging all existing
                                ACM and APM data, non-recoverable
    --resetFlags                Resets all initialized and enabled flags
                                to false.
                                Note: This does not undo changes made
                                during initialization or component
                                enablement.
 -s,--status                    Show operational status
 -v,--verbose                   Enable verbose output
    --vafeed                Enable VA Feed
Exit status:
0  if OK
1  if minor issues are encountered
2  if an error is encountered
-1 for invalid usage

… and here’s some output from the emi_init status option:

[sas@sas94m3lnx01 bin]$ ./emi_init.sh -s
Service Architecture settings:
	Level Root Dir  : [/opt/sas94m3/config/Lev1]
	Base Dir        : [/opt/sas94m3/config/Lev1/Web/SASEnvironmentManager/emi-framework]
	Initialized     : [true]
	Enabled         : [true]
	APM Initialized : [true]
	ACM Initialized : [false]
	APM Enabled     : [true]
	ACM Enabled     : [false]
	VA Feed Enabled : [false]

You can find more information on emi_init and similar commands in the Performing Functions By Using a Command Line section of the SAS Environment Manager 2.5: User’s Guide