Dateranoth / ConanExilesServerUtility

Utility for automating updates and remotely restarting Conan Exiles server.
GNU General Public License v3.0
15 stars 9 forks source link

Two servers, one of the two with the script, bug? #22

Closed Mannot74 closed 7 years ago

Mannot74 commented 7 years ago

Infos : Two servers, first PVP and second PVE on OVH dedicated server with windows server 2012.

I tried your script only on the PVE server, to test.

I only use "ConanServerUtility.exe" and I do not use the "ConanServerRemoteRestart (x64)" script.

I use the script only on the PVE server, but I still renamed "ConanServerUtility.exe" to "UpdatePVEv2.8.6.1" (Because I would like to run the script on both servers soon)

My "ConanServerUtility.ini"

[Use MULTIHOME to Bind IP? Disable if having connection issues (yes/no)] BindIP=yes [Game Server IP] ListenIP=xxx.xxx.xxx.xxx [Game Server Port] GamePort=xxxxx [Steam Query Port] QueryPort=xxxxx [Server Name] ServerName=[EU/FR]-[PVE] SOG - New Server 09/02 [Server Password] ServerPass= [Admin Password] AdminPass=xxxxxxxx [Max Players] MaxPlayers=70 [Server Directory. NO TRAILING SLASH] serverdir=C:\ConanexilePVE [Use SteamCMD To Update Server? yes/no] UseSteamCMD=yes [SteamCMD Directory. NO TRAILING SLASH] steamcmddir=C:\SteamCMD [Validate Files Every Time SteamCMD Runs? yes/no] validategame=yes [Use Remote Restart ?yes/no] UseRemoteRestart=no [Remote Restart Port] ListenPort=xxxxx [Remote Restart Password] RestartCode=Admin1_xc69ckxu38m66 [Hide Passwords in Log? yes/no] ObfuscatePass=yes [Restart Server Daily? yes/no] RestartDaily=no [Check for Update Every X Minutes? yes/no] CheckForUpdate=yes [Update Check Interval in Minutes 05-59] UpdateInterval=30 [Daily Restart Hours? 00-23] HotHour1=00 HotHour2=00 HotHour3=00 HotHour4=00 HotHour5=00 HotHour6=00 [Daily Restart Minute? 00-59] HotMin=01 [Excessive Memory Amount?] ExMem=6000000000 [Restart On Excessive Memory Use? yes/no] ExMemRestart=no [Running Server with Steam Open? (yes/no)] SteamFix=no [Rotate X Number of Logs every X Hours? yes/no] logRotate=yes logQuantity=10 logHoursBetweenRotate=24 [Use Discord Bot to Send Message Before Restart? yes/no] UseDiscordBot=no DiscordWebHookURL=https://discordapp.com/api/webhooks/XXXXXX/XXXX <- NO TRAILING SLASH AND USE FULL URL FROM WEBHOOK URL ON DISCORD DiscordBotName=Conan Exiles Discord Bot DiscordBotUseTTS=yes DiscordBotAvatarLink= DiscordBotTimeBeforeRestart=5

Problematic :

When there is an update, the server "PVP" shutdown while it should be the "PVE" server, and this without installing the update or rebooting ..

Did I make a mistake?

PS ; Also, do you know this script that I can not make it work ? https://github.com/C0nw0nk/SteamCMD-AutoUpdate-Any-Gameserver

Dateranoth commented 7 years ago

If you have two servers running you must shut them both down and start them one at a time the first time you use the script. It will then save the server information to know which is which.

So, in your case. Stop both servers, let the script start your PVE server. Then open your pvp server.

Please be aware that I have not tested this running one with the script and one without.

If you have further problems, let me know, and I will see if there is something wrong.

Sorry, I'm not familiar with that other script.

On Feb 16, 2017, at 1:58 PM, Mannot74 notifications@github.com<mailto:notifications@github.com> wrote:

Infos: Two servers, first PVP and second PVE on OVH dedicated server with windows server 2012.

I tried your script only on the pve server, to test.

I only use "ConanServerUtility.exe" and I do not use the "ConanServerRemoteRestart (x64)" script.

I use the script only on the PVE server, but I still renamed "ConanServerUtility.exe" to "UpdatePVEv2.8.6.1" (Because I would like to run the script on both servers soon)

