Lines Matching defs:pair

101  * config file user level Dual copy pair structure
219 _sd_dual_pair_t pair;
220 char *tmptohost = pair.thost;
221 char *tmptofile = pair.tfile;
222 char *fromhost = pair.fhost;
223 char *fromfile = pair.ffile;
224 char *frombitmap = pair.fbitmap;
225 char *tobitmap = pair.tbitmap;
226 char *directfile = pair.directfile;
227 char *group = pair.group;
228 char *diskqueue = pair.diskqueue;
229 char *ctag = pair.ctag;
301 if (parse_cfg_buf(buf, &pair, NULL))
309 if (pair.doasync == 0)
371 pair.doasync ? "async" : "sync");
451 parse_cfg_buf(char *buf, _sd_dual_pair_t *pair, char *lghn)
458 rc = sscanf(buf, "%s %s %s %s %s %s %s %s %s %s %s %s", pair->fhost,
459 pair->ffile, pair->fbitmap, pair->thost, pair->tfile,
460 pair->tbitmap, pair->directfile, sync, pair->group,
461 pair->ctag, options, pair->diskqueue);
466 if (strcmp(pair->diskqueue, place_holder) == 0)
467 (void) strcpy(pair->diskqueue, "");
469 if (strcmp(pair->group, place_holder) == 0)
470 (void) strcpy(pair->group, "");
473 pair->doasync = 0;
475 pair->doasync = 1;
479 pair->thost, pair->tfile);
671 _sd_dual_pair_t pair;
672 char *group = pair.group;
673 char *diskqueue = pair.diskqueue;
703 if (parse_cfg_buf(buf, &pair, NULL))
1237 rewrite_group_diskqueue(CFGFILE *cfg, _sd_dual_pair_t *pair, char *diskqueue)
1254 if (pair->group && pair->group[0]) {
1255 if (strcmp(pair->group, tmpair.group) != 0)
1259 if (strcmp(pair->thost, tmpair.thost) != 0)
1261 if (strcmp(pair->tfile, tmpair.tfile) != 0)
1285 _sd_dual_pair_t pair;
1316 if (parse_cfg_buf(buf, &pair, NULL))
1320 if (strcmp(tohost_arg, pair.thost) == 0 &&
1321 strcmp(tofile_arg, pair.tfile) == 0) {
1322 (void) strcpy(group_arg, pair.group);
1328 if (strcmp(group_arg, pair.group) == 0) {
1347 if (!resourced && strlen(pair.ctag)) { /* uh-oh... */
1352 cfg_resource(cfg, pair.ctag);
1353 ctag = strdup(pair.ctag);
1361 strncmp(ctag_arg, pair.ctag, MAX_RDC_HOST_SIZE))
1368 if (clustered && (ctag_check(pair.fhost, pair.ffile,
1369 pair.fbitmap, pair.thost, pair.tfile, pair.tbitmap,
1370 pair.ctag, qvol) < 0))
1373 if (strlen(pair.diskqueue) > 0) {
1381 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1382 pair.thost, pair.tfile, pair.tbitmap, subcmd, 0,
1383 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1397 rewrite_group_diskqueue(cfg, &pair, qvol);
1401 pair.thost, pair.tfile);
1404 if (strlen(pair.diskqueue) == 0) {
1410 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1411 pair.thost, pair.tfile, pair.tbitmap, subcmd, option,
1412 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1418 if (strlen(pair.diskqueue) == 0) {
1422 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1423 pair.thost, pair.tfile, pair.tbitmap, subcmd, 0,
1424 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1430 if (strlen(pair.diskqueue) == 0) {
1434 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1435 pair.thost, pair.tfile, pair.tbitmap, subcmd, 0,
1436 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1440 if (cfg_vol_disable(cfg, pair.diskqueue, ctag, "sndr") < 0)
1442 "[%s] from configuration"), pair.diskqueue);
1443 rewrite_group_diskqueue(cfg, &pair, place_holder);
1446 "diskqueue from set %s:%s and its group"), pair.thost,
1447 pair.tfile);
1450 if (strlen(pair.diskqueue) == 0) {
1454 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1455 pair.thost, pair.tfile, pair.tbitmap, subcmd, 0,
1456 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1460 if (cfg_vol_disable(cfg, pair.diskqueue, ctag, "sndr") < 0)
1462 "[%s] from configuration"), pair.diskqueue);
1464 rewrite_group_diskqueue(cfg, &pair, place_holder);
1468 pair.thost, pair.tfile);
1471 if (clustered && (ctag_check(pair.fhost, pair.ffile,
1472 pair.fbitmap, pair.thost, pair.tfile, pair.tbitmap,
1473 pair.ctag, qvol) < 0))
1476 if (strlen(pair.diskqueue) == 0) {
1480 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1481 pair.thost, pair.tfile, pair.tbitmap, RDC_CMD_REMQ, 0,
1482 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1486 if (cfg_vol_disable(cfg, pair.diskqueue, ctag, "sndr") < 0)
1488 "[%s] from configuration"), pair.diskqueue);
1490 rewrite_group_diskqueue(cfg, &pair, place_holder);
1495 "with %s failed"), pair.diskqueue, qvol);
1501 pair.diskqueue, qvol);
1503 if (rdc_operation(cfg, pair.fhost, pair.ffile, pair.fbitmap,
1504 pair.thost, pair.tfile, pair.tbitmap, RDC_CMD_ADDQ, 0,
1505 pair.directfile, pair.group, pair.ctag, qvol, &pair.doasync,
1518 rewrite_group_diskqueue(cfg, &pair, qvol);
1522 pair.thost, pair.tfile, qvol);
3472 _sd_dual_pair_t pair;
3574 bzero(&pair, sizeof (pair));
3581 if (parse_cfg_buf(buf, &pair, NULL))
3583 if (pair.group == NULL) /* not in a group */
3585 if (!pair.group[0])
3601 if (strcmp(pair.group, tmpair.group) != 0)
5442 _sd_dual_pair_t pair;
5444 char *host1 = pair.fhost, *host2 = pair.thost;
5445 char *diskqueue = pair.diskqueue;
5461 if (parse_cfg_buf(buf, &pair, lghn))
5463 vol = pair.ffile;
5464 bmp = pair.fbitmap;
5469 vol = pair.tfile;
5470 bmp = pair.tbitmap;
5474 vol = pair.tfile;
5475 bmp = pair.tbitmap;