I need to maintain a shared XML file on the network, which will be updated by several machines.
My understanding is that 1: There is no native PowerShell or .NET function to maintain an XML file, especially in a concurrent access scenario. And 2: If there is no native power shell mechanism to lock a file on the network, then I would need a generous solution of some type of house. Extreme files can be updated every 15-20 times every year by the machine, and it needs to be scaled along with thousands of machines. But the actual amount of data written is small, while the other things run in the past, are very time consuming, and by diversity. And in most cases this will not be updated on any large scale, mostly on the order of a few hundred machines, maybe to update the file during 15-20 minutes. Therefore, the possibilities of many machines reaching the file at the same time are remote, but still need to address them.
I think the script running on the machines has to change the name of the XML file with the machine name. It can then read XML, modified as needed, write to the previous file, then rename script, there is a wait loop in the script which sees that there is no correct file, but it is again named file, and wait As long as the other machine working with the file gets worked out and changes the file back, and before moving it forward with your efforts. Machine scripts will be started from the central script as remote jobs, which can reduce jobs to reduce the chances of conflict.
My first question is, am I getting a better view of some happiness? I have to be here with simple, I can not get into the database and like It needs to be a simple flat file.
And, there is no other obvious view, can there be any major loss or anyone? I'm sure I'll need to complete different error conditions, and possibly save a data in each file for each machine, after a fallback and all the updates, to drag that data into the main file, The utility is. But I do not want to be a primary workflow if I can help it.
I know, there is a 10,000 ft question, but any insights is appreciated. I have a plan to create a dummy XML file with 1000 records and then the process of running a simple remote script on 3-4 machines, which launches at the same time, and puts a timer on the process, so I see How long does each operation last, and if a machine also needs to wait to write, but if I can learn from someone else's mistakes then I would rather I
No comments:
Post a Comment