Solution: The ifconfig command is not available after CentOS7 is installed in mini version

Source: Internet
Author: User

Solution: The ifconfig command is not available after CentOS7 is installed in mini version

  • Configure yum source (local)
    1. Mount the system installation discmount /dev/cdrom /mnt/cdrom/
    2. Run the following command in linux:cd /etc/yum.repos.d/, And thenlsThe following files are displayed in the yum. repos. d file:CentOS-Base.repo CentOS-CR.repo CentOS-Debuginfo.repo
      CentOS-fasttrack.repo CentOS-Media.repo CentOS-Sources.repo CentOS-Vault.repoA total of 7 files.
    3. OpenCentOS-Media.repoFile, command:vi CentOS-Media.repo
    4. SetCentOS-Media.repoFile changed:
# CentOS-Media.repo # This repo can be used with mounted DVD media, verify the mount point for # CentOS-7. you can use this repo and yum to install items directly off the # dvd iso that we release. # To use this repo, put in your DVD and use it with the other repos too: # yum -- enablerepo = c7-media [command] # or for ONLY the media repo, do this: # yum -- disablerepo = \ * -- enablerepo = c7-media [command] [c7-media] # library name = CentOS-$ releasever-Media # library name Description baseurl = file: /// mnt/cdrom # yum source directory, source address gpgcheck = 1 # Check the GPG-KEY, 0, 1 are not checked, check enabled = 1 # whether to use the source gpgkey = file: // etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18

Then:wqSave and exit. Remember to delete the other six files, but it is best to keep them for future use. My solution is to change the suffix of the other six files.bakThe change is as follows:CentOS-Base.bak CentOS-CR.bak CentOS-Debuginfo.bak CentOS-fasttrack.bak CentOS-Media.repo CentOS-Sources.bak CentOS-Vault.bak5.Baseurl = file: // mnt/cdrom # this is very important. This is a specified path. You can use file, ftp, or http to use the next two services. File can be used as a local repository. Make sure the path is reachable)6.Gpgkey = file: // etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7 # After the gpgcheck is enabled, the gpgkey is used to specify the corresponding gpg file. If the gpgkey file is not specified, you must manually import the corresponding gpg file.7. Run the following command:yum install net-toolsBecause ifconfig is in net-tools, you need to install this package. 8. Okay. Now the solution is complete !! See

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.