Commit 8a5b0190 authored by Ramon Nou's avatar Ramon Nou
Browse files

Update scripts tests

parent 4e43dfac
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -48,7 +48,7 @@ extern "C" {
#include <sys/statfs.h>
#include <sys/statvfs.h>
}
#define GKFS_ENABLE_EC 1

#ifdef GKFS_ENABLE_EC
#include <jerasure/jerasure.h>
#include <jerasure/reed_sol.h>
@@ -867,7 +867,7 @@ gkfs_dup2(const int oldfd, const int newfd) {
    return CTX->file_map()->dup2(oldfd, newfd);
}


#ifdef GKFS_ENABLE_EC
bool
gkfs_ecc_write(std::shared_ptr<gkfs::filemap::OpenFile> file, size_t count,
               off64_t offset, off64_t updated_size) {
@@ -955,7 +955,7 @@ gkfs_ecc_write(std::shared_ptr<gkfs::filemap::OpenFile> file, size_t count,
    }
    return true;
}

#endif
/**
 * Actual write function for all gkfs write operations
 * errno may be set
@@ -1185,8 +1185,8 @@ gkfs_do_read(const gkfs::filemap::OpenFile& file, char* buf, size_t count,
    std::set<int8_t> failed; // set with failed targets.
    if(CTX->get_replicas() != 0) {

        ret = gkfs::rpc::forward_read(file->path(), buf, offset, count, CTX->get_replicas(),
                                      failed);
        ret = gkfs::rpc::forward_read(file->path(), buf, offset, count,
                                      CTX->get_replicas(), failed);
        while(ret.first == EIO) {
#ifdef GKFS_ENABLE_EC
            LOG(WARNING, "failed to read");
+10 −11
Original line number Diff line number Diff line
@@ -38,7 +38,6 @@

#include <unordered_set>

#define GKFS_ENABLE_EC 1
#ifdef GKFS_ENABLE_EC
#include <jerasure/jerasure.h>
#include <jerasure/reed_sol.h>
@@ -572,7 +571,7 @@ forward_write(const string& path, const void* buf, const off64_t offset,
        return make_pair(0, out_size);
}


#ifdef GKFS_ENABLE_EC
// To recover a missing chunk, we need to read all the remaining
// And apply the reconstruction function.
// This function is similar to the creation function
@@ -586,7 +585,7 @@ gkfs_ecc_recover(const std::string& path, void* buffer_recover,
    char** data = (char**) malloc(sizeof(char*) * data_servers);
    char** coding = (char**) malloc(sizeof(char*) * CTX->get_replicas());

    for(auto i = 0; i < data_servers; ++i) {
    for(unsigned int i = 0; i < data_servers; ++i) {
        data[i] = (char*) malloc(gkfs::config::rpc::chunksize);
    }
    for(auto i = 0; i < CTX->get_replicas(); ++i) {
@@ -625,8 +624,8 @@ gkfs_ecc_recover(const std::string& path, void* buffer_recover,
        for(auto k = 0; k < gkfs::config::rpc::chunksize; k++) {
            md5 += data[failed_server][k];
        }
        std::cout << "Content of the failed server? " << failed_server << " --> "
                  << md5 << std::endl;
        std::cout << "Content of the failed server? " << failed_server
                  << " --> " << md5 << std::endl;
    }

    // memset(data[failed_server], 3, gkfs::config::rpc::chunksize);
@@ -671,8 +670,8 @@ gkfs_ecc_recover(const std::string& path, void* buffer_recover,
        for(auto k = 0; k < gkfs::config::rpc::chunksize; k++) {
            md5 += data[failed_server][k];
        }
        std::cout << "Content of the recovered server? " << failed_server << " --> "
                  << md5 << std::endl;
        std::cout << "Content of the recovered server? " << failed_server
                  << " --> " << md5 << std::endl;
    }

    memcpy(buffer_recover, data[failed_server], gkfs::config::rpc::chunksize);
@@ -687,8 +686,8 @@ gkfs_ecc_recover(const std::string& path, void* buffer_recover,
    LOG(DEBUG, "EC computation finished");

    return true;
} // namespace gkfs::rpc

}
#endif

/**
 * Send an RPC request to read to a buffer.
+12 −0
Original line number Diff line number Diff line
######## Installing:  lz4 ###############################
######## Installing:  capstone ###############################
######## Installing:  json-c ###############################
######## Installing:  libfabric ###############################
######## Installing:  mercury ###############################
######## Installing:  argobots ###############################
######## Installing:  margo ###############################
######## Installing:  rocksdb ###############################
######## Installing:  syscall_intercept ###############################
######## Installing:  date ###############################
######## Installing:  agios ###############################
+17 −0
Original line number Diff line number Diff line
######## Installing:  lz4 ###############################
######## Installing:  capstone ###############################
######## Installing:  json-c ###############################
######## Installing:  psm2 ###############################
WARNING: Install script for 'psm2' not found. Skipping.
######## Installing:  libfabric ###############################
######## Installing:  mercury ###############################
######## Installing:  argobots ###############################
######## Installing:  margo ###############################
######## Installing:  rocksdb ###############################
######## Installing:  syscall_intercept ###############################
######## Installing:  date ###############################
######## Installing:  agios ###############################
######## Installing:  parallax ###############################
######## Installing:  gf-complete ###############################
######## Installing:  Jerasure ###############################
Done
 No newline at end of file
+9 −0
Original line number Diff line number Diff line
######## Installing:  libfabric ###############################
######## Installing:  mercury ###############################
######## Installing:  argobots ###############################
######## Installing:  margo ###############################
######## Installing:  rocksdb ###############################
######## Installing:  syscall_intercept ###############################
######## Installing:  date ###############################
######## Installing:  agios ###############################
######## Installing:  parallax ###############################
Loading