This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if ! command -v ioping &> /dev/null; then | |
echo "Error: ioping is not installed." | |
exit 1 | |
fi | |
root_disk=$(df / | grep '/' | awk '{print $1}' | sed 's/[0-9]*//g') | |
disks=$(ls /dev/sd* | grep -E "/dev/sd[a-z]$" | grep -v "$root_disk") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
spinner() { | |
local pid=$1 | |
local delay=0.1 | |
local spinstr="⠋⠙⠹⠸⠼⠴⠦⠧⠇⠏" | |
local i=0 | |
local len=${#spinstr} | |
while [ "$(ps a | awk '{print $1}' | grep $pid)" ]; do | |
i=$(( (i+1) % len )) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
display_help() { | |
echo "Usage: $0 [option]" | |
echo | |
echo "This script retrieves and displays information about the system's CPU, motherboard, and memory through DMI Decode." | |
echo | |
echo "Options:" | |
echo " --help Display this help message and exit." | |
echo |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo .DS_Store >> ~/.gitignore_global | |
git config --global core.excludesfile ~/.gitignore_global |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
openssl speed rsa4096 2>/dev/null | grep 'rsa 4096 bits' | awk '{print "1T : "$6" s/s | "$7" v/s"}' && openssl speed --multi $(nproc) rsa4096 2>/dev/null | grep 'rsa 4096 bits' | awk '{print "nT : "$6" s/s | "$7" v/s"}' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
IO_ENGINE=$1 | |
TESTS=$2 | |
TARGET=$3 | |
SIZE=$4 | |
launch () { | |
sudo fio --name=test --group_reporting --ioengine=$1 --disable_clat=1 --disable_slat=1 --percentile_list=0 --norandommap=1 --randrepeat=0 --direct=1 --rw=$2 --bs=$3 --size=$4 --iodepth=$5 --numjobs=$6 --filename=$7 | grep avg= | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
REQUEST=5000000 | |
SIZE=3 | |
if [ $1 == "--help" ] | |
then | |
echo "Usage : ./rb.sh [requests] [block]" | |
echo | |
echo " requests : how many to use during performance testing (default : 5000000) " |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# On affiche les informations sur les modules NVMe | |
clear | |
echo | |
echo "Module NVME_TARGET de votre noyau :" | |
echo "===================================" | |
echo | |
cat /boot/config-`uname -r` | grep NVME_TARGET |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
apt update && apt full-upgrade -y && apt autoremove -y | |
wget https://dl.min.io/server/minio/release/linux-amd64/minio | |
chmod +x minio | |
mv minio /usr/local/bin | |
useradd -r minio -s /sbin/nologin | |
chown minio:minio /usr/local/bin/minio |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# Script to install multiple applications in one command line through WinGet | |
You can modify bootstrapArray value and use "--bootstrap" argument to bootstrap a new machine | |
Don't forget to change ExecutionPolicy to execute this script | |
Set-ExecutionPolicy -ExecutionPolicy AllSigned -Scope CurrentUser #> | |
$bootstrapArray = @("vlc", "7zip", "cpu-z", "coretemp") | |
if ((New-Object Security.Principal.WindowsPrincipal([Security.Principal.WindowsIdentity]::GetCurrent())).IsInRole([Security.Principal.WindowsBuiltInRole]::Administrator)) | |
{ | |
if ($args[0] -ne "--bootstrap") { $bootstrapArray = $args } |