Page MenuHomeFeedback Tracker

priority.txt not editable during runtime
Assigned, UrgentPublic

Description

It would be really handy to have either a proto native function added to append new users to the priority queue system OR allow the editing of priority.txt during runtime and have it reload after change. Currently we are unable to append and or edit the priority.txt during runtime. This would help in limiting downtime required to append data to the list.

Thanks.

Something like this perhaps.

proto native bool RemovePriorityQueue( string uid ); //Steam 64 ID , returns true on success
proto native bool AddPriorityQueue( string uid ); //Steam 64 ID returns true on success

Details

Severity
Minor
Resolution
Open
Reproducibility
Always
Operating System
Windows 10
Operating System Version
Latest
Category
General

Event Timeline

Gilni added a subscriber: Gilni.Jun 21 2020, 4:12 PM
Jest added a subscriber: Jest.Jun 21 2020, 4:45 PM

Great Idea, but It would be nice to have some kind of whitelist the mod needs to be put on to be able to access this function. E.g. the Workshop ID needs to be inserted into the server config as an array of Strings. I can already see some modders having the great idea to add random people ore them selfes or anything else

Geez changed the task status from New to Assigned.Jun 22 2020, 11:46 AM
Geez closed this task as Resolved.Oct 15 2020, 11:23 AM
Geez claimed this task.
Geez added a subscriber: Geez.

Hello everyone.
This issue has been resolved internally and will be resolved on Steam in one of the future updates.
Regards,
Geez

Lewk added a subscriber: Lewk.Nov 25 2020, 2:36 PM

@Geez this didn't come in 1.10, when will it come?

Yes, the 1.10 Changelogs indicate this feature was implemented, but it either does not work, or it is not clear on how to use it. Priority.txt is locked during runtime so it's not possible to edit it on the fly.

Geez added a comment.Nov 27 2020, 2:27 PM

Hello again.
We have tested this several times but we do not seem to have any issues editing priority.txt file while the server is running. Can you please provide more details regarding to the problem and possibly list what do you do step by step?
Regards,
Geez

Following steps to reproduce the issue:

  • Download DayZ server from Steam using SteamCMD or Steam Client
  • Create empty priority.txt in server root
  • Start server using following command from a shell: start ./DayZServer_x64.exe -config=serverDZ.cfg -port=2302
  • Open priority.txt using Notepad, adding a SteamID64, Click File->Save

Notepad reports: "The process cannot access the file because it is being used by another process."

Other variant:

  • Download DayZ server from Steam using SteamCMD or Steam Client
  • Create empty priority.txt in server root and add a valid SteamID64
  • Start server using following command from a shell: start ./DayZServer_x64.exe -config=serverDZ.cfg -port=2302
  • Open shell (user or admin) and use following command to append to the file
2>nul (
  >>priority.txt echo off
) && (echo Locked) || (echo Success)

"Locked"

After shutting down the server using X and waiting 30 seconds for the shutdown to complete, both methods succeed.

Geez reopened this task as Need More Info.Nov 27 2020, 4:30 PM

Hello philippjoos.
When you cannot edit the priority.txt file, can you check if there is a dayz executable running in your task manager in the "background processes" tab rather than the running applications tab on top?
Regards,
Geez

Hello Geez,

only 1x DayZServer_x64.exe is running and it is not a background process.

Geez added a comment.Dec 1 2020, 4:44 PM

Do you have issues editing the file even after restarting the server and shutting down all the processes?
Also, we have tested the
" 2>nul (

>>priority.txt echo off

) && (echo Locked) || (echo Success)"
script but it gives a "locked" result even if the server is not running.
Regards,
Geez

Hello @Geez ,

I have embedded the wrong script, sorry about that.

Correct one:

@echo off
:loop
2>nul (
  >>priority.txt echo off
) && (echo WRITEABLE) || (echo LOCKED)
ping 192.0.2.1 -n 1 -w 100 >nul
goto loop

It checks every 100ms if the file is writeable or not. The file becomes locked directly after initiating the mission reading process and unlocks after the process exited.

I got a fresh install of Windows Server 2019 and only using default software except SteamCMD and DayZ Server. I am using the default Administrator user, so I have every permission.

Geez added a comment.Dec 14 2020, 2:18 PM

Hello,
Are there still problems with the file not being editable? Can you try to list everything you have tried so far?
Regards,
Geez

Hello @Geez ,

