windows - Dedicated Server restarts with a batch file -


i having troubles , hope can help. have game server running on dedicated server. have batch file running server. server needs restarted 4 hours after server starts. struggling statements batch file run restart batch file in 4 hours? if batch file says run restart batch in 4 hours life saved.

here current batch file.

@echo off  if "%configdone%"=="1" (  	goto :eof  )  set configdone=0  set skbt_debug=2  set keepalive_database=1  set keepalive_bec=0  set keepalive_asm=0  set keepalive_ts=0  set keepalive_hc=0  set serverport=2302  set bindtoip=0  set serverip=118.217.115.72  set bec_flag_dsc=1  set teamspeak_port=2310  set asm_log_interval=5  set serverstarttimeout=10  set db_backup_interval=60  set use_zip_logs=1  set use_zip_backups=1  set databasebackupfolder="e:\overpoch server 1\backup"  set logfilebackupfolder="c:\apps\epoch_log_backups"  set manual_timeout_length=2  set auto_timeout_length=10  set auto_restart_delay=5  set cleanwerdialogs=1  set hclaunchparams=-connect=1 -ip=199.217.115.72 -port=2312 -client -nosound -mod=@epoch;@epochhive;@mas;  set armaserverexe=arma3server.exe  set hcexename=arma3serverhc.exe  set teamspeakfilename=ts3server_win64.exe  set redisexename=redis-server.exe  set becexename=bec.exe  set asmexename=armaservermonitor.exe  set databasefile_name=dump.rdb  set asm_log_file=asm_performance.log  set armapath="c:\servers\epochserver"  set hcarmapath="c:\servers\epochserver"  set teamspeakpath="c:\apps\teamspeak"  set redispath="c:\servers\epochserver\db"  set asmpath="c:\servers\epochserver"  set battleyepath="c:\servers\epochserver\sc\battleye"  set logpath="c:\servers\epochserver\sc"  set becpath="c:\servers\epochserver\bec"  set databasefile="c:\servers\epochserver\db\dump.rdb"  set servercfgpath="c:\servers\epochserver\sc\config.cfg"  set serverbasicpath="c:\servers\epochserver\sc\basic.cfg"  set profilepathname="sc"  set cli_username="sc"  if %bindtoip%==1 (  	set ip_param= -ip=%serverip%  ) else (  	set ip_param=  )  set mod_string=-mod=@epoch;@epochhive;@mas;  set servercommandline=%armaserverexe% "%mod_string:"=%" "-config=%servercfgpath:"=%" %ip_param% -port=%serverport% "-profiles=%profilepathname:"=%" "-cfg=%serverbasicpath:"=%" "-name=%cli_username:"=%" -autoinit  set serveraffinity=0,1,2,3,4,5,6,7  set becaffinity=0,1,2,3,4,5,6,7  set hcaffinity=0,1,2,3,4,5,6,7  set redisaffinity=2,3,4,5,6,7,0,1  set teamspeakaffinity=0,1,2,3,4,5,6,7  set asmaffinity=0,1,2,3,4,5,6,7  set serverpriority=normal  set becpriority=normal  set hcpriority=normal  set redispriority=normal  set teamspeakpriority=normal  set asmpriority=normal

this restart batch

@echo off  call "c:\servers\epochs~2\batch\ultsgs~1.cmd"  cd /d %armapath%  if %skbt_debug% gtr 2 (  	call :func novar batchlogwrite 3__auto_restart__event__initialize====================================  )  call batch_lib\lib\setauto.bat  call batch_lib\lib\stop_all.bat  goto :eof    :func  set currentdir=%cd%  cd "%armapath%/batch_lib/gbl_func"  rem %1 = return var, %2 = function, %3 = args  set returnvarname=%1  set funcname=%2  set argstring=%3  set argstring=%argstring:__= %  set argstring=%argstring:"=%  set argstring=%argstring:(=[%  set argstring=%argstring:)=]%  set args=%argstring%  if "%argstring%"=="__=" set args=  if "%argstring%"=="" (  	set args=  )  set filename=%funcname%.cmd  set val1=  /f %%i in ('%filename% "%args%"') (  	set "val1=%%i"  )  set "%1=%val1%"  cd %currentdir%  goto :eof

thanks help! jayson

what's wrong - waits 4 hours reboots.

timeout /t 14400 shutdown /r /f /t 0 

Comments

Popular posts from this blog

java - Custom OutputStreamAppender not run: LOGBACK: No context given for <MYAPPENDER> -

java - UML - How would you draw a try catch in a sequence diagram? -

c++ - No viable overloaded operator for references a map -