My "ConanServerUtility.ini"

[Use MULTIHOME to Bind IP? Disable if having connection issues (yes/no)] BindIP=yes [Game Server IP] ListenIP=xxx.xxx.xxx.xxx [Game Server Port] GamePort=xxxxx [Steam Query Port] QueryPort=xxxxx [Server Name] ServerName=[EU/FR]-[PVE] SOG - New Server 09/02 [Server Password] ServerPass= [Admin Password] AdminPass=xxxxxxxx [Max Players] MaxPlayers=70 [Server Directory. NO TRAILING SLASH] serverdir=C:\ConanexilePVE [Use SteamCMD To Update Server? yes/no] UseSteamCMD=yes [SteamCMD Directory. NO TRAILING SLASH] steamcmddir=C:\SteamCMD [Validate Files Every Time SteamCMD Runs? yes/no] validategame=yes [Use Remote Restart ?yes/no] UseRemoteRestart=no [Remote Restart Port] ListenPort=xxxxx [Remote Restart Password] RestartCode=Admin1_xc69ckxu38m66 [Hide Passwords in Log? yes/no] ObfuscatePass=yes [Restart Server Daily? yes/no] RestartDaily=no [Check for Update Every X Minutes? yes/no] CheckForUpdate=yes [Update Check Interval in Minutes 05-59] UpdateInterval=30 [Daily Restart Hours? 00-23] HotHour1=00 HotHour2=00 HotHour3=00 HotHour4=00 HotHour5=00 HotHour6=00 [Daily Restart Minute? 00-59] HotMin=01 [Excessive Memory Amount?] ExMem=6000000000 [Restart On Excessive Memory Use? yes/no] ExMemRestart=no [Running Server with Steam Open? (yes/no)] SteamFix=no [Rotate X Number of Logs every X Hours? yes/no] logRotate=yes logQuantity=10 logHoursBetweenRotate=24 [Use Discord Bot to Send Message Before Restart? yes/no] UseDiscordBot=no DiscordWebHookURL=https://discordapp.com/api/webhooks/XXXXXX/XXXX <- NO TRAILING SLASH AND USE FULL URL FROM WEBHOOK URL ON DISCORD DiscordBotName=Conan Exiles Discord Bot DiscordBotUseTTS=yes DiscordBotAvatarLink= DiscordBotTimeBeforeRestart=5

Problematic :

When there is an update, the server "PVP" shutdown while it should be the "PVE" server, and this without installing the update or rebooting ..

Did I make a mistake?

PS; Also, do you know this script that I can not make it work ? https://github.com/C0nw0nk/SteamCMD-AutoUpdate-Any-Gameserver

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/Dateranoth/ConanExilesServerUtility/issues/22, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAabii8jR3n-HWgMmiXJCjp7lz7VS5jOks5rdJxggaJpZM4MDaMd.

Dateranoth commented 7 years ago

Also, if the problem continues, could you paste the ConanServerUtility.log here?

On Feb 16, 2017, at 1:58 PM, Mannot74 notifications@github.com<mailto:notifications@github.com> wrote:

Infos: Two servers, first PVP and second PVE on OVH dedicated server with windows server 2012.

I tried your script only on the pve server, to test.

I only use "ConanServerUtility.exe" and I do not use the "ConanServerRemoteRestart (x64)" script.

I use the script only on the PVE server, but I still renamed "ConanServerUtility.exe" to "UpdatePVEv2.8.6.1" (Because I would like to run the script on both servers soon)

My "ConanServerUtility.ini"

