Skip to content

Pull images ONCE #201

Closed
Closed

Description

@HacksonClark

In order to avoid rate limiting from pulling containers, we should aim to pull once at the start of a benchmark run and reuse these throughout. I believe we have some shell scripts that already do this, but we should make this part of the benchmark itself.

This could go in the conductor along with the dependency check to see if we have the images locally, then we could download them if they are not present.

Activity

  1. added
    enhancement
    on Aug 6, 2025
  2. HacksonClark commented on Aug 6, 2025

    @HacksonClark
    MemberAuthor

    I'm not sure if this will even matter since I think images will be reused anyways, if that's the case please let me know and we can close this issue.

  3. jq-huang commented on Aug 7, 2025

    @jq-huang
    Contributor

    Just to clarify, by 'image' do you mean images for apps?

  4. HacksonClark commented on Aug 7, 2025

    @HacksonClark
    MemberAuthor

    @777lefty Yes, I mean the container images that are used by the pods.

  5. jq-huang commented on Aug 7, 2025

    @jq-huang
    Contributor

    As is mentioned in kubernetes documentation, whether images will be pulled or not depends on imagePullPolicy attribute of the pod. (sees: https://kubernetes.io/docs/concepts/containers/images/#image-pull-policy) There are three possible values for imagePullPolicy:

    1. IfNotPresent: If imagePullPolicy is set to be this value, for all containers in the pod, the image is pulled only if it is not already present locally on the node.
    2. Always: For all containers in the pod, each time kubelet launches a container, it queries the image registry to resolve the required image name to an image digest, and if there is an image with the exact same digest cached locally on the node, then it reuses the locally cached image, otherwise it pulls the image.
    3. Never: kubelet never tries fetching the image, it only uses locally cached ones, if there aren't required images on the node, startup fails.

    In our cases, I checked all the pods for social network, hotel reservation to see their imagePullPolicy values:
    social network: All pods are set to be Always
    hotel reservation: 12 pods are set to be Always, 7 pods are set to be IfNotPresent

  6. HacksonClark commented on Aug 7, 2025

    @HacksonClark
    MemberAuthor

    @777lefty I think we could just switch to IfNotPresent. That seems to make the most sense for our use case.

  7. jq-huang commented on Aug 7, 2025

    @jq-huang
    Contributor

    @777lefty I think we could just switch to IfNotPresent. That seems to make the most sense for our use case.

    Got it, I'll try to modify it

  8. jq-huang commented on Aug 8, 2025

    @jq-huang
    Contributor

    To do so, we need to set the imagePullPolicy field in values.yaml in helm-chart for helm installed apps, and to set the imagePullPolicy field in every *-deployment.yaml files in kubernetes directory for non-helm (kubernetes deployed) apps, I modified the locally files pulled from aiopslab-applications repo and it works, but we might need to commit those modifications to the repository.

  9. HacksonClark commented on Aug 8, 2025

    @HacksonClark
    MemberAuthor

    @777lefty yes, we would commit these

  10. pinned this issue on Aug 8, 2025
  11. unpinned this issue on Aug 8, 2025
  12. HacksonClark commented on Aug 17, 2025

    @HacksonClark
    MemberAuthor

    @777lefty has fixed this issue by updating the submodules.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancement

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions