2022-08-31 16:27:53 +00:00
|
|
|
name: "End to End"
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [ master ]
|
|
|
|
pull_request:
|
|
|
|
branches: [ master ]
|
|
|
|
|
|
|
|
concurrency:
|
|
|
|
group: ${{ github.head_ref }}/e2e
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
|
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
working-directory: docker
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
e2e:
|
|
|
|
name: FUSE Mount
|
|
|
|
runs-on: ubuntu-22.04
|
2023-09-22 23:44:45 +00:00
|
|
|
timeout-minutes: 30
|
2022-08-31 16:27:53 +00:00
|
|
|
steps:
|
|
|
|
- name: Set up Go 1.x
|
2023-08-14 15:56:29 +00:00
|
|
|
uses: actions/setup-go@93397bea11091df50f3d7e59dc26a7711a8bcfbe # v2
|
2022-08-31 16:27:53 +00:00
|
|
|
with:
|
|
|
|
go-version: ^1.13
|
|
|
|
id: go
|
|
|
|
|
|
|
|
- name: Check out code into the Go module directory
|
2023-09-25 15:18:11 +00:00
|
|
|
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v2
|
2022-08-31 16:27:53 +00:00
|
|
|
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
sudo apt-get update
|
|
|
|
sudo apt-get install -y fuse
|
|
|
|
|
|
|
|
- name: Start SeaweedFS
|
|
|
|
timeout-minutes: 5
|
|
|
|
run: make build_e2e && docker compose -f ./compose/e2e-mount.yml up --wait
|
|
|
|
|
2023-09-22 23:41:39 +00:00
|
|
|
- name: Run FIO 4k
|
2023-09-23 05:35:27 +00:00
|
|
|
timeout-minutes: 15
|
2022-08-31 16:27:53 +00:00
|
|
|
run: |
|
|
|
|
echo "Starting FIO at: $(date)"
|
|
|
|
# Concurrent r/w
|
|
|
|
echo 'Run randrw with size=16M bs=4k'
|
2023-09-23 05:53:00 +00:00
|
|
|
docker compose -f ./compose/e2e-mount.yml exec mount timeout -k5 60 fio --name=fiotest --filename=/mnt/seaweedfs/fiotest --size=16M --rw=randrw --bs=4k --direct=1 --numjobs=8 --ioengine=libaio --group_reporting --runtime=30 --time_based=1
|
2023-01-16 20:46:56 +00:00
|
|
|
|
|
|
|
echo "Verify FIO at: $(date)"
|
2022-08-31 16:27:53 +00:00
|
|
|
# Verified write
|
|
|
|
echo 'Run randwrite with size=16M bs=4k'
|
2023-09-23 05:53:00 +00:00
|
|
|
docker compose -f ./compose/e2e-mount.yml exec mount timeout -k5 60 fio --name=fiotest --filename=/mnt/seaweedfs/fiotest --size=16M --rw=randwrite --bs=4k --direct=1 --numjobs=8 --ioengine=libaio --iodepth=32 --group_reporting --runtime=30 --time_based=1 --do_verify=0 --verify=crc32c --verify_backlog=1
|
2023-01-16 20:46:56 +00:00
|
|
|
|
2023-09-22 23:41:39 +00:00
|
|
|
- name: Run FIO 128k
|
2023-01-16 20:46:56 +00:00
|
|
|
timeout-minutes: 15
|
|
|
|
run: |
|
|
|
|
echo "Starting FIO at: $(date)"
|
|
|
|
# Concurrent r/w
|
|
|
|
echo 'Run randrw with size=16M bs=128k'
|
2023-01-16 21:54:07 +00:00
|
|
|
docker compose -f ./compose/e2e-mount.yml exec mount timeout -k5 60 fio --name=fiotest --filename=/mnt/seaweedfs/fiotest --size=16M --rw=randrw --bs=128k --direct=1 --numjobs=8 --ioengine=libaio --iodepth=32 --group_reporting --runtime=30 --time_based=1
|
2023-01-16 20:46:56 +00:00
|
|
|
|
|
|
|
echo "Verify FIO at: $(date)"
|
|
|
|
# Verified write
|
2022-08-31 16:27:53 +00:00
|
|
|
echo 'Run randwrite with size=16M bs=128k'
|
2023-01-16 21:54:07 +00:00
|
|
|
docker compose -f ./compose/e2e-mount.yml exec mount timeout -k5 60 fio --name=fiotest --filename=/mnt/seaweedfs/fiotest --size=16M --rw=randwrite --bs=128k --direct=1 --numjobs=8 --ioengine=libaio --iodepth=32 --group_reporting --runtime=30 --time_based=1 --do_verify=0 --verify=crc32c --verify_backlog=1
|
2023-01-16 20:46:56 +00:00
|
|
|
|
2023-09-22 23:41:39 +00:00
|
|
|
- name: Run FIO 1MB
|
2023-01-16 20:46:56 +00:00
|
|
|
timeout-minutes: 15
|
|
|
|
run: |
|
|
|
|
echo "Starting FIO at: $(date)"
|
|
|
|
# Concurrent r/w
|
|
|
|
echo 'Run randrw with size=16M bs=1m'
|
2023-01-16 21:54:07 +00:00
|
|
|
docker compose -f ./compose/e2e-mount.yml exec mount timeout -k5 60 fio --name=fiotest --filename=/mnt/seaweedfs/fiotest --size=16M --rw=randrw --bs=1m --direct=1 --numjobs=8 --ioengine=libaio --iodepth=32 --group_reporting --runtime=30 --time_based=1
|
2022-08-31 16:27:53 +00:00
|
|
|
|
2023-01-16 20:46:56 +00:00
|
|
|
echo "Verify FIO at: $(date)"
|
|
|
|
# Verified write
|
2022-08-31 16:27:53 +00:00
|
|
|
echo 'Run randwrite with size=16M bs=1m'
|
2023-01-16 21:54:07 +00:00
|
|
|
docker compose -f ./compose/e2e-mount.yml exec mount timeout -k5 60 fio --name=fiotest --filename=/mnt/seaweedfs/fiotest --size=16M --rw=randwrite --bs=1m --direct=1 --numjobs=8 --ioengine=libaio --iodepth=32 --group_reporting --runtime=30 --time_based=1 --do_verify=0 --verify=crc32c --verify_backlog=1
|
2022-08-31 16:27:53 +00:00
|
|
|
|
|
|
|
- name: Save logs
|
|
|
|
if: always()
|
|
|
|
run: |
|
|
|
|
docker compose -f ./compose/e2e-mount.yml logs > output.log
|
|
|
|
echo 'Showing last 500 log lines of mount service:'
|
|
|
|
docker compose -f ./compose/e2e-mount.yml logs --tail 500 mount
|
|
|
|
|
|
|
|
- name: Check for data races
|
|
|
|
if: always()
|
|
|
|
continue-on-error: true # TODO: remove this comment to enable build failure on data races (after all are fixed)
|
|
|
|
run: grep -A50 'DATA RACE' output.log && exit 1 || exit 0
|
|
|
|
|
|
|
|
- name: Archive logs
|
|
|
|
if: always()
|
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
with:
|
|
|
|
name: output-logs
|
|
|
|
path: docker/output.log
|
|
|
|
|
|
|
|
- name: Cleanup
|
|
|
|
if: always()
|
|
|
|
run: docker compose -f ./compose/e2e-mount.yml down --volumes --remove-orphans --rmi all
|