What is a chunk in layman's term

I can’t wrap my mind about the concept of a chunk in PBS. Quoting from the users guide :

A chunk is a set of resources that are allocated as a unit to a job. All parts of a chunk come from the same host/node. A chunk -level resource or a host-level resource is a resource available at host level.

So in practical terms what does it mean when I select=2 chunks and send a job with qsub ?

thanks !

If the user submits a job without requesting any resources, then the default resources that is requested for that job can be called a chunk. However, if the user is given a chance to submit jobs on one compute node, he can submit jobs , For example user has 1 compute node with 16 cores and 16GB RAM

  • User can submit 16 jobs requesting 1 core and 1 GB RAM, then you will have 16 jobs running on the system, any other jobs would be queued ( chunk = -l select=1:ncpus=1:mem=1gb)
  • User can submit 4 jobs each requesting 4 cores and 4GB RAM , then you will have 4 jobs running on the system, any other jobs would be queued ( chunk = -l select=1:ncpus=4:mem=4gb)
  • User can submit 2 jobs each requesting 8 cores and 8GB RAM and so on ( chunk = -l select=1:ncpus=8:mem=8gb)
  • If user requests 1 core and 16gb RAM, then you can run one job only, rest of the jobs would be queued ( chunk = -l select=1:ncpus=16:mem=16gb)

Chunk gives an opportunity to the end user of how they want to run the job, also you can use split chunks qsub -l select=1:ncpus=3:mem=10gb+2:ncpus=4:mem=3gb+3:ncpus=1:mem=15gb

You are requesting 2 chunks each with 1 cpus ( -l select=2:ncpus=1 )

hope this helps, also please check -l place=(free or scatter or pack or exc ) , it gives you more control on chunk placement.

1 Like

It’s an old thread, but I think the chunk thing leaves a lot of people struggling when crossing over. whether right or not since we are new to the party…

On the one hand, for my own head space, I think of it as somewhat equivalent to a vnode of that requested size (so if the software would run on multiple nodes, it would run across multiple chunks). If someone’s software would not, err… then your life is -l select=1 and I think that is 90% of what we are/will be seeing. Other than MPI, not really sure what would communicate across the chunk/node boundary.

Would be awesome if Altair had or put together examples using chunks and the interaction with some of the current tech and interplay, could straight python, R, or sage or magma or Matlab or huggingface (ok, python again)… but -lselect=1 is intuitive, -lselect=2 in a non MPI, not so much.

Chunks are host/vnode level resources.
Chunks are the smallest part of the resource(s) allocated to a job.

For example , an application requires a total of 64 cores and 64GB memory.

Case1:
There is one compute node with 64 cores and 64GB , then you can request
one chunk of 64 cores and 64gb : -l select=1:ncpus=64:mem=64GB

Case2
There are 4 compute nodes with each with 16 cores and 16GB of memory, then you can request
4 chunks of 16 cores and 16 gb : -l select=4:ncpus=16:mem=16GB

Case3
There are 64 compute nodes, each with 1 core and 1GB of memory
64 chunks of 1 core and 1 gb : -l select=64:ncpus=1:mem=1gb

So you can make your own combination to request the resources require to run the job.

Hope this helps

It does… and I think I understood that, but chunk and the interplay with tech is probably where i was going…

code or an application that can leverage multiple nodes can leverage multiple chunks

code or an application that looks simply at NCPUs/Threads and within those single node confines, not so much… so one chunk only ever.

I think in dealing with researchers making that unfortunate comparison to nodes helps firm it up for them.

So for a single chunk, the largest possible chunk is one node’s full and free resources

(and then again, I could be completely wrong… lol)

Yes, largest possible chunk can be the entire compute node or a portion of the compute nodes resources.

Cluster with 2 compute nodes each with 32 cores and 64GB memory

  1. if the user wants to run a scalable application job across 2 nodes but using 8 core and 16 GB memory from each of the compute node, then

-l select=2:ncpus=8:mem=16gb -l place=scatter

-l select=2:ncpus=8:mem=16gb:mpiprocs=8 -l place=scatter (MPI)

The remaining resources of those nodes can be used by other jobs , until all the resources are used up.

FYI: Split chunk statements

1 Like