473,569 Members | 2,466 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I shut down and restart (only one) ASP.NET 2.0 website on the server?

How can I shut down (only one) ASP.NET website on the server.

Problem. I have updated my web-site but the site which I see is the
old one (the one there prior to the update).

I do I force ASP.NET to use the code in the new site - including the
new global.asax settings. ?
I have set the HTTP headers to expire after 1 minute. I have put the
following line in web.config

<authenticati on mode="Forms">
<forms name="whatevers ite"
loginUrl="Defau lt.aspx"
protection="Val idation"
timeout="5"/>
</authentication>

I have tried stopping and starting IIS.
What do I do to force ASP.NET 2 to end all current sessions and begin
the application anew?

I really don't want to restart the server as there are other websites
running on it.

Jan 15 '07 #1
4 1214
Save either web.config or global.asax so it gets a newer timestamp.
That will automatically restart the application's AppDomain.

Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
=============== =============== =====
"mark4asp" <ma******@gmail .comwrote in message news:1d******** *************** *********@4ax.c om...
How can I shut down (only one) ASP.NET website on the server.

Problem. I have updated my web-site but the site which I see is the
old one (the one there prior to the update).

I do I force ASP.NET to use the code in the new site - including the
new global.asax settings. ?
I have set the HTTP headers to expire after 1 minute. I have put the
following line in web.config

<authenticati on mode="Forms">
<forms name="whatevers ite"
loginUrl="Defau lt.aspx"
protection="Val idation"
timeout="5"/>
</authentication>

I have tried stopping and starting IIS.
What do I do to force ASP.NET 2 to end all current sessions and begin
the application anew?

I really don't want to restart the server as there are other websites
running on it.

Jan 15 '07 #2
Two strategies come to mind

1.) Delete the web.config file. Request a page to force the application to
fail. Use FTP to replace the old web.config file with the new web.config
file.

2.) Go into the Temporary ASP.NET Files directory where ASP.NET keeps its
compiled instance of the application and delete the instance which will be
reconstructed the next time the application is requested.

C:\WINDOWS\Micr osoft.NET\Frame work\v2.0.50727 \Temporary ASP.NET Files
<%= Clinton Gallagher
NET csgallagher AT metromilwaukee. com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=-...8&z=17&l=0&m=h
"mark4asp" <ma******@gmail .comwrote in message
news:1d******** *************** *********@4ax.c om...
How can I shut down (only one) ASP.NET website on the server.

Problem. I have updated my web-site but the site which I see is the
old one (the one there prior to the update).

I do I force ASP.NET to use the code in the new site - including the
new global.asax settings. ?
I have set the HTTP headers to expire after 1 minute. I have put the
following line in web.config

<authenticati on mode="Forms">
<forms name="whatevers ite"
loginUrl="Defau lt.aspx"
protection="Val idation"
timeout="5"/>
</authentication>

I have tried stopping and starting IIS.
What do I do to force ASP.NET 2 to end all current sessions and begin
the application anew?

I really don't want to restart the server as there are other websites
running on it.

Jan 15 '07 #3
On Mon, 15 Jan 2007 10:30:07 -0600, "clintonG"
<cs*********@RE MOVETHISTEXTmet romilwaukee.com wrote:
>Two strategies come to mind

1.) Delete the web.config file. Request a page to force the application to
fail. Use FTP to replace the old web.config file with the new web.config
file.

2.) Go into the Temporary ASP.NET Files directory where ASP.NET keeps its
compiled instance of the application and delete the instance which will be
reconstructe d the next time the application is requested.

C:\WINDOWS\Mic rosoft.NET\Fram ework\v2.0.5072 7\Temporary ASP.NET Files
Thanks, I just discovered that my problem is almost certainly that my
ISP (provider at work - not the host) is probably caching the pages.

I will include the following html in the hope that they stop caching.

<head>
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="pragma" content="no-cache" />
</head>

I tried deleting web.config but it had no effect - the same old pages
were still there.

