1. Install nginx
2. Install minio
3. Install mc client
$ mc mb myminio/static
Bucket created successfully ‘myminio/static’.
package main | |
import ( | |
"fmt" | |
"math" | |
"time" | |
) | |
// humanizeDuration humanizes time.Duration output to a meaningful value, | |
// golang's default ``time.Duration`` output is badly formatted and unreadable. |
version: '3.7' | |
# Settings and configurations that are common for all containers | |
x-minio-common: &minio-common | |
image: quay.io/minio/minio:${RELEASE} | |
command: server http://site1-minio{1...4}/data{1...2} | |
environment: | |
- MINIO_PROMETHEUS_AUTH_TYPE=public | |
- CI=true |
/* | |
* ---------------------------------------------------------------------------- | |
* "THE BEER-WARE LICENSE" (Revision 42): | |
* <dweymouth@gmail.com> wrote this file. As long as you retain this notice you | |
* can do whatever you want with this stuff. If we meet some day, and you think | |
* this stuff is worth it, you can buy me a beer in return. D. Weymouth 4/2014 | |
* ---------------------------------------------------------------------------- | |
*/ | |
import java.io.*; |
version: '2' | |
services: | |
minio: | |
image: minio/minio | |
container_name: miniobkp | |
ports: | |
- 9000:9000 | |
env_file: | |
- ./minio.env |
# Based on a modified script from here: http://tmont.com/blargh/2014/1/uploading-to-s3-in-bash | |
S3KEY="YOUR-ACCESSKEY" | |
S3SECRET="YOUR-SECRETKEY" | |
function putS3 | |
{ | |
path=$1 | |
file=$2 | |
aws_path=$3 |
""" | |
FTP benchmark. | |
Usage: | |
ftpbench --help | |
ftpbench -h <host> -u <user> -p <password> [options] login | |
ftpbench -h <host> -u <user> -p <password> [options] upload <workdir> [-s <size>] | |
ftpbench -h <host> -u <user> -p <password> [options] download <workdir> [-s <size>] [--files <count>] | |
Connection options: |
DATA AND METADATA COHERENCE | |
Some modern cluster file systems provide perfect cache coherence among their clients. Perfect cache coherence among disparate NFS clients is expensive to achieve, especially on wide area networks. As such, NFS settles for weaker cache coherence that satisfies the requirements of most file sharing types. | |
Close-to-open cache consistency | |
Typically file sharing is completely sequential. First client A opens a file, writes something to it, then closes it. Then client B opens the same file, and reads the changes. | |
When an application opens a file stored on an NFS version 3 server, the NFS client checks that the file exists on the server and is permitted to the opener by sending a GETATTR or ACCESS request. The NFS client sends these requests regardless of the freshness of the file's cached attributes. | |
When the application closes the file, the NFS client writes back any pending changes to the file so that the next opener can view the changes. This al |
#!/bin/bash \ | |
i=1 | |
sudo rm -f /tmp/fstab | |
for disk in $(lsblk -i -p -n -o NAME | grep -v 'loop\|nvme0\|nvme1\|nvme2\|nvme3\|ubuntu\|md\|sda' | sort); do | |
sudo mkdir -p /disk${i} | |
sudo mkfs.xfs -f -L disk${i} $disk | |
echo "LABEL=disk${i} /disk${i} xfs defaults,noatime 0 0" | sudo tee -a /tmp/fstab | |
i=$(( $i + 1 )) |