Advertisement
Ubidibity

runme.bat

Jan 8th, 2025 (edited)
10
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.24 KB | Gaming | 0 0
  1. @echo off
  2. REM DayZ cmd batch-file to restart server after crash or periodic reboot
  3. REM This doesn't create a service or anything, you still need to log into the server and run the .bat file
  4. REM this batch-file depends (or at least is intended to work with) the following additional pastes:
  5. REM Periodic reboot schedule update to DayZ config: https://pastebin.com/1KVDnc4D
  6. REM Powershell for daily dayz incremental backups https://pastebin.com/ibf8ephZ
  7. REM Powershell to limit incremental zips to one week https://pastebin.com/muwsXgG8
  8.  
  9. cd C:\dayz-server
  10.  
  11. :goon
  12. rem back up dayz between executions, prune back to one week retention
  13. powershell -ExecutionPolicy Bypass -File "c:\users\administrator\documents\dayz-bak.ps1"
  14. powershell -ExecutionPolicy Bypass -File "c:\users\administrator\documents\clean-zips.ps1"
  15.  
  16. rem update the app during reboots, if one's available
  17. c:\Steamcmd\steamcmd.exe +force_install_dir c:\dayz-server +login anonymous +app_update 223350 validate +quit
  18.  
  19. rem execute the server with extra logs 'cause I'm "that guy"
  20. DayZServer_x64.exe -config=serverDZ.cfg -port=2302 --dologs -adminlog -netlog -freezecheck -profiles=c:\dayz-server\DayZServerprofiles
  21.  
  22. rem crash? Go on! (or if it's a scheduled reboot...still go on)
  23. goto goon
  24.  
Tags: DayZ
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement