DEV Community

dbao
dbao

Posted on

openEuler release 22.03挂载本地iso光盘镜像,配置yum软件仓库

1.首先上传openEuler-22.03-LTS-SP4-aarch64-dvd.iso镜像到任意目录,此处上传到/root 下
2.创建挂载点并挂载iso镜像

mkdir /mnt/yum
mount -o loop /root/openEuler-22.03-LTS-SP4-aarch64-dvd.iso /mnt/yum/
Enter fullscreen mode Exit fullscreen mode

查看是否挂载成功

df -Th
Enter fullscreen mode Exit fullscreen mode

3.配置yum软件仓库
首先将原有的仓库备份

cd /etc/yum.repos.d
mkdir bak
mv openEuler.repo bak/
Enter fullscreen mode Exit fullscreen mode

新建openEuler.repo仓库

cd /etc/yum.repos.d
vi openEuler.repo
Enter fullscreen mode Exit fullscreen mode

编辑内容如下:

[os]
name=os
baseurl=file:///mnt/yum/
enabled=1
gpgcheck=0
Enter fullscreen mode Exit fullscreen mode

4.验证是否配置成功

yum list
Enter fullscreen mode Exit fullscreen mode

Top comments (0)