1
1

- dont require NODES environment variable

- ignore existing nodes that aren't valid

This commit was SVN r6488.
Этот коммит содержится в:
Tim Woodall 2005-07-14 15:40:30 +00:00
родитель b30540646a
Коммит d52252065d
2 изменённых файлов: 11 добавлений и 7 удалений

Просмотреть файл

@ -90,7 +90,7 @@ static size_t orte_ras_bjs_node_slots(char* node_name)
static int orte_ras_bjs_node_resolve(char* node_name, int* node_num) static int orte_ras_bjs_node_resolve(char* node_name, int* node_num)
{ {
/* for now we expect this to be the node number */ /* for now we expect this to be the node number */
if(sscanf(node_name, "%d", node_num) != 1) if(NULL == node_name || sscanf(node_name, "%d", node_num) != 1)
return ORTE_NODE_ERROR; return ORTE_NODE_ERROR;
return ORTE_SUCCESS; return ORTE_SUCCESS;
} }
@ -132,15 +132,17 @@ static int orte_ras_bjs_discover(opal_list_t* nodelist)
} }
if(orte_ras_bjs_node_state(node_num) != ORTE_NODE_STATE_UP) { if(orte_ras_bjs_node_state(node_num) != ORTE_NODE_STATE_UP) {
opal_output(0, "error: a specified node (%s) is not up.\n", opal_list_remove_item(nodelist,item);
node->node_name); OBJ_DESTRUCT(item);
return ORTE_NODE_DOWN; item = next;
continue;
} }
if(bproc_access(node_num, BPROC_X_OK) != 0) { if(bproc_access(node_num, BPROC_X_OK) != 0) {
opal_output(0, "error: a specified node (%s) is not accessible.\n", opal_list_remove_item(nodelist,item);
node->node_name); OBJ_DESTRUCT(item);
return ORTE_NODE_ERROR; item = next;
continue;
} }
/* try and determine the number of available slots */ /* try and determine the number of available slots */

Просмотреть файл

@ -103,9 +103,11 @@ static int orte_ras_bjs_open(void)
static orte_ras_base_module_t *orte_ras_bjs_init(int* priority) static orte_ras_base_module_t *orte_ras_bjs_init(int* priority)
{ {
#if 0
if(getenv("NODES") == NULL) { if(getenv("NODES") == NULL) {
return NULL; return NULL;
} }
#endif
*priority = mca_ras_bjs_component.priority; *priority = mca_ras_bjs_component.priority;
return &orte_ras_bjs_module; return &orte_ras_bjs_module;
} }