Ignore:
Timestamp:
Sep 9, 2009, 8:30:47 PM (11 years ago)
Author:
Bruno Cornec
Message:
  • Change NFS support into a NetFS support to allow for multiple protocol in addition to NFS (NEEDS TESTING)
  • Better logging to detect a potential nuke issue
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.9/mondo/src/common/libmondo-tools.c

    r2348 r2380  
    395395 * - Used: @c bkpinfo->make_cd_use_lilo
    396396 * - Used: @c bkpinfo->media_device
    397  * - Used: @c bkpinfo->nfs_mount
     397 * - Used: @c bkpinfo->netfs_mount
    398398 * - Used: @c bkpinfo->nonbootable_backup
    399399 * - Used: @c bkpinfo->scratchdir
     
    668668    }                           // end of iso code
    669669
    670     if (bkpinfo->backup_media_type == nfs) {
    671         strcpy(hostname, bkpinfo->nfs_mount);
     670    if (bkpinfo->backup_media_type == netfs) {
     671        strcpy(hostname, bkpinfo->netfs_mount);
    672672        colon = strchr(hostname, ':');
    673673        if (!colon) {
    674             log_it("nfs mount doesn't have a colon in it");
     674            log_it("netfs mount doesn't have a colon in it");
    675675            retval++;
    676676        } else {
     
    680680            hent = gethostbyname(hostname);
    681681            if (!hent) {
    682                 log_it("Can't resolve NFS mount (%s): %s", hostname,
     682                log_it("Can't resolve Network mount (%s): %s", hostname,
    683683                       hstrerror(h_errno));
    684684                retval++;
    685685            } else {
    686686                mr_asprintf(&ip_address, "%s", inet_ntoa((struct in_addr) *((struct in_addr *) hent->h_addr)));
    687                 mr_strcat(ip_address, strchr(bkpinfo->nfs_mount, ':'));
    688                 strcpy(bkpinfo->nfs_mount, ip_address);
     687                mr_strcat(ip_address, strchr(bkpinfo->netfs_mount, ':'));
     688                strcpy(bkpinfo->netfs_mount, ip_address);
    689689                paranoid_free(ip_address);
    690690            }
    691691        }
    692         store_nfs_config();
     692        store_netfs_config();
    693693    }
    694694
     
    759759    }
    760760    g_current_media_number = 1;
    761     bkpinfo->postnuke_tarball[0] = bkpinfo->nfs_mount[0] = '\0';
     761    bkpinfo->postnuke_tarball[0] = bkpinfo->netfs_mount[0] = '\0';
    762762    return (res);
    763763}
     
    846846    bkpinfo->call_after_iso[0] = '\0';
    847847    bkpinfo->kernel_path[0] = '\0';
    848     bkpinfo->nfs_mount[0] = '\0';
    849     bkpinfo->nfs_user = NULL;
    850     bkpinfo->nfs_remote_dir[0] = '\0';
     848    bkpinfo->netfs_mount[0] = '\0';
     849    bkpinfo->netfs_proto = NULL;
     850    bkpinfo->netfs_user = NULL;
     851    bkpinfo->netfs_remote_dir[0] = '\0';
    851852    bkpinfo->postnuke_tarball[0] = '\0';
    852853    bkpinfo->wipe_media_first = FALSE;
Note: See TracChangeset for help on using the changeset viewer.