当前位置: 首页 > article >正文

OpenShift AI - 启用过时版本的 Notebook 镜像

《OpenShift / RHEL / DevSecOps 汇总目录》
说明:本文已经在 OpenShift 4.18 + OpenShift AI 2.19 的环境中验证

文章目录

  • 查看可用 Notebook 镜像
    • 控制台查看
    • 命令行查看
  • Notebook 镜像、Image Stream 和 Image Registry Repository 对应关系
  • 启用老版本的 Notebook 镜像
  • 参考

查看可用 Notebook 镜像

控制台查看

在 OpenShift AI 中可以在一个项目的 Workbench 中或者在 Applications -> Enabled 中通过选择特定的 Notebook Image 来运行 Notebook Server。下图中 OpenShift AI 内置的 Notebook Image 包含的软件配置可参见官方 《Red Hat OpenShift AI: Supported Configurations》中 “Supported workbench images” 小节的说明。
在这里插入图片描述
可看到当前 OpenShift AI 有 2 个可用的 TensFlow版本:2025.1 和 2024.2。点击版本右侧的图标,将显示该版本镜像中所含软件包的情况。RedHat 会每 6 个月对 Notebook 镜像升级一次,同时会淘汰过时的老版本镜像(后面将介绍如何启用老版本 Notebook 镜像)。
在这里插入图片描述

命令行查看

通过以下命令可以查看在 OpenShift AI 中可用的 Notebook 镜像。

$ oc get is -n redhat-ods-applications
NAME                                IMAGE REPOSITORY                                                                                             TAGS                                     UPDATED
code-server-notebook                image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/code-server-notebook                2023.2,2024.1,2024.2,2025.1              5 days ago
cuda-rhel9                          image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/cuda-rhel9
cuda-rstudio-rhel9                  image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/cuda-rstudio-rhel9
jupyter-rocm-minimal                image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/jupyter-rocm-minimal                2024.2,2025.1                            5 days ago
jupyter-rocm-pytorch                image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/jupyter-rocm-pytorch                2024.2,2025.1                            5 days ago
jupyter-rocm-tensorflow             image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/jupyter-rocm-tensorflow             2024.2,2025.1                            5 days ago
minimal-gpu                         image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/minimal-gpu                         1.2,2023.1,2023.2,2024.1,2024.2,2025.1   5 days ago
odh-trustyai-notebook               image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/odh-trustyai-notebook               2023.1,2023.2,2024.1,2024.2,2025.1       5 days ago
pytorch                             image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/pytorch                             1.2,2023.1,2023.2,2024.1,2024.2,2025.1   5 days ago
rstudio-rhel9                       image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/rstudio-rhel9
s2i-generic-data-science-notebook   image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/s2i-generic-data-science-notebook   1.2,2023.1,2023.2,2024.1,2024.2,2025.1   5 days ago
s2i-minimal-notebook                image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/s2i-minimal-notebook                1.2,2023.1,2023.2,2024.1,2024.2,2025.1   5 days ago
tensorflow                          image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/tensorflow                          1.2,2023.1,2023.2,2024.1,2024.2,2025.1   5 days ago

执行以下命令可查看上一步显示的名为 tensorflow 的 ImageStream 包含的信息,包括 Tag 和对应的镜像地址。在返回结果的 status 中可以看到 tensorflow 有哪些可用的 tag,可以看到除了在控制台中看到的 2025.1 和 2024.2 以外还有 2024.1、2023.2、2023.1、1.2。

