473,396 Members | 2,109 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Modify application after Deployment

Hello Everyone,

I am having a little problem. After publish my ASP.Net project to my server I have to recycle the Application pool in IIS. Whenever I modify the code i get a compilation error and have to Recycle the application pool again. Is that the normal process for applications after deployment?
Oct 7 '09 #1
30 4148
Frinavale
9,735 Expert Mod 8TB
Every time you modify the application the application pool is restarted.
So yes this is normal.

Whenever you make a change to the .NET code (your VB or C#) code [edit] and then build your website (precompile the application) [/edit] the application pool is reset. Whenever you modify the web.config file, the application pool is reset.

-Frinny
Oct 8 '09 #2
Should the application pool reset itself? Because I get a compilation error when I try to access the modified page online. So what I usually do is open the app pool and manually refresh,reset recycle it. Then my application works. Is that how it should be?
Oct 8 '09 #3
Frinavale
9,735 Expert Mod 8TB
Yes it will reset itself.
It might help if you posted what the error says.....
Oct 8 '09 #4
Description: An error occurred during the compilation of a resource required to service this request. Please review the following specific error details and modify your source code appropriately.

Compiler Error Message: The compiler failed with error code -1073741502.

I have googled this error but none of the solutions seem to work for me. Only restarting the app pool. Any Ideas?
Oct 8 '09 #5
Frinavale
9,735 Expert Mod 8TB
Try precompiling the website before publishing it...?
Oct 8 '09 #6
What if the website is already published and located on the server. I open the project in visual studio, make the changes , click save and thats it. Time to restart the app pool.
Oct 8 '09 #7
Frinavale
9,735 Expert Mod 8TB
Is the project located on the web server?
Try right clicking on the project name in the Solution Explorer and clicking "build".
This will compile all of your code and will definitely reset the application domain (if changes are made to the code).
Oct 8 '09 #8
Yest it is located on the web server.Have done that. Still does not work. Just to clarify the restart I have to do is in IIS app pool.
Oct 8 '09 #9
Frinavale
9,735 Expert Mod 8TB
That's the way I work as well.

It makes absolutely no sense for ASP.NET to compile your code if you have already pre-compiled it. The ASP.NET compiler does not compile your code "on the fly" when there is as cached, precompiled version available.

Are you absolutely sure that you built the solution without error after making code changes?
Oct 8 '09 #10
Absolutely no errors or warnings.
Oct 8 '09 #11
Here is the Detailed Compiler Output."If it helps"

c:\windows\system32\inetsrv> "C:\Windows\Microsoft.NET\Framework\v3.5\csc.e xe" /t:library /utf8output /R:"C:\Windows\assembly\GAC_MSIL\System.ServiceMode l.Web\3.5.0.0__31bf3856ad364e35\System.ServiceMode l.Web.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Data.DataSe tExtensions\3.5.0.0__b77a5c561934e089\System.Data. DataSetExtensions.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Web.Extensi ons\3.5.0.0__31bf3856ad364e35\System.Web.Extension s.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Web.Service s\2.0.0.0__b03f5f7f11d50a3a\System.Web.Services.dl l" /R:"C:\Windows\assembly\GAC_MSIL\System.IdentityMod el\3.0.0.0__b77a5c561934e089\System.IdentityModel. dll" /R:"C:\Windows\assembly\GAC_32\System.Data\2.0.0.0_ _b77a5c561934e089\System.Data.dll" /R:"C:\Windows\assembly\GAC_32\System.Web\2.0.0.0__ b03f5f7f11d50a3a\System.Web.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Web.Mobile\ 2.0.0.0__b03f5f7f11d50a3a\System.Web.Mobile.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Configurati on\2.0.0.0__b03f5f7f11d50a3a\System.Configuration. dll" /R:"C:\Windows\assembly\GAC_MSIL\System\2.0.0.0__b7 7a5c561934e089\System.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.WorkflowSer vices\3.5.0.0__31bf3856ad364e35\System.WorkflowSer vices.dll" /R:"C:\Windows\assembly\GAC_32\System.EnterpriseSer vices\2.0.0.0__b03f5f7f11d50a3a\System.EnterpriseS ervices.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Drawing\2.0 .0.0__b03f5f7f11d50a3a\System.Drawing.dll" /R:"C:\Windows\Microsoft.NET\Framework\v2.0.50727\m scorlib.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Xml\2.0.0.0 __b77a5c561934e089\System.Xml.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Runtime.Ser ialization\3.0.0.0__b77a5c561934e089\System.Runtim e.Serialization.dll" /R:"C:\Windows\Microsoft.NET\Framework\v2.0.50727\T emporary ASP.NET Files\healthgames_cms_asp.net\534a3fdc\8ab2d544\as sembly\dl3\a563f03a\aeb41d32_3e48ca01\HealthGames. DLL" /R:"C:\Windows\assembly\GAC_MSIL\System.Xml.Linq\3. 5.0.0__b77a5c561934e089\System.Xml.Linq.dll" /R:"C:\Windows\assembly\GAC_MSIL\System.Core\3.5.0. 0__b77a5c561934e089\System.Core.dll" /R:"C:\Windows\Microsoft.NET\Framework\v2.0.50727\T emporary ASP.NET Files\healthgames_cms_asp.net\534a3fdc\8ab2d544\as sembly\dl3\18ba3e12\001e1e5c_92ebc901\AjaxControlT oolkit.DLL" /R:"C:\Windows\assembly\GAC_MSIL\System.ServiceMode l\3.0.0.0__b77a5c561934e089\System.ServiceModel.dl l" /out:"C:\Windows\Microsoft.NET\Framework\v2.0.50727 \Temporary ASP.NET Files\healthgames_cms_asp.net\534a3fdc\8ab2d544\Ap p_Web_demographics.aspx.cdcab7d2.b2ja-z0v.dll" /debug- /optimize+ /win32res:"C:\Windows\Microsoft.NET\Framework\v2.0. 50727\Temporary ASP.NET Files\healthgames_cms_asp.net\534a3fdc\8ab2d544\yv u6wkfa.res" /w:4 /nowarn:1659;1699;1701 /warnaserror- "C:\Windows\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\healthgames_cms_asp.net\534a3fdc\8ab2d544\Ap p_Web_demographics.aspx.cdcab7d2.b2ja-z0v.0.cs" "C:\Windows\Microsoft.NET\Framework\v2.0.50727\Tem porary ASP.NET Files\healthgames_cms_asp.net\534a3fdc\8ab2d544\Ap p_Web_demographics.aspx.cdcab7d2.b2ja-z0v.1.cs"
Oct 8 '09 #12
------ Build started: Project: HealthGames, Configuration: Debug Any CPU ------
HealthGames -> Z:\HealthGames\cms\ASP.Net\bin\HealthGames.dll
========== Build: 1 succeeded or up-to-date, 0 failed, 0 skipped ==========
Oct 8 '09 #13
Frinavale
9,735 Expert Mod 8TB
I'm not sure what's wrong...
Have you tried creating a new website (or virtual directory) using IIS and publishing the application to that website instead?
Oct 8 '09 #14
Could it be because the home page to the web site is written in classic asp It compiles fine even after modifying?But the new page, the one i created and modify is asp.net. Could it be that they don't mesh together until restarting the app pool?
Oct 8 '09 #15
Frinavale
9,735 Expert Mod 8TB
I didn't realize you had classic asp in the mix.
How did you include the classic asp into the application???
Oct 8 '09 #16
The application was written in classic by a different programmer. Any new nodes to the application I write in .net for many reasons. I just publish my web site/project to the same folder on the server with the classic asp pages. In the classic asp pages I modify the code to point to my new pages and include any query strings needed. That is about it
Oct 8 '09 #17
Frinavale
9,735 Expert Mod 8TB
Ok, I have a feeling this has something to do with ASP classic.
You're probably running 2 different applications pools (but I'm not sure how ASP classic works). It's probably not the ASP.NET compiler crashing because you are able to build your solution to create a pre-compiled version of your .NET web application. This problem probably has to do with the way your ASP classic code is working.

