Jump to content

Connect Leeroopedia MCP: Equip your AI agents to search best practices, build plans, verify code, diagnose failures, and look up hyperparameter defaults.

Implementation:FMInference FlexLLMGen Mount NVMe Scripts

From Leeroopedia


Field Value
Sources FlexLLMGen
Domains Infrastructure, Storage
Last Updated 2026-02-09 00:00 GMT

Overview

External tool documentation for shell scripts that format and mount NVMe SSDs for FlexLLMGen's disk offloading tier.

Description

This is an External Tool Doc for the mount scripts provided with FlexLLMGen. Two scripts handle NVMe setup on different cloud platforms: mount_nvme_aws.sh formats a single NVMe device (/dev/nvme1n1) with ext4 and mounts it; mount_nvme_gcp.sh creates a RAID-0 array across multiple NVMe devices and mounts the array. Both mount to ~/flexllmgen_offload_dir by default.

Code Reference

  • Source: scripts/mount_nvme_aws.sh, Lines: 1-17; scripts/mount_nvme_gcp.sh, Lines: 1-22
  • Import: No Python import (shell scripts)

AWS script:

#!/bin/bash
# Mount NVMe SSD on AWS instance
sudo mkfs.ext4 /dev/nvme1n1
mkdir -p ~/flexllmgen_offload_dir
sudo mount /dev/nvme1n1 ~/flexllmgen_offload_dir
sudo chown $USER:$USER ~/flexllmgen_offload_dir

GCP script:

#!/bin/bash
# Create RAID-0 across GCP NVMe devices for maximum bandwidth
sudo mdadm --create /dev/md0 --level=0 --raid-devices=N /dev/nvme0n1 /dev/nvme0n2 ...
sudo mkfs.ext4 /dev/md0
mkdir -p ~/flexllmgen_offload_dir
sudo mount /dev/md0 ~/flexllmgen_offload_dir
sudo chown $USER:$USER ~/flexllmgen_offload_dir

I/O Contract

Direction Name Description
Input Cloud instance AWS or GCP instance with NVMe SSD(s) attached
Input Sudo access Root/sudo access required for formatting and mounting
Output Mounted directory NVMe disk formatted and mounted at ~/flexllmgen_offload_dir, owned by current user

Usage Examples

# AWS (single NVMe)
bash scripts/mount_nvme_aws.sh

# GCP (RAID-0 NVMe)
bash scripts/mount_nvme_gcp.sh

# Verify mount
df -h ~/flexllmgen_offload_dir
# Expected: NVMe device mounted with ext4

Related Pages

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment