projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch '13140-cwl-conformance' refs #13140
[arvados.git]
/
services
/
crunch-dispatch-slurm
/
crunch-dispatch-slurm.go
diff --git
a/services/crunch-dispatch-slurm/crunch-dispatch-slurm.go
b/services/crunch-dispatch-slurm/crunch-dispatch-slurm.go
index dab6025cd832fefdc1e5c0043913c078905bb2ef..23e4b3a8cb456aac06f644c0219148967586fe71 100644
(file)
--- a/
services/crunch-dispatch-slurm/crunch-dispatch-slurm.go
+++ b/
services/crunch-dispatch-slurm/crunch-dispatch-slurm.go
@@
-50,6
+50,10
@@
type Dispatcher struct {
// Example: []string{"crunch-run", "--cgroup-parent-subsystem=memory"}
CrunchRunCommand []string
// Example: []string{"crunch-run", "--cgroup-parent-subsystem=memory"}
CrunchRunCommand []string
+ // Extra RAM to reserve (in Bytes) for SLURM job, in addition
+ // to the amount specified in the container's RuntimeConstraints
+ ReserveExtraRAM int64
+
// Minimum time between two attempts to run the same container
MinRetryPeriod arvados.Duration
}
// Minimum time between two attempts to run the same container
MinRetryPeriod arvados.Duration
}
@@
-199,7
+203,7
@@
func (disp *Dispatcher) checkSqueueForOrphans() {
}
func (disp *Dispatcher) sbatchArgs(container arvados.Container) ([]string, error) {
}
func (disp *Dispatcher) sbatchArgs(container arvados.Container) ([]string, error) {
- mem := int64(math.Ceil(float64(container.RuntimeConstraints.RAM+container.RuntimeConstraints.KeepCacheRAM) / float64(1048576)))
+ mem := int64(math.Ceil(float64(container.RuntimeConstraints.RAM+container.RuntimeConstraints.KeepCacheRAM
+disp.ReserveExtraRAM
) / float64(1048576)))
var disk int64
for _, m := range container.Mounts {
var disk int64
for _, m := range container.Mounts {