Forefront UAG Troubleshooting: Event ID 158: The Application Settings Could Not Be Read

Forefront UAG Troubleshooting: Event ID 158: The Application Settings Could Not Be Read

SymptomsWhen end users attempt to access the Forefront UAG portal, they may receive the following message "An unexpected error occurred when starting the application." There may also be an event 158 in the event viewer or in the Web Monitor with the description "ADFSv2Site: The application settings could not be read because the trunk name is not defined."

Cause—The web.config file for this portal has been modified and does not define the trunk name in the application settings.

Solution—Either activate the configuration to recreate the web.config file, or manually modify the web.config file as follows:

  1. On the Forefront UAG server, go to ...\Microsoft Forefront Unified Access Gateway\von\InternalSite\ADFSv2Sites\<trunk_name>\ and open the web.config file.
  2. In the <appSettings> section, add the following line:

<add key="TrunkName" value="[trunk name]">

where [trunk name] is the name of the HTTPS trunk in the Forefront UAG Management console.

Leave a Comment
  • Please add 1 and 6 and type the answer here:
  • Post
Wiki - Revision Comment List(Revision Comment)
Sort by: Published Date | Most Recent | Most Useful
Comments
  • Maheshkumar S Tiwari edited Revision 3. Comment: Added Tag

  • Ed Price MSFT edited Revision 2. Comment: Updated title and tags.

Page 1 of 1 (2 items)
Wikis - Comment List
Sort by: Published Date | Most Recent | Most Useful
Posting comments is temporarily disabled until 10:00am PST on Saturday, December 14th. Thank you for your patience.
Comments
  • Ed Price MSFT edited Revision 2. Comment: Updated title and tags.

  • Maheshkumar S Tiwari edited Revision 3. Comment: Added Tag

Page 1 of 1 (2 items)