The issue is still there.

This is everything I have done:

  • Download DayZ server via SteamCMD (v 1.10.153598)
  • Open CMD as Administrator
  • Navigate to installation directory
  • Start server via start /wait ./DayZServer_x64.exe -config=serverDZ.cfg -port=2302 -profiles=profiles
  • Test file writeable state using Notepad

During these steps the above mentioned script was persistently running and writing "WRITEABLE"; Around 5 seconds after the server has been started, the file becomes LOCKED.

I tested on these operating systems:

  • Windows 10 (Bare metal)
  • Windows 10 (VM)
  • Windows Server 2016 (VM)
  • Windows Server 2019 (Bare metal)
  • Windows Server 2019 (VM)
Geez added a comment.Dec 15 2020, 11:02 AM

Hello @Geez ,

The issue is still there.

This is everything I have done:

  • Download DayZ server via SteamCMD (v 1.10.153598)
  • Open CMD as Administrator
  • Navigate to installation directory
  • Start server via start /wait ./DayZServer_x64.exe -config=serverDZ.cfg -port=2302 -profiles=profiles
  • Test file writeable state using Notepad

    During these steps the above mentioned script was persistently running and writing "WRITEABLE"; Around 5 seconds after the server has been started, the file becomes LOCKED.

    I tested on these operating systems:
  • Windows 10 (Bare metal)
  • Windows 10 (VM)
  • Windows Server 2016 (VM)
  • Windows Server 2019 (Bare metal)
  • Windows Server 2019 (VM)

Can you please try to run the server through a simple .bat file without the SteamCMD to see if that changes anything about this? The bat file format should be something similar to

*disc*\*folderpath*\DayZServer_x64.exe -config=serverDZ.cfg -port=2302 -profiles=*path to the folder where the logs should save*

make sure to create a new priority.txt (right click>new text document) file in the server folder before doing so.
Regards,
Geez

Hello @Geez ,

I am only downloading the server files through SteamCMD, the server is started via CMD / Batch script.

I have deleted the existing priority.txt and created a new one. Same result.

sileed added a subscriber: sileed.Jan 19 2021, 1:04 PM

Hello @Geez ,

Do you have an update on this issue yet?

Geez added a comment.May 3 2021, 1:18 PM

Hello philippjoos.
Unfortunately we do not have any updates on this issue as we are still struggling with producing any issues on our end. Any other variable that comes in mind that could be cause of the problem on your end?
Regards,
Geez

Would it be possible to read and edit priority using the server?
If such functionality would be possible to the scripts, you could also check if your list is updating correctly

proto native bool RemovePriorityQueue( string uid ); //Steam 64 ID , returns true on success
proto native bool AddPriorityQueue( string uid ); //Steam 64 ID returns true on success

Hello philippjoos.
Unfortunately we do not have any updates on this issue as we are still struggling with producing any issues on our end. Any other variable that comes in mind that could be cause of the problem on your end?
Regards,
Geez

Hi Geez,

I have tried with several setups already and all have the exact same issue. Since I have some level of log aggregation, I can replicate this issue on around one thousand running community servers, all with strongly varying environments.

Are you able to share what you are using internally to start/run the test servers?

Geez added a comment.May 13 2021, 2:05 PM

Hello again phillippjoos.
Thorough testing has revealed an issue on our end and we are going to look into what can be done.
Regards,
Geez

Geez changed the task status from Need More Info to Assigned.May 13 2021, 2:05 PM
Geez added a comment.May 19 2021, 12:16 PM

Hello again.
The fix is still being worked on and goes through extensive testing internally.
Meanwhile, There is a temporary workaround possible: If you never end the file with ',' or ';' or a space, it should be possible to edit the priority.txt even while the server is running.
However if either of those three (, ; or space) are present at the end of the file, the file will get locked when the server is running.

An example of a file that will be locked

76561197960287930;

Example of a file that will not get locked

76561197960287930

Regards,
Geez

Geez added a comment.May 19 2021, 1:57 PM

Just to clarify on the post above, you can put multiple id's and separate them with ";" but the final one can not have anything behind it.

Works:

76561197960287930;76561197960287930;76561197960287930

Does not work:

76561197960287930;76561197960287930;76561197960287930;

Regards,
Geez

Hi Geez,

Thanks for posting that workaround. I confirmed it working and deployed updates accordingly.

Very nice! Thanks Geez