When troubleshooting an issue, the logs or nginx status may show an "emerg" level error referencing an issue with an application's configuration file (/etc/nginx/conf.d/icsgw_app_<uuid>.active.conf). This may also result in a UI error that the OAG configuration is "Not Valid".
This is likely due to a misconfiguration in one of the application's policies. This article describes how to identify that application based on the UUID of the configuration file to make the necessary fix.
Example error:
nginx: [emerg] directive "proxy_redirect" is not terminated by ";" in /etc/nginx/conf.d/icsgw_app_cca31722-eae4-4057-b802-e74c6a77d8da.active.conf:82
- Okta Access Gateway (OAG)
Either option can be used to get the label from the UUID of the application:
- From the Command Line:
-
Login to the appliance shell.
-
From the error message, copy the path in the error message (/etc/nginx/conf.d/icsgw_app_cca31722-eae4-4057-b802-e74c6a77d8da.active.conf) and paste it where <path> is to view the name of the application.
sudo grep 'set $label "' <path>
Example:
sudo grep 'set $label "' /etc/nginx/conf.d/icsgw_app_cca31722-eae4-4057-b802-e74c6a77d8da.active.conf
-
- From the Browser:
- Login to the OAG UI.
- Open the browser's developer tools (Ctrl+Shift+I) and go to the Network tab.
- Navigate to the Applications page of the OAG UI.
- Within developer tools, click on the magnifying glass and search for the UUID from the error message.
- This should return a match for the response from an "app?sparse=true" call.
- Click the search result to open the response body section.
- Click anywhere in the response section and search (Ctrl+f) for the UUID.
- The UUID is the first key in the application's JSON object, which also includes its label/name and other details.
