Share via

Container Instance mounted file share does not show all files for Linux image depending size of allocated memory

Hannu S 6 Reputation points
2021-03-11T12:27:06.867+00:00

I have linux image that provides predictions as service. We have predictions stored as files in mounted Azure file share.
Linux image use maximum 2 G of memory. Even in Azure it doesnt seem to need more. Locally in docker it allocates less than 1G.

But for a some reason depending on memory that we allocate to image dictates whether all files are available to linux image.
If I create container instance with 1 cpu and 12 G of memory all files are available.... although image does not need it... If I create instance with less than 12 G's of memory some of the files arent available and we get file not found errors in service.

Anyone has any clue what could cause this?

Azure Files
Azure Files

An Azure service that offers file shares in the cloud.

Azure Container Instances
0 comments No comments

2 answers

Sort by: Most helpful
  1. Hannu S 6 Reputation points
    2022-12-12T18:30:02.227+00:00

    Well after few(read lot) weeks of investigating issue, we found out that there was Python-code that was invoked in Container instance after it startted. We this was the main reason for different beheaviour between Docker and container in Azure.
    But then I got to investigate the Python code. And that was amazing loop inside a another loop and so on. So it actually was really memory hugnry and due we had few hundred thousand invoices having average 33 detailt rows per invoice and then same amount of posting rows. So code was quite quickly reserving all possible memory. But that's another story.

    But never, ever start anything after startup, you need to have trigger and monitoring!

    Was this answer helpful?

    0 comments No comments

  2. TravisCragg-MSFT 5,701 Reputation points Microsoft Employee Moderator
    2021-03-23T21:19:53.41+00:00

    This is a strange one, and will require an in-depth look at your environment. To go forward with this, your best bet is to create a support request with Azure Support. If you do not have a support plan but would like to make a support request, please let me know.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.