Running multiple versions of ASP.NET on the same web server.

childlikenumberSecurity

Nov 5, 2013 (3 years and 1 month ago)

75 views

1


Running
multiple versions of
ASP.NET on the same web server.

Alchemex Web Components 3.0 requires
.NET framework version 3.5

which

runs
ASP.NET version
2.0.50727

in Internet Information Services (IIS).


I
t is imperative that sites running different versions of ASP.NET be placed in separate
application

pools

in IIS.
If this occurs
,

a “
Server Application Unavailable
” error will be shown
when
navigating to

any

asp.net site
.


Before we start...

Backup, Restore

(
and Restart
)

in IIS:

To
b
ackup

the
s
tate of IIS (before making any configuration changes) do the following:

Right click on the machine name > All Tasks > Backup/Restore Configuration.


Click Create Backup.




2


Give the backup a meaningful name and click

OK.


To
restore

the state of IIS (from a backup) do the following:

Right click on the machine name > All Tasks > Backup/Restore Configuration.

Select the desired backup and click Restore.




3


To
restart IIS

do the following:

Right click on the machine na
me > All Tasks > Restart IIS.



Please Note!

After making configuration changes to a particular site
, it is often
necessary to stop and start the
site for the changes to take effect
. To do these do the following:


Select the appropriate site and click the

“Stop Item” button in the toolbar.


Then click the “Start Item” button in the toolbar.




4


Ok, backups in place...

Configuring Application Pools correctly:

This is achieved in different ways depending on the IIS version:



IIS7

(Windows Vista)


(not
affected)



I
IS6


(Windows Server 2003)

In IIS expand the Application Pools node and select New > Application Pool.


Give the new application pool a meaningful name (ID) and click OK.


Select the properties of the AlcWebReporting site.




5


On the Home
Directory tab, choose the new application pool from the Application pool drop
down list then click O
K.




IIS5.1

(Windows XP)

In IIS select the properties of the AlcWebReporting site.



6


On the Virtual Directory tab, choose High (Isolated) from the
Application Protection drop
down list then click O
K.




7


Conclusion:

Once the above changes are in place and each affected site has been
re
started, the error should be
resolved.


Remember
!




This error will only affect machines running multiple sites with
multiple versions of ASP.NET
in Internet Information Services.


Should you still be experiencing issues it may be due to your specific configuration
, one common fix
is to run the following batch file (Advanced Users Only):


Caution!

Make note of the ASP.NE
T version of
EACH

site before running this batch file.

During the process ASP.NET 2 > 3.5 will be removed and all
of
the sites
in IIS
will have their
ASP.NET
version set to 1.1.

Batch File

REM Start Batch File

@echo off


REM Change to the .NET Framework installation directory.

cd /d %SystemRoot%
\
microsoft.net
\
framework
\
2.0.50727



echo "Stopping IIS."

iisreset /stop

echo "
----------------------
"


echo "Stopping the ASP.NET state service if it is running."

net stop aspnet_state

echo "
----------------------
"


echo "Deleting the ASPNET account."

net user ASPNET /delete

echo "
----------------------
"


echo "Creating a new ASPNET account with a temporary password."

net user ASPNET 1pass@word /add

echo "
---
-------------------
"


echo "Launching runas to create a profile."

echo "You see a command window being created."

echo "Type 1pass@word when you are prompted for the temporary password."

runas /profile /user:ASPNET cmd.exe

echo "
----------------------
"


echo "Reregistering ASP.NET and the ASPNET account."

aspnet_regiis
-
i

echo "A new random password has been autocreated for the ASPNET account."

echo "
----------------------
"


echo "Restarting IIS."

iisreset /start

echo

"
----------------------
"


echo "The workaround has been applied."

echo "Try to access an ASP.NET page."

echo "If you have any custom access controls settings for the ASPNET account,"

echo "you must re
-
create them."

echo "If you were running the ASP.N
ET state service, you must restart it."


REM End of batch file.