$ oc get is -n redhat-ods-applications tensorflow -oyaml
。。。
status:dockerImageRepository: image-registry.openshift-image-registry.svc:5000/redhat-ods-applications/tensorflowtags:- items:- created: "2025-05-27T01:53:53Z"dockerImageReference: quay.io/modh/cuda-notebooks@sha256:6fadedc5a10f5a914bb7b27cd41bc644392e5757ceaf07d930db884112054265generation: 2image: sha256:6fadedc5a10f5a914bb7b27cd41bc644392e5757ceaf07d930db884112054265tag: "1.2"- items:- created: "2025-05-27T01:53:53Z"dockerImageReference: quay.io/modh/cuda-notebooks@sha256:88d80821ff8c5d53526794261d519125d0763b621d824f8c3222127dab7b6cc8generation: 2image: sha256:88d80821ff8c5d53526794261d519125d0763b621d824f8c3222127dab7b6cc8tag: "2023.1"- items:- created: "2025-05-27T01:53:53Z"dockerImageReference: quay.io/modh/cuda-notebooks@sha256:3da74d732d158b92eaada0a27fb7067fa18c8bde5033c672e23caed0f21d6481generation: 2image: sha256:3da74d732d158b92eaada0a27fb7067fa18c8bde5033c672e23caed0f21d6481tag: "2023.2"- items:- created: "2025-05-27T01:53:53Z"dockerImageReference: quay.io/modh/cuda-notebooks@sha256:0e57a0b756872636489ccd713dc9f00ad69d0c481a66ee0de97860f13b4fedcdgeneration: 2image: sha256:0e57a0b756872636489ccd713dc9f00ad69d0c481a66ee0de97860f13b4fedcdtag: "2024.1"- items:- created: "2025-05-27T01:53:53Z"dockerImageReference: quay.io/modh/cuda-notebooks@sha256:99d3fb964e635873214de4676c259a96c2ea25f3f79cc4bead5bc9f39aba34c0generation: 2image: sha256:99d3fb964e635873214de4676c259a96c2ea25f3f79cc4bead5bc9f39aba34c0tag: "2024.2"- items:- created: "2025-05-27T01:53:53Z"dockerImageReference: quay.io/modh/cuda-notebooks@sha256:3c7d3cb69cb311925afd67d05e54b0d34a2acd6990ff12a16bb3ee5cb8dbd265generation: 2image: sha256:3c7d3cb69cb311925afd67d05e54b0d34a2acd6990ff12a16bb3ee5cb8dbd265tag: "2025.1"
。。。

查看名为 tensorflow:2023.1 的 imagestreamtag 。其中可以从以下部分了解该 imagestreamtag 对应的镜像情况,例如 notebook-software,notebook-python-dependencies,依赖镜像 quay.io/modh/cuda-notebooks,其中 opendatahub.io/image-tag-outdated 为 true。

$ oc get imagestreamtag tensorflow:2023.1 -n redhat-ods-applications -oyaml
。。。
image:metadata:name: 'sha256:88d80821ff8c5d53526794261d519125d0763b621d824f8c3222127dab7b6cc8'uid: f90e20f0-84bb-4f1f-9841-896680f67436resourceVersion: '65395'creationTimestamp: '2025-05-27T01:53:53Z'annotations:image.openshift.io/dockerLayersOrder: ascendingopendatahub.io/image-tag-outdated: 'true'opendatahub.io/notebook-build-commit: 07015ecopendatahub.io/notebook-python-dependencies: |[{"name":"TensorFlow","version":"2.11"},{"name":"Tensorboard","version":"2.11"},{"name":"Boto3","version":"1.26"},{"name":"Kafka-Python","version":"2.0"},{"name":"Kfp-tekton","version":"1.5"},{"name":"Matplotlib","version":"3.6"},{"name":"Numpy","version":"1.24"},{"name":"Pandas","version":"1.5"},{"name":"Scikit-learn","version":"1.2"},{"name":"Scipy","version":"1.10"},{"name":"Elyra","version":"3.15"}]opendatahub.io/notebook-software: |[{"name":"CUDA","version":"11.8"},{"name":"Python","version":"v3.9"},{"name":"TensorFlow","version":"2.11"}]openshift.io/imported-from: quay.io/modh/cuda-notebooks
。。。

Notebook 镜像、Image Stream 和 Image Registry Repository 对应关系

Notebook 镜像名称Image Stream 名称Image Registry Repository说明
Minimal Pythons2i-minimal-notebookquay.io/modh/odh-pytorch-notebook只提供基础 Python 运行环境,不提供任何附加包
Standard Data Sciences2i-generic-data-science-notebookquay.io/modh/odh-generic-data-science-notebook提供常用的科学计算包,但不提供 TensorFlow 或 PyTorch
CUDAminimal-gpuquay.io/modh/cuda-notebooks使用 GPU 加速库和优化工具来优化工作
PyTorchpytorchquay.io/modh/odh-pytorch-notebook利用 PyTorch 构建、训练和部署机器学习模型
TensorFlowtensorflowquay.io/modh/cuda-notebooks利用 TensorFlow 构建、训练和部署机器学习模型
TrustyAIodh-trustyai-notebookquay.io/modh/odh-trustyai-notebook利用 TrustyAI 构建、训练和部署机器学习模型
ROCmjupyter-rocm-minimalquay.io/modh/rocm-notebooks使用 AMD GPU 运行通用的 ML 工作负载
ROCm-PyTorchjupyter-rocm-pytorchquay.io/modh/rocm-notebooks使用 AMD GPU 运行基于 PyTorch 的 ML 工作负载
ROCm-TensorFlowjupyter-rocm-tensorflowquay.io/modh/rocm-notebook使用 AMD GPU 运行通基于 TensorFlow 的工作负载
code-servercode-server-notebookquay.io/modh/codeserver使用基于 VScode 的IDE

