Repository Commands: Difference between revisions

From UNIX Systems Administration
Jump to navigation Jump to search
No edit summary
Line 2: Line 2:
=== Enable Repository ===
=== Enable Repository ===
# List all Repositories
# List all Repositories
## <tt>'''# yum repolist all'''</tt>
#: <tt>'''# yum repolist all'''</tt>
# Enable Repository
# Enable Repository
#: <tt>'''# yum-config-manager --enable <repository>'''</tt>
#: <tt>'''# yum-config-manager --enable <repository>'''</tt>
Line 9: Line 9:
=== Disable Repository ===
=== Disable Repository ===
# List Enabled Repositories
# List Enabled Repositories
## <tt>'''# yum repolist'''</tt>
#: <tt>'''# yum repolist'''</tt>
# Disable Repository
# Disable Repository
#: <tt>'''# yum-config-manager --disable <repository>'''</tt>
#: <tt>'''# yum-config-manager --disable <repository>'''</tt>
Line 18: Line 18:
=== Enable Repository ===
=== Enable Repository ===
# List all Repositories
# List all Repositories
## <tt>'''# dnf repolist all'''</tt>
#: <tt>'''# dnf repolist all'''</tt>
# Enable Repository
# Enable Repository
#: <tt>'''# dnf config-manager --enable <repository>'''</tt>
#: <tt>'''# dnf config-manager --enable <repository>'''</tt>

Revision as of 10:29, 30 October 2021

CentOS 7

Enable Repository

  1. List all Repositories
    # yum repolist all
  2. Enable Repository
    # yum-config-manager --enable <repository>
  3. Verify repository is enabled
    # yum repolist

Disable Repository

  1. List Enabled Repositories
    # yum repolist
  2. Disable Repository
    # yum-config-manager --disable <repository>
  3. Verify repository is disabled
    # yum repolist

CentOS 8

Enable Repository

  1. List all Repositories
    # dnf repolist all
  2. Enable Repository
    # dnf config-manager --enable <repository>
  3. Verify repository is enabled
    # dnf repolist

Disable Repository

  1. List Enabled Repositories
    # dnf repolist
  2. Disable Repository
    # dnf config-manager --disable <repository>
  3. Verify repository is disabled
    # dnf repolist

Further Reading