1:创建目录
mkdir /usr/local/minio
mkdir /usr/local/minio/logs
mkdir /usr/local/minio/conf
mkdir /usr/local/minio/data
2:下载minio
wget https://dl.minio.org.cn/server/minio/release/linux-amd64/minio
3:授权
chmod +x minio
4:后台进程启动
MINIO_ROOT_USER=admin MINIO_ROOT_PASSWORD=password ./minio server /usr/local/minio/data --console-address ":9001"
5:设置minio登录参数及安装目录参数
创建minio.conf文件
vim /usr/local/minio/data/minio.conf
MINIO_ROOT_USER="admin"
MINIO_ROOT_PASSWORD="password"
MINIO_VOLUMES="/usr/local/minio/data"
MINIO_OPTS="--console-address :9001"
6:开机自启动
创建 vim /etc/systemd/system/minio.service文件
[Unit]
Description=Minio Service
[Service]
Environment="MINIO_ROOT_USER=admin"
Environment="MINIO_ROOT_PASSWORD=minio123456"
ExecStart=/usr/local/minio/minio server /usr/local/data --console-address ":9001"
ExecReload=/bin/kill -s HUP $MAINPID
ExecStop=/bin/kill -s QUIT $MAINPID
StandardOutput=/usr/local/minio/logs/minio.log
PrivateTmp=true
[Install]
WantedBy=multi-user.target
MINIO_ROOT_USER:登录用户名
MINIO_ROOT_PASSWORD 密码
ExecStart:minio的安装路径和控制台启动。默认启动端口9000 控制台登录端口可自行设置:演示为:9001
StandardOutput:minio日志
7:加载服务文件
systemctl daemon-reload
8:设置开机自启动
systemctl enable minio.service
9:启动minio
systemctl start minio.service
10:查看状态
systemctl status minio.service
11:测试重新启动linux
reboot
12:安装命令客户端mc
wget https://dl.min.io/client/mc/release/linux-amd64/mc
13:授权
chmod +x mc
14:启动mc
./mc --help
15:将mc移动到/usr/local/sbin中
mv mc /usr/local/sbin
版权归原作者 聻956 所有, 如有侵权,请联系我们删除。