Compare commits
10 Commits
pkgs/tacud
...
1d3bda33a0
| Author | SHA1 | Date | |
|---|---|---|---|
|
1d3bda33a0
|
|||
|
87bf095dae
|
|||
|
2264e15102
|
|||
|
209f8a582e
|
|||
|
1457d85f4c
|
|||
|
ad812ea32d
|
|||
|
5bc928c407
|
|||
|
eb9358abab
|
|||
|
d2025d35d9
|
|||
|
6e089344da
|
6
flake.lock
generated
6
flake.lock
generated
@@ -2,11 +2,11 @@
|
|||||||
"nodes": {
|
"nodes": {
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1767634882,
|
"lastModified": 1764522689,
|
||||||
"narHash": "sha256-2GffSfQxe3sedHzK+sTKlYo/NTIAGzbFCIsNMUPAAnk=",
|
"narHash": "sha256-SqUuBFjhl/kpDiVaKLQBoD8TLD+/cTUzzgVFoaHrkqY=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "3c9db02515ef1d9b6b709fc60ba9a540957f661c",
|
"rev": "8bb5646e0bed5dbd3ab08c7a7cc15b75ab4e1d0f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -57,18 +57,6 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.fail2ban = {
|
|
||||||
enable = true;
|
|
||||||
maxretry = 5;
|
|
||||||
bantime-increment = {
|
|
||||||
enable = true; # Double ban time on each attack
|
|
||||||
maxtime = "7d"; # Ban up to a week
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Disable SSH login with password, allow only keypair
|
|
||||||
services.openssh.settings.PasswordAuthentication = false;
|
|
||||||
|
|
||||||
networking.firewall = {
|
networking.firewall = {
|
||||||
extraCommands = ''
|
extraCommands = ''
|
||||||
# Blackhole BSC vulnerability scanner (OpenVAS) as it is spamming our
|
# Blackhole BSC vulnerability scanner (OpenVAS) as it is spamming our
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
address = "10.0.40.40";
|
address = "10.0.40.40";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
interfaces.ibs785.ipv4.addresses = [ {
|
interfaces.ibp5s0.ipv4.addresses = [ {
|
||||||
address = "10.0.42.40";
|
address = "10.0.42.40";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
|
|||||||
@@ -139,7 +139,6 @@
|
|||||||
openssh.authorizedKeys.keys = [
|
openssh.authorizedKeys.keys = [
|
||||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKGt0ESYxekBiHJQowmKpfdouw0hVm3N7tUMtAaeLejK vincent@varch"
|
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKGt0ESYxekBiHJQowmKpfdouw0hVm3N7tUMtAaeLejK vincent@varch"
|
||||||
];
|
];
|
||||||
shell = pkgs.zsh;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
pmartin1 = {
|
pmartin1 = {
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
{ pkgs, lib, ... }:
|
{ config, pkgs, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
|
# add the perf tool
|
||||||
|
environment.systemPackages = with pkgs; [
|
||||||
|
config.boot.kernelPackages.perf
|
||||||
|
];
|
||||||
|
|
||||||
# allow non-root users to read tracing data from the kernel
|
# allow non-root users to read tracing data from the kernel
|
||||||
boot.kernel.sysctl."kernel.perf_event_paranoid" = -2;
|
boot.kernel.sysctl."kernel.perf_event_paranoid" = -2;
|
||||||
boot.kernel.sysctl."kernel.kptr_restrict" = 0;
|
boot.kernel.sysctl."kernel.kptr_restrict" = 0;
|
||||||
|
|||||||
@@ -45,7 +45,7 @@
|
|||||||
address = "10.0.40.7";
|
address = "10.0.40.7";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
interfaces.ibs785.ipv4.addresses = [ {
|
interfaces.ibp5s0.ipv4.addresses = [ {
|
||||||
address = "10.0.42.7";
|
address = "10.0.42.7";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
|
|||||||
@@ -46,7 +46,7 @@
|
|||||||
address = "10.0.40.42";
|
address = "10.0.40.42";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
interfaces.ibs785.ipv4.addresses = [ {
|
interfaces.ibp5s0.ipv4.addresses = [ {
|
||||||
address = "10.0.42.42";
|
address = "10.0.42.42";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
address = "10.0.40.1";
|
address = "10.0.40.1";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
interfaces.ibs785.ipv4.addresses = [ {
|
interfaces.ibp5s0.ipv4.addresses = [ {
|
||||||
address = "10.0.42.1";
|
address = "10.0.42.1";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
|
|||||||
@@ -21,7 +21,7 @@
|
|||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
# Watch out! The OmniPath device is not in the same place here:
|
# Watch out! The OmniPath device is not in the same place here:
|
||||||
interfaces.ibs801.ipv4.addresses = [ {
|
interfaces.ibp129s0.ipv4.addresses = [ {
|
||||||
address = "10.0.42.2";
|
address = "10.0.42.2";
|
||||||
prefixLength = 24;
|
prefixLength = 24;
|
||||||
} ];
|
} ];
|
||||||
|
|||||||
@@ -27,7 +27,4 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
# Allow gitea user to send mail
|
|
||||||
users.users.gitea.extraGroups = [ "mail-robot" ];
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -62,14 +62,7 @@ let
|
|||||||
tagaspi = callPackage ./pkgs/tagaspi/default.nix { };
|
tagaspi = callPackage ./pkgs/tagaspi/default.nix { };
|
||||||
tampi = callPackage ./pkgs/tampi/default.nix { };
|
tampi = callPackage ./pkgs/tampi/default.nix { };
|
||||||
upc-qaire-exporter = prev.callPackage ./pkgs/upc-qaire-exporter/default.nix { };
|
upc-qaire-exporter = prev.callPackage ./pkgs/upc-qaire-exporter/default.nix { };
|
||||||
taopencl = callPackage ./pkgs/taopencl/default.nix { };
|
|
||||||
wxparaver = callPackage ./pkgs/paraver/default.nix { };
|
wxparaver = callPackage ./pkgs/paraver/default.nix { };
|
||||||
|
|
||||||
_cuda = prev._cuda.extend (_: _prev: final.lib.recursiveUpdate _prev {
|
|
||||||
extensions = _prev.extensions ++ [(finalAttrs: _: {
|
|
||||||
tacuda = finalAttrs.callPackage ./pkgs/tacuda/default.nix { };
|
|
||||||
})];
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
tests = rec {
|
tests = rec {
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ in stdenv.mkDerivation {
|
|||||||
'';
|
'';
|
||||||
hardeningDisable = [ "pic" "format" ];
|
hardeningDisable = [ "pic" "format" ];
|
||||||
nativeBuildInputs = kernel.moduleBuildDependencies;
|
nativeBuildInputs = kernel.moduleBuildDependencies;
|
||||||
patches = [ ./makefile.patch ./hrtimer.patch ./remove-wr-rdmsrq.patch ];
|
patches = [ ./makefile.patch ./hrtimer.patch ];
|
||||||
makeFlags = [
|
makeFlags = [
|
||||||
"KERNEL_VERSION=${kernel.modDirVersion}"
|
"KERNEL_VERSION=${kernel.modDirVersion}"
|
||||||
"KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
"KERNEL_DIR=${kernel.dev}/lib/modules/${kernel.modDirVersion}/build"
|
||||||
|
|||||||
@@ -1,20 +0,0 @@
|
|||||||
diff --git a/inc/PwrProfAsm.h b/inc/PwrProfAsm.h
|
|
||||||
index d77770a..c93a0e9 100644
|
|
||||||
--- a/inc/PwrProfAsm.h
|
|
||||||
+++ b/inc/PwrProfAsm.h
|
|
||||||
@@ -347,6 +347,7 @@
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
+/*
|
|
||||||
#define rdmsrq(msr,val1,val2,val3,val4) ({ \
|
|
||||||
__asm__ __volatile__( \
|
|
||||||
"rdmsr\n" \
|
|
||||||
@@ -362,6 +363,7 @@
|
|
||||||
:"c"(msr), "a"(val1), "d"(val2), "S"(val3), "D"(val4) \
|
|
||||||
); \
|
|
||||||
})
|
|
||||||
+*/
|
|
||||||
|
|
||||||
#define rdmsrpw(msr,val1,val2,val3,val4) ({ \
|
|
||||||
__asm__ __volatile__( \
|
|
||||||
@@ -1,72 +0,0 @@
|
|||||||
{
|
|
||||||
backendStdenv,
|
|
||||||
fetchFromGitHub,
|
|
||||||
automake,
|
|
||||||
autoconf,
|
|
||||||
libtool,
|
|
||||||
gnumake,
|
|
||||||
autoreconfHook,
|
|
||||||
boost,
|
|
||||||
cudatoolkit,
|
|
||||||
libcublas,
|
|
||||||
cuda_cudart,
|
|
||||||
|
|
||||||
useGit ? false,
|
|
||||||
gitUrl ? "git@gitlab-internal.bsc.es:task-awareness/tacuda/tacuda.git",
|
|
||||||
gitBranch ? "main",
|
|
||||||
gitCommit ? "35234f9445e6149a2bd38d119841e2485d6ee05e",
|
|
||||||
}:
|
|
||||||
|
|
||||||
let
|
|
||||||
|
|
||||||
release_ver = "2.1.0";
|
|
||||||
release = {
|
|
||||||
version = release_ver;
|
|
||||||
src = fetchFromGitHub {
|
|
||||||
owner = "bsc-pm";
|
|
||||||
repo = "tacuda";
|
|
||||||
rev = release_ver;
|
|
||||||
hash = "sha256-Cj3EiLVJSLvRv0ydeg7Vp4SpkniEqHkcWF+YOJQ8EcM=";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
git = rec {
|
|
||||||
version = src.shortRev;
|
|
||||||
src = builtins.fetchGit {
|
|
||||||
url = gitUrl;
|
|
||||||
ref = gitBranch;
|
|
||||||
rev = gitCommit;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
source = if (useGit) then git else release;
|
|
||||||
|
|
||||||
in
|
|
||||||
|
|
||||||
backendStdenv.mkDerivation {
|
|
||||||
pname = "tacuda";
|
|
||||||
inherit (source) src version;
|
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
separateDebugInfo = true;
|
|
||||||
strictDeps = true;
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
autoreconfHook
|
|
||||||
automake
|
|
||||||
autoconf
|
|
||||||
libtool
|
|
||||||
gnumake
|
|
||||||
];
|
|
||||||
|
|
||||||
patches = [ ./fix_config.patch ];
|
|
||||||
|
|
||||||
configureFlags = [ "--with-cuda-include=${cudatoolkit}/include" ];
|
|
||||||
|
|
||||||
buildInputs = [
|
|
||||||
boost
|
|
||||||
libcublas
|
|
||||||
cuda_cudart
|
|
||||||
];
|
|
||||||
|
|
||||||
}
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
diff --git a/m4/cuda.m4 b/m4/cuda.m4
|
|
||||||
index 23f5c94..8f9b534 100644
|
|
||||||
--- a/m4/cuda.m4
|
|
||||||
+++ b/m4/cuda.m4
|
|
||||||
@@ -40,7 +40,7 @@ search_libs="cuda cublas cudart"
|
|
||||||
required_libs=""
|
|
||||||
|
|
||||||
m4_foreach([function],
|
|
||||||
- [cuInit,
|
|
||||||
+ [
|
|
||||||
cublasSgemm,
|
|
||||||
cudaStreamCreate,
|
|
||||||
cudaLaunchKernel,
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
{
|
|
||||||
stdenv,
|
|
||||||
automake,
|
|
||||||
autoconf,
|
|
||||||
libtool,
|
|
||||||
gnumake,
|
|
||||||
boost,
|
|
||||||
mpi,
|
|
||||||
autoreconfHook,
|
|
||||||
ocl-icd,
|
|
||||||
opencl-headers,
|
|
||||||
}:
|
|
||||||
|
|
||||||
stdenv.mkDerivation (finalAttrs: {
|
|
||||||
pname = "taopencl";
|
|
||||||
version = finalAttrs.src.shortRev;
|
|
||||||
|
|
||||||
src = builtins.fetchGit {
|
|
||||||
url = "git@gitlab-internal.bsc.es:task-awareness/taopencl/taopencl.git";
|
|
||||||
ref = "master";
|
|
||||||
rev = "c3b7b32ae8fa4af7ceff598532a881f8f1490aaf";
|
|
||||||
};
|
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
separateDebugInfo = true;
|
|
||||||
strictDeps = true;
|
|
||||||
|
|
||||||
configureFlags = [
|
|
||||||
"--with-opencl-lib=${ocl-icd}/lib"
|
|
||||||
"--with-opencl-include=${opencl-headers}/include"
|
|
||||||
];
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
autoreconfHook
|
|
||||||
automake
|
|
||||||
autoconf
|
|
||||||
libtool
|
|
||||||
gnumake
|
|
||||||
];
|
|
||||||
|
|
||||||
buildInputs = [
|
|
||||||
boost
|
|
||||||
mpi
|
|
||||||
];
|
|
||||||
|
|
||||||
dontDisableStatic = true;
|
|
||||||
hardeningDisable = [ "all" ];
|
|
||||||
})
|
|
||||||
Reference in New Issue
Block a user