启用老版本的 Notebook 镜像

  1. 编辑名为 tensorflow:2023.1 的 imagestreamtag 对象,删除包含 opendatahub.io/image-tag-outdated: "true"的 3 行,然后保存。
  2. 然后在 OpenShift AI 控制中可看到原来未显示的过时老版本 2023.1 被显示出来了。
    在这里插入图片描述

注意

  1. 被恢复启用的老版本 Notebook 镜像因为已经超过 RedHat 支持的生命周期,因此即便有 Bug,也得不到官方支持。
  2. 当 OpenShift 集群被重启后,被恢复启用的老版本 Notebook 镜像会再次被重置为隐藏状态。

参考

https://access.redhat.com/articles/rhoai-supported-configs

https://ai-on-openshift.io/odh-rhoai/custom-notebooks/
https://github.com/opendatahub-io/notebooks/wiki/Workbenches
https://github.com/opendatahub-io/notebooks/wiki/Developer-Guide
https://github.com/opendatahub-io/notebooks/wiki/User-Guide

https://github.com/opendatahub-io/notebooks
https://github.com/opendatahub-io/notebooks/wiki/Workbenches

https://docs.redhat.com/en/documentation/red_hat_openshift_ai_self-managed/2.20/html/managing_openshift_ai/creating-custom-workbench-images
https://docs.redhat.com/en/documentation/red_hat_openshift_ai_self-managed/2.20/html/managing_openshift_ai/creating-custom-workbench-images#creating-a-custom-image-from-default-image_custom-images

https://github.com/opendatahub-io-contrib/workbench-images
https://github.com/opendatahub-io-contrib/workbench-images/releases
https://github.com/opendatahub-io-contrib/workbench-images/blob/main/DEVELOPMENT.md

https://quay.io/repository/opendatahub-contrib/workbench-images
https://quay.io/organization/modh

http://www.lryc.cn/news/2395964.html

相关文章:

  • Redis 缓存穿透、缓存击穿、缓存雪崩详解与解决方案
  • sass高阶应用
  • docker docker-ce docker.io
  • DQN和DDQN(进阶版)
  • 【组件】翻牌器效果
  • CentOS 7 环境中部署 LNMP(Linux + Nginx + MySQL 5.7 + PHP)
  • NX811NX816美光颗粒固态NX840NX845
  • 捋捋wireshark
  • c++学习之---模版
  • MyBatis-Flex 全面指南:下一代轻量级持久层框架实战入门
  • 第十六章 EMQX黑名单与连接抖动检测
  • WebSphere(WAS)
  • 新编辑器编写指南--给自己的备忘
  • xPSR
  • 鸿蒙网络数据传输案例实战
  • 【JavaEE】-- 网络原理
  • 1.RV1126-OPENCV 交叉编译
  • PySide6 GUI 学习笔记——常用类及控件使用方法(标签控件QLabel)
  • CSS (mask)实现服装动态换色:创意与技术的完美融合
  • 基于51单片机的音乐盒汽车喇叭调音量proteus仿真
  • 彻底理解Spring三级缓存机制
  • MacOs 安装局域网 gitlab 记录
  • Flutter 与 Android 原生布局组件对照表(完整版)
  • 【产品经理从0到1】自媒体端产品设计
  • 017搜索之深度优先DFS——算法备赛
  • 解决 maven编译项目-Fatal error compiling: 无效的目标发行版: 21 -> [Help 1]
  • Thinkphp6实现websocket
  • web-css
  • 关于 smali:2. 从 Java 到 Smali 的映射
  • 三、zookeeper 常用shell命令