23 Oct Octubre 23
If you are running a CSS server on linux, the server itself already supports auto restarting srcds when crash. Si utilitzeu un servidor de CSS en Linux, el servidor en si suporta acte reiniciar srcds a l'accident. However on Windows, you can do it via a batch file. No obstant això, en Windows, podeu fer-ho a través d'un arxiu per lots. It works but it has its problems in doing that which I'll explain further. Funciona però té els seus problemes en fer el que vaig a explicar amb més detall.
This is the batch file that you need to run to keep srcds.exe open by automatically running when crashed or closed. Aquest és l'arxiu per lots que ha d'executar per mantenir srcds.exe obrir automàticament en funcionament quan es va estavellar o tancat.
@echo off
cls
echo Protecting srcds from crashes...
echo If you want to close srcds and this script, close the srcds window and type Y depending on your language followed by Enter.
title srcds.com Watchdog
:srcds
echo (%time%) srcds started.
start /wait srcds.exe -console -game cstrike +map de_dust +maxplayers 16
echo (%time%) WARNING: srcds closed or crashed, restarting.
goto srcds
The command above will monitor for srcds.exe and immediately auto runs the command line if it's not running. La comanda anterior per supervisar srcds.exe automàtica i immediatament s'executa la línia de comandes si no s'executa. Well Valve recommends that we should wait for at least 10 seconds before restarting so that there is enough time for the memory to clear up. Bé vàlvula recomana que hem d'esperar com a mínim 10 segons abans de reiniciar, perquè hi hagi temps suficient perquè la memòria a aclarir. I've used this batch and noticed that there were a few times the server crashes, restart, crashes again and restart. He utilitzat aquest lot i es va adonar que hi havia un parell de vegades el servidor es bloqueja, reinicieu, els accidents de nou i reiniciar. Previously I've written an Anteriorment he escrit un article article that contains a couple of free tools that can auto rerun program when closed but this time I needed something different. que conté un parell d'eines gratuïtes que poden tornar a executar el programa d'auto quan està tancat, però aquest cop necessitava alguna cosa diferent.
I was looking for a free, small, simple and portable tool that can monitor for a specific process and then run a “different” file when it detects a crash. Estava buscant una eina gratuïta, petita, senzilla i portàtil que pot controlar per a un procés específic i després executeu l'arxiu "diferent" quan es detecta un accident. I found Restart on Crash which has been working perfectly ever since I started using it. He trobat Reinicieu l'accident que ha estat funcionant perfectament des que vaig començar a usar-lo. Restart on Crash is an monitoring tool that will watch the applications that you specify and automatically relaunch any program that hangs or crashes. Reiniciar Crash és una eina de vigilància a veure les aplicacions que s'especifica de forma automàtica i reiniciar qualsevol programa que es penja o es bloqueja. You can add any number of applications to monitor, enable/disable them individually and edit the command line that will be used to restart an application. Vostè pot afegir qualsevol nombre d'aplicacions per controlar, activar o desactivar individualment i editar la línia de comandes que s'utilitza per reiniciar una aplicació. Restart on Crash doesn't require installation and stores all it's configuration data in a “settings.ini” file in the program's folder, so it's portable. Reinicieu l'accident no requereix instal lació i emmagatzema totes les seves dades de configuració en un "settings.ini" fitxer a la carpeta del programa, així que és portàtil. It should be compatible with most NT-based Windows versions. Ha de ser compatible amb la majoria basats en NT versions de Windows.
Basically the below image is the settings for the srcds server. Bàsicament, la imatge de baix és la configuració del servidor d'srcds. It monitors srcds.exe and when it isn't running, a run.bat file will be executed. Supervisa srcds.exe i quan no s'està executant, un arxiu de run.bat serà executat. 
The more interesting part is the run.bat which is executed when the program detected that srcds.exe is not running. La part més interessant és el run.bat que s'executa quan el programa detecta que srcds.exe no s'està executant. Since it is a batch file, I can program it to run multiple commands. Com que és un arxiu per lots, que es pot programar per executar diversos ordres. 
The first command shows that I ping localhost 3 times. El primer comanda mostra que ping localhost 3 vegades. This command is being used as a feature to wait for 3 seconds before going to the second command. Aquesta funció és sent utilitzat com una característica d'esperar durant 3 segons abans d'anar a la segona ordre. The second command from the batch file is to execute El segon comandament de l'arxiu de procés per lots és executar CleanMem CleanMem which is a tool to clean process and file cache to recover even more memory and performance. que és una eina per netejar el procés i l'arxiu de memòria cau de recuperar la memòria encara més i el rendiment. Then again pause for 10 seconds before running srcds.exe with the full command line. D'altra pausa de 10 segons abans d'executar srcds.exe amb la línia de comandes completa. This method has been working perfectly for weeks already and I didn't need any other more advanced crash recovery software such as Firedaemon that cost money. Aquest mètode s'ha estat treballant perfectament durant setmanes i ja no necessitava cap altre més avançat programari de recuperació de falles, com FireDaemon que costen diners.
[ [ Download Restart on Crash Descarregar Reiniciar en Crash ] ]
Technorati Tags: Etiquetes de Technorati: restart reinicieu , , crash accident , , firedaemon FireDaemon , , srcds srcds , , windows Windows
: Copying this article to your website is strictly NOT allowed. : Còpia d'aquest article al seu lloc web està estrictament permès. However, if you like this article, you can use the HTML code below to directly link to this article. No obstant això, si t'agrada aquest article, pot utilitzar el codi HTML per vincular directament a aquest article. Disable Program Has Stopped Working Error Dialog in Windows Server 2008 Deshabilitar programa ha deixat de funcionar de diàleg d'error a Windows Server 2008 Sending Email Using Command Line Useful for Downtime Alert Notification Enviament de correu electrònic utilitzant la línia d'ordres útils per al temps d'inactivitat de notificació d'alertes Keep Application Running by Automatically ReRun When Closed Mantingui aplicació que s'executa automàticament quan es tanca rerun Shut down Unnecessary Services and Programs with AlacrityPC Apagueu els serveis innecessaris i programes amb AlacrityPC Automatically Close Running Programs and Eject USB PenDrive Es tanquen automàticament execució de programes i Expulsar pendrive USB Angsuman’s Translator Plugin Pro causing High Load for servers Angsumanâ € ™ s Traductor Plugin Pro causant alta càrrega dels servidors Nero 7.2.3.2b fixes audio CD skipping problem Nero 7.2.3.2b fixa CD d'àudio saltar problema de
Have computer technical problems? Problemes informàtics han tècnica? Get FREE help from Raymond.CC FORUM Aconsegueix GRATIS ajuda de Raymond.CC FÒRUM
6 Responses for "Execute any File When Application Crashed or Stopped Running (Useful for SRCDS)" 6 respostes per a "Executar qualsevol arxiu o quan l'aplicació Crashed Stopped Running (útil per SRCDS)"
Very Useful! Molt útil!
I have a problem using this tool. Tinc un problema amb aquesta eina.
I choose an application on “MONITOR THIS APPLICATION”..for example opera.exe Puc triar una aplicació a "vetllar per l'aplicació AQUESTA" .. per exemple OPERA.EXE
after i wish if Opera isn't running to run Firefox by a run.bat després de desig si l'òpera no s'està executant per executar Firefox per un run.bat
the problem is that when i choose the run.bat the same run.bat appears in the box MONITOR THIS APPLICATION el problema és que quan trio la run.bat run.bat la mateixa apareix en el quadre MONITOR D'AQUESTA SOL LICITUD
i don't understand No ho entenc
I find the solution Em sembla la solució
I have to modify manually the box in witch I run run.bat He de modificar manualment el quadre de la bruixa rotllana run.bat
ALL is ok now TOT està bé ara
It's great És genial
it will be usefull for when i set up a counter strike in my home serà útil per quan em va crear un counter strike a casa meva
do you think its possible fro me to set up at home via wireless connection? Creu vostè que la seva possible venir amb mi per establir al país a través de connexió sense fils?
Raymond, I really like the use of CleanMem that you've implemented. Raymond, m'agrada molt l'ús de CleanMem que ha implementat. I'm going to give Shane a call and tell him about it. Vaig a donar a Shane una trucada i li diuen al respecte.
Just out of curiousity are you running CleanMem with the “Clear File Cache” option enabled or disabled? Només per curiositat Està executant CleanMem amb l'opció "Esborrar Memòria cau d'arxius" activat o desactivat? If you've tried it both ways for this server have you noticed any positive or negative impact either way? Si has provat les dues coses per aquest servidor Heu notat algun impacte positiu o negatiu de qualsevol manera?
Oh yeah, welcome back from the honeymoon and congrats! Oh, sí, celebro la tornada de la lluna de mel i felicitats!
-Evan -Evan
http://www.PcWinTech.com http://www.PcWinTech.com – Home of CleanMem - Inici de CleanMem
I'll keep this in mind. Vaig a tenir això en ment. Hopefully I can use it when I host a CS Server. Espero poder usar-lo quan amfitrió d'un servidor CS.
Leave a reply Deixa una resposta