Solved

Restart the CF application service automatically?

Posted on 2003-11-07
7
719 Views
Last Modified: 2013-12-24
The are something wrong with our system lately that  the application hangs from time to time. I am not 100% confident what it's causing this but one thing I am sure our database server is under powered, where we store the session variables. When the DB server is slow, our application hangs... However, when the DB server backs to normal,  we have to restart the cold fuion service manually anyway. Besides buying a new DB server, what should I do to prevent this? I thought it's going to restart itself because:

I have the following settings in the administrator page.

Limit simultaneous requests to  10
Timeout requests after  1200 seconds
Restart at 10 unresponsive requests
Restart when requests terminate abnormally

Are they good settings? I am also thinking about restart the application service once every night, just to clear any cumulative memory leak from previous days or maybe just for fun ... Is there a way to do it?
0
Comment
Question by:lyrix1999
  • 4
  • 3
7 Comments
 
LVL 1

Expert Comment

by:kjuliff
ID: 9702440
I stop and start mt CF server twice a day with scheduled tasks. Depending upon your operating system, just modify the .bat file

at 04:30 /every:M,T,W,Th,F,S,Su net stop "Cold Fusion Executive"
at 04:31 /every:M,T,W,Th,F,S,Su net stop "Cold Fusion RDS"
at 04:33 /every:M,T,W,Th,F,S,Su net stop "Cold Fusion Application Server"
at 04:35 /every:M,T,W,Th,F,S,Su net start "Cold Fusion Application Server"
at 04:36 /every:M,T,W,Th,F,S,Su net start "Cold Fusion RDS"
at 04:37 /every:M,T,W,Th,F,S,Su net start "Cold Fusion Executive"
0
 
LVL 1

Expert Comment

by:kjuliff
ID: 9702462
On restarting - I have had no problem, even with an overloaded srever. Here are my settings
Limit simultaneous requests to 5
Timeout requests after   seconds 360
Restart at   unresponsive requests 3
 Restart when requests terminate abnormally (checked)
0
 

Author Comment

by:lyrix1999
ID: 9702936
Kjuliff, thanks for your comments.

What .bat file? Or do you just create two .bat (stop and start), and run them in windows' scheduler task? I usually only stop/start application server, what's the role for CF Executive and CF RDS service?
0
U.S. Department of Agriculture and Acronis Access

With the new era of mobile computing, smartphones and tablets, wireless communications and cloud services, the USDA sought to take advantage of a mobilized workforce and the blurring lines between personal and corporate computing resources.

 
LVL 1

Expert Comment

by:kjuliff
ID: 9703887
Yes. Creat a bat file to set up the start and stop. It is generally called cf.bat.

Then run it once. It sets up the schedule.

You will not need the RDS in your version of CF (that was from an earlier one and I forgot it was there - sorry). Executive may as well stop and start too. It handles scheduled tasks and other things but  I like to clear everything out twice a day.

You just need one .bat file. Of course you could type it all into the Windows scheduler but I just find this is easier. It's easier to edit the times.


0
 

Author Comment

by:lyrix1999
ID: 9704058
Thanks. Actually I was searching if there is a .bat in the folder, I did find one in

\cfusion\bin\cycle.bat.

Looks like it has exactly same code you posted... and the REM line basically indicates the same thing you said... Cool, I never knew you can write a .bat file with 'at' clause...

I am wondering since it looks like being written by Alliure, do I have to add the .bat into scheduler, or it has been in there or called by the CF server to restart every night and I just didn't know...
0
 
LVL 1

Accepted Solution

by:
kjuliff earned 125 total points
ID: 9704162
No it will not have been executed.  Go to the command prompt at type

AT

Any sheduled tasks will be listed.

The cycle.bat will put the scheduled tasks there. It isn't a scheduler in itself.

So once you run it, type
AT
again and you'll see the tasks listed.

0
 

Author Comment

by:lyrix1999
ID: 9704241
Thanks. Now I understand this batch file is for adding the automatic stop/start in the windows scheduler.

Hope it can fix my problem.
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Most ColdFusion developers get confused between the CFSet, Duplicate, and Structcopy methods of copying a Structure, especially which one to use when. This Article will explain the differences in the approaches with examples; therefore, after readin…
Article by: kevp75
Hey folks, 'bout time for me to come around with a little tip. Thanks to IIS 7.5 Extensions and Microsoft (well... really Windows 8, and IIS 8 I guess...), we can now prime our Application Pools, when IIS starts. Now, though it would be nice t…
This video shows how to quickly and easily add an email signature for all users on Exchange 2016. The resulting signature is applied on a server level by Exchange Online. The email signature template has been downloaded from: www.mail-signatures…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

830 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question