0

I have Python scripts in Linux Server.

I have multiple scripts in directory example /home/python/scripts

all users use same username "python" to login linux server.

If multiple users are run same script is there any issues?

Like if one user start execute one script before finishing this script another user also started same script. Is variable got overwrite ?

What is best way to handle this kind of things.

1
  • It depends on what your scripts do. Multiple users can run the same script but the problem is only present if the script is doing stuff like IO Commented Jul 2, 2017 at 2:49

1 Answer 1

1

So long as the state is not shared in any way between the different interpreters executing the scripts (re each user running the script gets a different Python interpreter process), there should be no problem. However if there is some shared context (such as a log file each process is simultaneously reading/writing from assuming mutual exclusivity), you will very likely have trouble. The trouble could be mitigated in many ways whether through mutexes or other synchronized access.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.