><%= Clinton Gallagher
NET csgallagher AT metromilwaukee. com
URL http://clintongallagher.metromilwaukee.com/
MAP http://wikimapia.org/#y=43038073&x=-...8&z=17&l=0&m=h
"mark4asp" <ma******@gmail .comwrote in message
news:1d******* *************** **********@4ax. com...
>How can I shut down (only one) ASP.NET website on the server.

Problem. I have updated my web-site but the site which I see is the
old one (the one there prior to the update).

I do I force ASP.NET to use the code in the new site - including the
new global.asax settings. ?
I have set the HTTP headers to expire after 1 minute. I have put the
following line in web.config

<authenticati on mode="Forms">
<forms name="whatevers ite"
loginUrl="Defa ult.aspx"
protection="Va lidation"
timeout="5"/>
</authentication>

I have tried stopping and starting IIS.
What do I do to force ASP.NET 2 to end all current sessions and begin
the application anew?

I really don't want to restart the server as there are other websites
running on it.
Jan 15 '07 #4
Thanks, I just discovered that my problem is almost certainly that my
ISP (provider at work - not the host) is probably caching the pages.
A way to bypass that cache may be to add a dummy parameter with some
randowm value to the querystring
so instead of
mypage.aspx
use
mypage.aspx?som evar=864

The fact *that* you use a querystring might already be enough to bypass
a cache, else the "new URL" should do the trick.

Hans Kesting
Jan 16 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
5836
by: Claire | last post by:
Running XP pro, SP2. Visual studio .NET 2003. App written in C# I have written an application that hides itself when run and shows a notification icon in the system tray. If the main form is visible/restored to the desktop, and I tell windows to restart, windows shuts down fine. If the main form is minimized to the tray and I tell windows...
2
3775
by: Daniel | last post by:
Is there any way for System.IO.StreamWriter Write method to write out part of the string to file. such as if the machine is shut down half way through? or does the file not actually exist until the entire write is completed successfully.
5
1433
by: Bruce W.1 | last post by:
I know how to setup an ASP.NET project and website. But I'm not clear on how this is done with classic ASP. I've heard people say they need to shut down ASP before they can modify any of the files, no hot swapping like with ASP.NET. What's this all about? And how does one create a new classic ASP website in wwwroot? Can I just make a...
3
3193
by: John A Grandy | last post by:
In ASP.NET 1.1 and/or 2.0 ..... Is it possible to configure a web-app so that replacement of an .xml file ( physically located under the virtual dir root ) with a newer version of the file causes a web-app restart ... ? Also, is a stopping and starting a website in IIS the only way to restart a web-app ? (Of course, iisreset stops and...
6
2580
by: Deepa K | last post by:
Hi, I am using Postgresql 7.1.3. PgSQL server gets shut down once the hard disk space becomes full. Is thers any particular reason to shut down the server? Can any one help me on this. -- regards, Deepa K ---------------------------(end of broadcast)---------------------------
4
3683
by: pamelafluente | last post by:
Hi Guys, I have a small application which uses a NotifyIcon. The user can set a flag (PreventClosing ) so that when he clicks on the form-cancel button "X", the program will instead be minimized in the icon try. See code attached. My problem is that my code is probably too naive. In fact there is a problem when one tries to shut dow or...
8
1949
by: Austen | last post by:
Hello i trying to shut down window using vb. i able to restart and log off, but was unable to shut down. when excute the shut down command , nothing happend. it related to window os security issue?
6
10535
sashi
by: sashi | last post by:
Shut down Windows For various reasons you may require a shut down of Windows to happen programmatically. For instance if the installation of your program requires system reconfiguration. The following code will do this for you with options to Reboot, etc. 'Module code - modShutdown ' Shutdown Flags Const EWX_LOGOFF = 0 Const...
3
1925
by: TC | last post by:
Hey All, I have some classes that I recently built for a website which uses the HttpWebRequest & HttpWebResponse objects from the System.Net namespace. Basically, the classes rap submitted data up, connect to external websites on external servers and post / remove the data from these other sites. It works fine locally but when uploaded to...
0
8132
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7678
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7982
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
1
5514
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
5222
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3656
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3644
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2116
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
944
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

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.