当前位置:网站首页>The script implements the automated deployment of raid0
The script implements the automated deployment of raid0
2022-06-24 19:00:00 【51CTO】
#!/bin/bash
# Use EOF Realize automatic configuration raid0
#reid( Strip ) >=2 Improve reading and writing speed , disk IO performance No fault tolerance Disk utilization %100
read -p " Please enter the path of the disk you want to make " path
if [ -b $path ]
then
echo " The device is a block device , Already exists "
echo " Start automated partitioning "
fdisk $path <<EOF
n
p
+1G
n
p
+1G
p
t
1
fd
t
2
fd
p
w
EOF
sleep 3
mdadm -C -a yes /dev/md0 -l 0 -n 2 ${path}[12]
echo " see raid0 situation "
mdadm -D /dev/md0
echo " format partition "
mkfs.ext4 /dev/md0
read -p " Please enter the created mount point " bb
if [ -e $bb ]
then
echo " Mount point already exists "
else
echo " Create mount point "
mkdir $bb
fi
echo " Mount device "
mount /dev/md0 $bb
echo " see "
df -h
else
echo " Device does not exist , Please check and re-enter "
fi
边栏推荐
- Using alicloud RDS for SQL Server Performance insight to optimize database load - first understanding of performance insight
- FROM_ GLC introduction and data download tutorial
- cdc+mysql connector从维表中join的日期时间字段会被+8:00,请问阿里云托管的
- Sentry series satellite introduction and download tutorial
- 小白请教下各位大佬,cdc抽取mysql binlog是严格顺序的吗
- Introduction, download and use of global meteorological data CRU ts from 1901 to 2020
- Introduction and download tutorial of two types of soil data
- Interprétation de la thèse (SR - gnn) Shift Robust GNNS: Overcoming the Limits of Localized Graph Training Data
- Bisection function template
- JS deep understanding of functions
猜你喜欢

FROM_ GLC introduction and data download tutorial

Do you have all the basic embedded knowledge points that novices often ignore?

为什么 Nodejs 这么快?

AI时代生物隐私如何保护?马德里自治大学最新《生物特征识别中的隐私增强技术》综述,全面详述生物隐私增强技术

Microservice system design -- data model and system architecture design

多云模式并非“万能钥匙”

Road vector data download tutorial

Volcano becomes spark default batch scheduler

Introduction to alos satellite

Why is nodejs so fast?
随机推荐
想问下 pgsql cdc 账号同一个 多个 task 会有影响吗,我现在3个task 只有一个 有
Microservice system design - sub service project construction
Microservice system design -- data model and system architecture design
C self learning function
Microservice system design -- interface document management design
ls 常用参数
Bisection function template
多云模式并非“万能钥匙”
Solve the problem that the MapReduce program console does not have log information warn please initialize the log4j system properly
我链接mysql 报这个错 是啥意思呀?
Differences between get and post request modes
Set up your own website (8)
flink-sql的kafka的这个设置,group-offsets,如果指定的groupid没有提
History object
Introduction and download tutorial of administrative division vector data
电源效率测试
Sudoku (easy to understand)
Fabric 账本数据块结构解析(一):如何解析账本中的智能合约交易数据
模块五
LabView之MQTT协议使用