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 | |
# Check if the script is run with superuser privileges | |
if [ "$EUID" -ne 0 ]; then | |
echo "Please run this script as root (sudo)." | |
exit 1 | |
fi | |
# Prompt the user for the target devices | |
read -p "Enter the target devices (e.g., /dev/sdX /dev/sdY): " target_devices |