[Use MULTIHOME to Bind IP? Disable if having connection issues (yes/no)] BindIP=yes [Game Server IP] ListenIP=xxx.xxx.xxx.xxx [Game Server Port] GamePort=xxxxx [Steam Query Port] QueryPort=xxxxx [Server Name] ServerName=[EU/FR]-[PVE] SOG - New Server 09/02 [Server Password] ServerPass= [Admin Password] AdminPass=xxxxxxxx [Max Players] MaxPlayers=70 [Server Directory. NO TRAILING SLASH] serverdir=C:\ConanexilePVE [Use SteamCMD To Update Server? yes/no] UseSteamCMD=yes [SteamCMD Directory. NO TRAILING SLASH] steamcmddir=C:\SteamCMD [Validate Files Every Time SteamCMD Runs? yes/no] validategame=yes [Use Remote Restart ?yes/no] UseRemoteRestart=no [Remote Restart Port] ListenPort=xxxxx [Remote Restart Password] RestartCode=Admin1_xc69ckxu38m66 [Hide Passwords in Log? yes/no] ObfuscatePass=yes [Restart Server Daily? yes/no] RestartDaily=no [Check for Update Every X Minutes? yes/no] CheckForUpdate=yes [Update Check Interval in Minutes 05-59] UpdateInterval=30 [Daily Restart Hours? 00-23] HotHour1=00 HotHour2=00 HotHour3=00 HotHour4=00 HotHour5=00 HotHour6=00 [Daily Restart Minute? 00-59] HotMin=01 [Excessive Memory Amount?] ExMem=6000000000 [Restart On Excessive Memory Use? yes/no] ExMemRestart=no [Running Server with Steam Open? (yes/no)] SteamFix=no [Rotate X Number of Logs every X Hours? yes/no] logRotate=yes logQuantity=10 logHoursBetweenRotate=24 [Use Discord Bot to Send Message Before Restart? yes/no] UseDiscordBot=no DiscordWebHookURL=https://discordapp.com/api/webhooks/XXXXXX/XXXX <- NO TRAILING SLASH AND USE FULL URL FROM WEBHOOK URL ON DISCORD DiscordBotName=Conan Exiles Discord Bot DiscordBotUseTTS=yes DiscordBotAvatarLink= DiscordBotTimeBeforeRestart=5

Problematic :

When there is an update, the server "PVP" shutdown while it should be the "PVE" server, and this without installing the update or rebooting ..

Did I make a mistake?

PS; Also, do you know this script that I can not make it work ? https://github.com/C0nw0nk/SteamCMD-AutoUpdate-Any-Gameserver

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/Dateranoth/ConanExilesServerUtility/issues/22, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AAabii8jR3n-HWgMmiXJCjp7lz7VS5jOks5rdJxggaJpZM4MDaMd.

Mannot74 commented 7 years ago

ConanServerUtility.log.txt

Sorry for my bad english.. :)

To answer you, I already tried to stop both servers, then start the server "PVE" with the script and then launch the "PVP" server, and you already know what happened during The update ..

But I have the impression that the shutdown of the server "PVP" is a coincidence, since the first crash of the server "PVP" this one crash several times (every 2 hours approximately) without the script of "PVE "Be launched ..

So I guess it may not be the script launched since the "PVE" that crashed the "PVP" ..

In any case, the result remains the same, if the "PVP" server has crashed and it has nothing to do with the script launched from the "PVE", the PVE has not restarted or made any Update ..

It's a bit complicated, but I tried to transcribe the situation better. (Moreover, as long as there is no new update, I can not test anything)

I was wondering, if there are multiple servers and the script has to close or kill the process of a single server during an update, this one uses a "PID" to avoid closing all "ConanSandboxServer -Win64-Test " ?

PS : I renamed "ConanServerUtility.log" to "ConanServerUtility.log.txt" to post it here

Dateranoth commented 7 years ago

Ok. That makes more sense that it was just coincidence. V2.8.6 was not updating properly. V2.8.6.1 should have fixed it, but there hasn't been an update since I released it I don't think.

It was a quick fix so it will say Update released today in the log even when there isn't one because of how I changed it.

Dateranoth commented 7 years ago

And to answer your other question, yes it uses PID # and window handles to avoid closing the wrong server. Should be almost impossible unless you started both of them with the script at exactly the same time.

Mannot74 commented 7 years ago

hello ;)

An update has been made, the "PVE" server has automatically updated without any problems.

I set up the script on the server "PVP" and I wait for the next update to confirm if all goes well :)

If I can thank with a small donation ?

Also, I imagine you will set up an automatic reboot message during an update?

Dateranoth commented 7 years ago

Glad it's working for you!

For now, the latest version can notify multiple Twitch channels or a Discord channel. When they release rcon or add console access I will add direct messages in game. Currently that's not possible.

No donation necessary, but if you wish.

donations@gamercide.org

Mannot74 commented 7 years ago

Unfortunately, there was an update tonight at 10.30 PM, the server "PVE" and the server "PVP" did not detect update and did not restart .. I post here the different files.

I renamed for you all file with PVE and PVP in the beginning in txt for post here

PVE file ConanServerUtility.ini.txt PVE file ConanServerUtility.log.txt

And

PVP file ConanServerUtility.ini.txt PVP file ConanServerUtility.log.txt

Dateranoth commented 7 years ago

Yeah, I see the problem. They used HOTFIX instead of PATCH. This pretty much sums up that the RSS feed is going to be continuously unreliable. I started on a different method, and I will release it tonight. Sorry for the trouble.

Dateranoth commented 7 years ago

I created a new issue for this. #24 . I will work hard to have this fixed tonight.

Mannot74 commented 7 years ago

Only thing that changes between the two scripts are the server ports, and the ports of the script, and yes I have booted both servers since the script has a different time. sorry for bad english if you need more Information ask me :)

Mannot74 commented 7 years ago

And i use SteamCMD with the script, you can see with my files ?

Dateranoth commented 7 years ago

It's nothing on your end. It's just my script and how it checks. Thanks for keeping me informed. The new method will work every time, but it will need to be able to write to your SteamCMD dir.

Mannot74 commented 7 years ago

and ok good work for tonight ! Keep me informed :)

Dateranoth commented 7 years ago

@Mannot74 The latest release is out, and I tested it before release. This version uses steamCMD to check for updates. If you are going to run multiple servers I suggest one of two things. Make sure that you start the scripts a minute or two apart or use two different SteamCMD folders. This is because they will both be using SteamCMD to check for updates, and it will likely create problems if they both do the update check at the exact same time.

Mannot74 commented 7 years ago

@Dateranoth Question: we did already use steamCMD with these parameters with the old script v2.8.6.1 ?

[Use SteamCMD To Update Server? yes/no] UseSteamCMD=yes [SteamCMD Directory. NO TRAILING SLASH] steamcmddir=C:\SteamCMD

And yes i know that i need to run script a minute or two apart, that's what i did. i will put one steamcmd folder by server folder.

the new script is ConanServerUtility_x64_v2.9.zip ?

Dateranoth commented 7 years ago

Yes. The script has been using SteamCMD to update the server, but not to check for the update. Now it does.

I'm currently updating to a version that will make sure SteamCMD is not being used by another server just to be safe.

Mannot74 commented 7 years ago

thank you for the answer. I executed the new script, with a steamCMD folder per server folder. I will keep you informed at the time of the next update.

And can you detail these parameters please ?

[Excessive Memory Amount?] ExMem=6000000000 [Restart On Excessive Memory Use? yes/no] ExMemRestart=yes [Running Server with Steam Open? (yes/no)] SteamFix=no

Dateranoth commented 7 years ago

@Mannot74 Excessive Memory Amount allows you to Log when the memory exceeds a certain amount. So if you set ExMem=4000000000 The Script will write the memory usage to the ConanServerUtility.log every 5 minutes whenever the server uses more than 4GB of memory.

If you set

ExMem=4000000000
ExMemRestart=yes

The Script will RESTART the server when it uses more than 4GB of memory.

SteamFix=yes Automatically closes two error windows that popup when running the server on the same machine the client or Steam is running on. This makes sure those errors don't stop the server from starting. If you are not running the client on the same machine it's not necessary.

Mannot74 commented 7 years ago

ok thanks

Mannot74 commented 7 years ago

And i renamed "ConanServerUtility_x64_v2.9" to "ConanServerUtility_x64_v2.9PVE" and "ConanServerUtility_x64_v2.9PVP"

Dateranoth commented 7 years ago

Should work for you. As long as they are in different directories you won't have an issue. I mainly rename them so I can tell icons apart. I released 2.9.1 a bit ago. No need to update if you are using different SteamCMD directories. It just adds a small check just in case someone is using the same directory.

Let me know how it goes.

Mannot74 commented 7 years ago

Ok, Yes I'll tell you how it goes next Conan update.

Mannot74 commented 7 years ago

hello, server PVP and PVE has automatically updated without any problems. :)

Dateranoth commented 7 years ago

Great! Thanks for letting me know it worked. I'm closing this now. Feel free to open a new issue if anything else comes up.