Linux Source Repository Change Notes

Published 2022-12-10 19:32 160 words 1 min read

Linux and CentOS 8 yum configuration, a detailed step-by-step illustrated tutorial

centos8

yum Configuration

I only recommend using the network-based yum.

  • Network source: Alibaba yum centos8
    wget -O /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
    centos7
    wget -O /etc/yum.repo.d/CentOS-Linux-BaseOS.repo http://mirrors.aliyun.com/repo/Centos-8.repo
    etc.
  • Local yum mounting: it’s slow, not recommended.
  1. Step one:
    • Check whether the DVD drive is connected; you can use lsblk df to view it.
  2. Step two:
    • Create a mount point with mkdir /mnt/a, then mount it using mount /dev/cdrom /mnt/a
    • Use df -hT /mnt/a to view the mount record.
  3. Step three:
    • Use cd /etc/yum.repo.d/ to go to the yum configuration directory.
    • mkdir /aa
    • Back up by running mv *.repo aa
    • Copy out a yum.base.repo using cp -p . (the dot here means the current directory)
  4. Step four:
    • vim /etc/yum.Base.repo
    • Change the directory to the mount point you created.
    • Press wq to save.

Too much hassle — just use a network source instead.

If you enjoyed this, leave a comment~

... Page views
© 2021 - 2026 Vullfin @VV
Powered by theme astro-koharu · Inspired by Shoka