I'm going to move your question to the ASP classic forum and hopefully you can get more help on the issue there.

-Frinny
Oct 8 '09 #18
Thank you for your help.
Oct 8 '09 #19
CroCrew
564 Expert 512MB
Hello stefbek97,

Isolate the problem and future problems by placing all your websites within their own application pool.

Under IIS you will see a folder called “ApplicationPool” there you can create a new pool for your Virtuals/Web sites.

Then in IIS right click on the virtual/website that is having the problems and select properties. Then look under the “Virtual Directory” tab and you will see where you can change it to the new application pool you have created.

When you start creating more and more DotNet application under different Frameworks you will see the need for creating more application pools. I Have create a pool for every version of DotNet Frameworks there are and what ever Framework I build a site under I place it in that Application Pools Framework.

Hope this helps,
CroCrew~
Oct 9 '09 #20
CroCrew
564 Expert 512MB
Hello stefbek97,

It has been a few days. Has this problem been resolved?

CroCrew~
Oct 13 '09 #21
Not really. I am not sure what to do at this point.
Oct 13 '09 #22
CroCrew
564 Expert 512MB
Did you try creating a new application pool?
Oct 13 '09 #23
I did and I cant get the app to work in the new pool.
Oct 13 '09 #24
CroCrew
564 Expert 512MB
You cant get it to work at all?
Oct 14 '09 #25
JamieHowarth0
533 Expert 512MB
Hi guys,

1) Thread moved, this is not related to classic ASP.
2) The problem you're having is that when a website is run in ASP.NET, ASP.NET caches the compiled code into C:\WINDOWS\Microsoft.NET\Framework\(version you are using)\Temporary ASP.NET Files. When you change the codebase on the webserver, ASP.NET tries to see what file you are accessing, and then tries to run the cached code if applicable. If the cached file is not equal to the file being requested, this error springs up.
Every time you make live code changes you will either need to:
a) recycle the app pool, or;
b) clear the Temporary ASP.NET Files directory.

