@@ -331,7 +331,7 @@ def is_scheduler_logging_enabled():
331
331
>>> print(slurmctld.is_scheduler_logging_enabled())
332
332
False
333
333
"""
334
- return Config.load().scheduler_logging
334
+ return Config.load().scheduler_logging_enabled
335
335
336
336
337
337
def set_fair_share_dampening_factor (factor ):
@@ -577,10 +577,6 @@ cdef class Config:
577
577
out[" mpi_config" ] = self .mpi_config.to_dict()
578
578
return out
579
579
580
- @property
581
- def accounting_storage_tres (self ):
582
- return cstr.to_list(self .ptr.accounting_storage_tres)
583
-
584
580
@property
585
581
def accounting_storage_enforce (self ):
586
582
cdef char tmp[128 ]
@@ -608,14 +604,14 @@ cdef class Config:
608
604
def accounting_storage_parameters (self ):
609
605
return cstr.to_dict(self .ptr.accounting_storage_params)
610
606
611
- @property
612
- def accounting_storage_password (self ):
613
- return cstr.to_unicode(self .ptr.accounting_storage_pass)
614
-
615
607
@property
616
608
def accounting_storage_port (self ):
617
609
return u16_parse(self .ptr.accounting_storage_port)
618
610
611
+ @property
612
+ def accounting_storage_tres (self ):
613
+ return cstr.to_list(self .ptr.accounting_storage_tres)
614
+
619
615
@property
620
616
def accounting_storage_type (self ):
621
617
return cstr.to_unicode(self .ptr.accounting_storage_type)
@@ -664,9 +660,9 @@ cdef class Config:
664
660
return cstr.to_list(self .ptr.authinfo)
665
661
666
662
@property
667
- def auth_alt_params (self ):
668
- # TODO: maybe dict?
669
- return cstr.to_list( self .ptr.authalt_params )
663
+ def auth_alt_parameters (self ):
664
+ return cstr.to_dict( self .ptr.authalt_params, delim1 = " , " ,
665
+ delim2 = " = " , def_value = True )
670
666
671
667
@property
672
668
def auth_type (self ):
@@ -683,14 +679,15 @@ cdef class Config:
683
679
684
680
@property
685
681
def bcast_parameters (self ):
686
- return cstr.to_list(self .ptr.bcast_parameters)
682
+ return cstr.to_dict(self .ptr.authalt_params, delim1 = " ," ,
683
+ delim2 = " =" , def_value = True )
687
684
688
685
@property
689
686
def burst_buffer_type (self ):
690
687
return cstr.to_unicode(self .ptr.bb_type)
691
688
692
689
@property
693
- def boot_time (self ):
690
+ def slurmctld_boot_time (self ):
694
691
return _raw_time(self .ptr.boot_time)
695
692
696
693
@property
@@ -711,21 +708,17 @@ cdef class Config:
711
708
712
709
@property
713
710
def communication_parameters (self ):
714
- return cstr.to_list(self .ptr.comm_params)
711
+ # TODO: check again
712
+ return cstr.to_dict(self .ptr.comm_params, delim1 = " ," ,
713
+ delim2 = " =" , def_value = True )
715
714
716
715
@property
717
716
def complete_wait_time (self ):
718
717
# seconds
719
718
return u16_parse(self .ptr.complete_wait)
720
719
721
720
@property
722
- def disable_root_jobs (self ):
723
- if self .ptr.conf_flags & slurm.CONF_FLAG_DRJ:
724
- return True
725
- return False
726
-
727
- @property
728
- def default_cpu_frequency (self ):
721
+ def default_cpu_frequency_governor (self ):
729
722
return cpu_freq_int_to_str(self .ptr.cpu_freq_def)
730
723
731
724
@property
@@ -752,10 +745,20 @@ cdef class Config:
752
745
def default_memory_per_node (self ):
753
746
return _get_memory(self .ptr.def_mem_per_cpu, per_cpu = False )
754
747
748
+ # TODO: DefCpuPerGPU
749
+ # TODO: DefMemPerGPU
750
+
755
751
@property
756
752
def dependency_parameters (self ):
753
+ # TODO: check format again
757
754
return cstr.to_list(self .ptr.dependency_params)
758
755
756
+ @property
757
+ def disable_root_jobs (self ):
758
+ if self .ptr.conf_flags & slurm.CONF_FLAG_DRJ:
759
+ return True
760
+ return False
761
+
759
762
@property
760
763
def eio_timeout (self ):
761
764
# seconds
@@ -780,6 +783,10 @@ cdef class Config:
780
783
return cstr.to_list_with_count(self .ptr.epilog_slurmctld,
781
784
self .ptr.epilog_slurmctld_cnt)
782
785
786
+ @property
787
+ def fair_share_dampening_factor (self ):
788
+ return u16_parse(self .ptr.fs_dampening_factor)
789
+
783
790
@property
784
791
def federation_parameters (self ):
785
792
return cstr.to_list(self .ptr.fed_params)
@@ -788,12 +795,6 @@ cdef class Config:
788
795
def first_job_id (self ):
789
796
return u32_parse(self .ptr.first_job_id)
790
797
791
- @property
792
- def fair_share_dampening_factor (self ):
793
- return u16_parse(self .ptr.fs_dampening_factor)
794
-
795
- # getnameinfo_cache_timeout
796
-
797
798
@property
798
799
def get_environment_timeout (self ):
799
800
return u16_parse(self .ptr.get_env_timeout)
@@ -802,14 +803,14 @@ cdef class Config:
802
803
def gres_types (self ):
803
804
return cstr.to_list(self .ptr.gres_plugins)
804
805
805
- @property
806
- def group_update_time (self ):
807
- return u16_parse(self .ptr.group_time)
808
-
809
806
@property
810
807
def group_update_force (self ):
811
808
return u16_parse_bool(self .ptr.group_force)
812
809
810
+ @property
811
+ def group_update_time (self ):
812
+ return u16_parse(self .ptr.group_time)
813
+
813
814
@property
814
815
def default_gpu_frequency (self ):
815
816
return cstr.to_unicode(self .ptr.gpu_freq_def)
@@ -847,14 +848,14 @@ cdef class Config:
847
848
def interactive_step_options (self ):
848
849
return cstr.to_unicode(self .ptr.interactive_step_opts)
849
850
850
- @property
851
- def job_accounting_gather_frequency (self ):
852
- return cstr.to_dict(self .ptr.job_acct_gather_freq)
853
-
854
851
@property
855
852
def job_accounting_gather_type (self ):
856
853
return cstr.to_unicode(self .ptr.job_acct_gather_type)
857
854
855
+ @property
856
+ def job_accounting_gather_frequency (self ):
857
+ return cstr.to_dict(self .ptr.job_acct_gather_freq)
858
+
858
859
@property
859
860
def job_accounting_gather_parameters (self ):
860
861
return cstr.to_list(self .ptr.job_acct_gather_params)
@@ -869,6 +870,7 @@ cdef class Config:
869
870
870
871
@property
871
872
def job_completion_parameters (self ):
873
+ # TODO: maybe dict?
872
874
return cstr.to_list(self .ptr.job_comp_params)
873
875
874
876
@property
@@ -906,16 +908,12 @@ cdef class Config:
906
908
def job_submit_plugins (self ):
907
909
return cstr.to_list(self .ptr.job_submit_plugins)
908
910
909
- @property
910
- def keepalive_interval (self ):
911
- return u32_parse(self .ptr.keepalive_interval)
912
-
913
911
@property
914
912
def kill_on_bad_exit (self ):
915
913
return u16_parse_bool(self .ptr.kill_on_bad_exit)
916
914
917
915
@property
918
- def kill_wait (self ):
916
+ def kill_wait_time (self ):
919
917
# seconds
920
918
return u16_parse(self .ptr.kill_wait)
921
919
@@ -998,6 +996,7 @@ cdef class Config:
998
996
999
997
@property
1000
998
def mpi_parameters (self ):
999
+ # TODO: check format again
1001
1000
return cstr.to_list(self .ptr.mpi_params)
1002
1001
1003
1002
@property
@@ -1036,6 +1035,7 @@ cdef class Config:
1036
1035
1037
1036
@property
1038
1037
def preempt_parameters (self ):
1038
+ # TODO: check format again
1039
1039
return cstr.to_list(self .ptr.preempt_params)
1040
1040
1041
1041
@property
@@ -1057,7 +1057,7 @@ cdef class Config:
1057
1057
1058
1058
@property
1059
1059
def priority_calc_period (self ):
1060
- # seconds
1060
+ # TODO: seconds or minutes?
1061
1061
return u32_parse(self .ptr.priority_calc_period)
1062
1062
1063
1063
@property
@@ -1070,7 +1070,7 @@ cdef class Config:
1070
1070
1071
1071
@property
1072
1072
def priortiy_max_age (self ):
1073
- # seconds?
1073
+ # TODO: seconds or minutes ?
1074
1074
return u32_parse(self .ptr.priority_max_age)
1075
1075
1076
1076
@property
@@ -1087,27 +1087,27 @@ cdef class Config:
1087
1087
1088
1088
@property
1089
1089
def priority_weight_age (self ):
1090
- return u32_parse(self .ptr.priority_weight_age)
1090
+ return u32_parse(self .ptr.priority_weight_age, zero_is_noval = False )
1091
1091
1092
1092
@property
1093
1093
def priority_weight_assoc (self ):
1094
- return u32_parse(self .ptr.priority_weight_assoc)
1094
+ return u32_parse(self .ptr.priority_weight_assoc, zero_is_noval = False )
1095
1095
1096
1096
@property
1097
1097
def priority_weight_fair_share (self ):
1098
- return u32_parse(self .ptr.priority_weight_fs)
1098
+ return u32_parse(self .ptr.priority_weight_fs, zero_is_noval = False )
1099
1099
1100
1100
@property
1101
1101
def priority_weight_job_size (self ):
1102
- return u32_parse(self .ptr.priority_weight_js)
1102
+ return u32_parse(self .ptr.priority_weight_js, zero_is_noval = False )
1103
1103
1104
1104
@property
1105
1105
def priority_weight_partition (self ):
1106
- return u32_parse(self .ptr.priority_weight_part)
1106
+ return u32_parse(self .ptr.priority_weight_part, zero_is_noval = False )
1107
1107
1108
1108
@property
1109
1109
def priority_weight_qos (self ):
1110
- return u32_parse(self .ptr.priority_weight_qos)
1110
+ return u32_parse(self .ptr.priority_weight_qos, zero_is_noval = False )
1111
1111
1112
1112
@property
1113
1113
def priority_weight_tres (self ):
@@ -1178,12 +1178,10 @@ cdef class Config:
1178
1178
1179
1179
@property
1180
1180
def resume_rate (self ):
1181
- # minutes?
1182
1181
return u16_parse(self .ptr.resume_rate)
1183
1182
1184
1183
@property
1185
1184
def resume_timeout (self ):
1186
- # seconds
1187
1185
return u16_parse(self .ptr.resume_timeout)
1188
1186
1189
1187
@property
@@ -1192,8 +1190,7 @@ cdef class Config:
1192
1190
1193
1191
@property
1194
1192
def reservation_over_run (self ):
1195
- # minutes
1196
- return u16_parse(self .ptr.resv_over_run)
1193
+ return u16_parse(self .ptr.resv_over_run, zero_is_noval = False )
1197
1194
1198
1195
@property
1199
1196
def reservation_prolog (self ):
@@ -1208,11 +1205,13 @@ cdef class Config:
1208
1205
return cstr.to_unicode(self .ptr.sched_logfile)
1209
1206
1210
1207
@property
1211
- def scheduler_logging (self ):
1208
+ def scheduler_logging_enabled (self ):
1209
+ # TODO: check again
1212
1210
return u16_parse_bool(self .ptr.sched_log_level)
1213
1211
1214
1212
@property
1215
1213
def scheduler_parameters (self ):
1214
+ # TODO: check format again
1216
1215
return cstr.to_list(self .ptr.sched_params)
1217
1216
1218
1217
@property
@@ -1265,8 +1264,6 @@ cdef class Config:
1265
1264
def slurmd_user_name (self ):
1266
1265
return cstr.to_unicode(self .ptr.slurmd_user_name)
1267
1266
1268
- # TODO: char *slurmctld_addr
1269
-
1270
1267
@property
1271
1268
def slurmctld_log_level (self ):
1272
1269
return _log_level_int_to_str(self .ptr.slurmctld_debug)
@@ -1309,6 +1306,7 @@ cdef class Config:
1309
1306
1310
1307
@property
1311
1308
def slurmctld_parameters (self ):
1309
+ # TODO: check format again
1312
1310
return cstr.to_list(self .ptr.slurmctld_params)
1313
1311
1314
1312
@property
@@ -1321,6 +1319,7 @@ cdef class Config:
1321
1319
1322
1320
@property
1323
1321
def slurmd_parameters (self ):
1322
+ # TODO: Check again
1324
1323
return cstr.to_list(self .ptr.slurmd_params)
1325
1324
1326
1325
@property
@@ -1336,7 +1335,7 @@ cdef class Config:
1336
1335
return cstr.to_unicode(self .ptr.slurmd_spooldir)
1337
1336
1338
1337
@property
1339
- def slurmd_syslog_debug_level (self ):
1338
+ def slurmd_syslog_level (self ):
1340
1339
return _log_level_int_to_str(self .ptr.slurmd_syslog_debug)
1341
1340
1342
1341
@property
@@ -1398,6 +1397,7 @@ cdef class Config:
1398
1397
1399
1398
@property
1400
1399
def switch_parameters (self ):
1400
+ # TODO: Check format again
1401
1401
return cstr.to_list(self .ptr.switch_param)
1402
1402
1403
1403
@property
@@ -1440,6 +1440,7 @@ cdef class Config:
1440
1440
1441
1441
@property
1442
1442
def topology_parameters (self ):
1443
+ # TODO: check format again
1443
1444
return cstr.to_list(self .ptr.topology_param)
1444
1445
1445
1446
@property
@@ -1480,11 +1481,12 @@ cdef class Config:
1480
1481
1481
1482
@property
1482
1483
def default_job_wait_time (self ):
1484
+ # TODO: reconsider name
1483
1485
return u16_parse(self .ptr.wait_time)
1484
1486
1485
1487
@property
1486
1488
def x11_parameters (self ):
1487
- return cstr.to_unicode (self .ptr.x11_params)
1489
+ return cstr.to_list (self .ptr.x11_params)
1488
1490
1489
1491
1490
1492
def _str_to_bool (val , true_str , false_str ):
0 commit comments