☁️CSP Related 的子部分

Aliyun 的子部分

OSSutil

阿里版本的 Minio(https://min.io/)

下载 ossutil

首先,你需要下载 ossutil 二进制文件

OS:
curl https://gosspublic.alicdn.com/ossutil/install.sh  | sudo bash
curl -o ossutil-v1.7.19-windows-386.zip https://gosspublic.alicdn.com/ossutil/1.7.19/ossutil-v1.7.19-windows-386.zip

配置 ossutil

./ossutil config
ParamsDescriptionInstruction
endpointthe Endpoint of the region where the Bucket is located通过OSS页面找到endpoin 地址
accessKeyIDOSS AccessKey通过用户中心找到accessKey
accessKeySecretOSS AccessKeySecret通过用户中心找到accessKeySecret
stsTokentoken for sts service可以为空
信息

您还可以直接修改 /home/<$user>/.ossutilconfig 文件来配置ossutil。

展示文件

ossutil ls oss://<$PATH>
For exmaple
ossutil ls oss://csst-data/CSST-20240312/dfs/

下载文件/文件夹

你能用 cp 上传或者下载文件

ossutil cp -r oss://<$PATH> <$PTHER_PATH>
For exmaple
ossutil cp -r oss://csst-data/CSST-20240312/dfs/ /data/nfs/data/pvc... #从OSS下载文件到本地/data/nfs/data/pvc...

上传文件/文件夹

ossutil cp -r <$SOURCE_PATH> oss://<$PATH>
For exmaple
ossutil cp -r /data/nfs/data/pvc/a.txt  oss://csst-data/CSST-20240312/dfs/b.txt #从本地上传文件到OSS
2024年3月24日

ECS

Apsara Stack (Aliyun Directed Cloud)

Append content in /etc/resolv.conf

nameserver 172.27.205.79

And then restart kube-system.coredns-xxxx

2024年3月14日

Zhejianglab 的子部分

👨‍💻Schedmd Slurm

The Slurm Workload Manager, formerly known as Simple Linux Utility for Resource Management (SLURM), or simply Slurm, is a free and open-source job scheduler for Linux and Unix-like kernels, used by many of the world’s supercomputers and computer clusters.

It provides three key functions:

  • allocating exclusive and/or non-exclusive access to resources (computer nodes) to users for some duration of time so they can perform work,
  • providing a framework for starting, executing, and monitoring work, typically a parallel job such as Message Passing Interface (MPI) on a set of allocated nodes, and
  • arbitrating contention for resources by managing a queue of pending jobs.

func1 func1

Content

2024年8月7日

👨‍💻Schedmd Slurm 的子部分

Build & Install

2024年8月7日

CheatSheet

2024年8月7日

CheatSheet 的子部分

File Operations

文件分发

  • sbcast 用于将文件从提交节点分发到计算节点。它特别适用于需要将大量或较大的数据文件分发到多个计算节点的情况,能够减少分发时间并提高效率。
    • 特性
      1. 快速分发文件:将文件快速复制到作业分配的所有计算节点,避免手动分发文件的麻烦。比传统的 scp 或 rsync 更快,尤其是在分发到多个节点时。
      2. 简化作业脚本:自动处理文件分发,使作业脚本更简洁。
      3. 提高效率:通过并行传输提高文件分发速度,尤其是对大文件或多个文件的分发。
    • 用例
      1. 单独使用
      sbcast <source_file> <destination_path>
      1. 嵌入作业脚本
      #!/bin/bash
      #SBATCH --job-name=example_job
      #SBATCH --output=example_job.out
      #SBATCH --error=example_job.err
      #SBATCH --partition=compute
      #SBATCH --nodes=4
      
      # 使用 sbcast 将文件分发到每个节点的 /tmp 目录
      sbcast data.txt /tmp/data.txt
      
      # 执行你的程序,使用分发的文件
      srun my_program /tmp/data.txt

文件收集

  1. 重定向 在提交作业时,可以使用 #SBATCH –output 和 #SBATCH –error 指令将标准输出和标准错误重定向到指定文件

     #SBATCH --output=output.txt
     #SBATCH --error=error.txt

    或者

    sbatch -N2 -w "compute[01-02]" -o result/file/path xxx.slurm
  2. 手动发送目标地址 在提交作业时,在作业中使用 scprsync 将文件从计算节点复制到提交节点

  3. 使用NFS 如果计算集群中配置了共享文件系统(如 NFS、Lustre 或 GPFS),可以直接将结果文件写入共享目录。这样,所有节点生成的结果文件会自动存储在同一个位置

  4. 使用sbcast

2024年8月7日

Configuration Files

2024年8月7日

MPI Libs