It's easier and more sensible to do a) because b) is a side-effect of a).

BTW check which version of ASP.NET your website is configured to use and ensure that any other applications sharing the same AppPool are using the same version (as per CroCrew's recommendations). You cannot run two versions of ASP.NET inside a single application pool - this is by design.

Hope this helps.

codegecko
Oct 14 '09 #26
Frinavale
9,735 Expert Mod 8TB
CG I don't know if this is really related to the issue.

I just tested this and every time I make a change to my ASP.NET code (and compiled it) the files in the "Temporary ASP.NET Files" directory are automatically changed to the newest version (old ones are replaced with the new ones) the first time the website is accessed.

I still think it has to do with the ASP classic.

What happens when you have ASP.NET code and ASP classic code running in the same virtual directory/website?

I would assume it would go something like:
  • User accesses classic ASP page
  • Classic ASP compiler compiles the ASP page
  • User clicks link in Classic ASP page
  • Classic ASP compiler compiles the ASP page and executes the ASP code associated with the link that results in redirecting user to ASP.NET page
  • ASP.NET finds cached version of aspx page and uses that to do stuff and return the page to the user

The problem is that the compiler's crashing.
I'm assuming it's the ASP classic compiler because the ASP.NET compiler isn't required since there's a cached version website.

I don't understand why the OP has to delete the files in the temporary ASP.NET files directory when this is automatically done.

What I really don't understand is how the ASP classic code is sharing an application pool with the ASP.NET code....I've never done this before so I have no clue.
Oct 14 '09 #27
Frinavale
9,735 Expert Mod 8TB
@Stefbek97: I'm just wonder, what version of IIS are you using?
Oct 14 '09 #28
JamieHowarth0
533 Expert 512MB
@Frinny, the Classic ASP compiler and the .NET compiler are two separate ISAPIs which are only executed when a matching request is made to the web server (.asp for ClASP, .aspx for .NET), so it can't be a compiler mis-match.

@Stefbek97, what's the error when you move the site to it's own application pool?
If you could reply with the following info:
* IIS version
* ASP.NET version of the site
* Application pool identity
* Error message

then hopefully we can try and isolate the issue.

codegecko
Oct 15 '09 #29
Frinavale
9,735 Expert Mod 8TB
@codegecko
Thanks for the clarification :)

@codegecko
I didn't think it was a compiler mismatch.
I think that it's the ASP classic compiler that's failing when the following error happens:
@stefbek97
Is there a way to cache ASP classic pages? (eg precompile them the same way you can precompile an ASP.NET application)

If so, it could be that the cached version of the ASP classic page is still referencing the old ASP.NET application, which it can't find any more because it's been updated. If so, all you'd have to update the ASP classic whenever you update the ASP.NET application.
Oct 15 '09 #30
Frinavale
9,735 Expert Mod 8TB
@stefbek97
Stefbek97, have you considered updating the ASP classic page to .NET?
I think this would probably get solve your problem and prevent future headaches....

-Frinny
Oct 16 '09 #31

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Baldy | last post by:
Hi All is it possible to modify code at run time? I have a set of constants that change at deployment (from development to deployment server and a few other consts) I have a menu item that...
0
by: Mart | last post by:
Hi, I have just written (my first) VB.net app using MS Visual Basic 2005 Express Edition Beta. It is fairly simple, it reads some configuration data from an XML file then opens a new window...
0
by: Uma | last post by:
Dear all, I have a problem while running a smart client application which was installed through CD-ROM. After installing the smart client setup the application is running properly. When running...
6
by: Josef Brunner | last post by:
Hi, I published my application (VS 2005) and am now trying to install it when I get this error message. It worked before...even on a different machine. Here is the detailed description: ...
8
by: Ryan | last post by:
I've created and deployed a VB.Net 2005 Application. I have it set as a FullTrust (ClickOnce) application. The install point is on a network server. I did not run into this issue at all while...
2
by: Michael Kalika | last post by:
Hi, We have developed a VSTO 2005 Excel application and we would like to leverage ClickOnce deployment mechanism for distribution of this application. How can we do that? I was digging in MSDN...
0
by: Tifer | last post by:
Hello, I am building my first .Net Application. The first couple of Publish and Installs I did went fine. But after a couple of builds, I get a modal dialogue box error every time upon trying...
0
by: coopdog | last post by:
This is a new issue as of an install to sp1 on vb express 2005. When I publish the application to my drive then I try to install it is wants to be installed from the same location as it was...
0
by: Andrus | last post by:
I created .NET 3.5 SP1 Winforms application setup by pressing publish button in VCSE 2008 SP1 Running created setup.exe in same computer causes error below "Reference in the manifest does not...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.