Logo
  • Home
  • About
  • Services
  • Blogs
  • Career
  • Contact
Logo

The UK's #1 Software Development Company. PodTech IO builds custom software solutions for businesses. Call today for a free consultation

  • Address

    4th Floor, 4 Tabernacle Street London EC2A 4LU
  • Email

    info@podtech.com
  • Contact

    +44 (0) 20 8720 6583

RedHat vs Ubuntu – Useful Package Commands

  • Home
  • RedHat vs Ubuntu – Useful Package Commands
  • By podtech
  • In UNIX

RedHat vs Ubuntu – Useful Package Commands

Task Red Hat/Fedora Ubuntu
Refresh list of available packages Yum refreshes each time it’s used apt-get update
Install a package from a repository yum install package_name apt-get install package_name
Install a package file yum install package.rpm
rpm -i package.rpm
dpkg –install package.deb
Remove a package rpm -e package_name apt-get remove package_name
Check for package upgrades yum check-update apt-get -s upgrade
apt-get -s dist-upgrade
Upgrade packages yum update
rpm -Uvh [args]
apt-get dist-upgrade
Upgrade the entire system yum upgrade apt-get dist-upgrade
Get information about an available package yum search package_name apt-cache show package_name
Show available packages yum list available apt-cache dumpavail
List all installed packages yum list installed
rpm -qa
dpkg –list
Get information about an installed package yum info package_name
rpm -qi package_name
dpkg –status package_name
List files in an installed package rpm -ql package_name dpkg –listfiles package_name
List documentation files in an installed package rpm -qd package_name –
List configuration files in an installed package rpm -qc package_name –
Show the packages a given package depends on rpm -qR package_name apt-cache depends package_name
Show other packages that depend on a
given package (reverse dependency)
rpm -q -whatrequires [args] apt-cache rdepends package_name
Find packages with substring in name yum list “*substring*” –
Get information about a package file rpm -qpi package.rpm dpkg –info package.deb
List files in a package file rpm -qpl package.rpm dpkg –contents package.deb
List documentation files in a package file rpm -qpd package.rpm –
List configuration files in a package file rpm -qpc package.rpm –
Extract files in a package cpio -vid dpkg-deb –extract package.deb dir-to-extract-to
Find package that installed a file rpm -qf filename dpkg –search filename
Find package that provides a particular file yum provides filename apt-file search filename
Show stats about the package cache – apt-cache stats
Verify all installed packages rpm -Va debsums
Remove packages from the local cache directory yum clean packages apt-get clean
Remove only obsolete packages from the local cache directory – apt-get autoclean
Remove header files from the local cache directory
(forcing a new download of same on next use)
yum clean headers apt-file purge
Repository location configuration /etc/yum.conf /etc/apt/sources.list
Starting/stopping services immediately service httpd start /etc/init.d/apache start
service apache start
Enabling a service at boot chkconfig httpd on update-rc.d apache defaults
sysv-rc-conf apache on
Disabling a service at boot chkconfig httpd off update-rc.d apache purge
sysv-rc-conf apache off
commandsRedHatRedHat vs UbuntuubuntuUseful Package Commands
Given a size in KB, try to return a more readable MB, GB or TB answer string
Recursively Expand a NIS Netgroup

Recent Posts

  • DevOps as a Software Development Methodology
  • How Does Spiral Software Development Methodology Work?
  • Waterfall Software Development Methodology And When To Use It
  • What Exactly Is Lean Software Development Methodology?
  • What is Kanban and How Does It Work?

PodTech IO

The UK's #1 Software Development Company. PodTech IO builds custom software solutions for businesses. Call today for a free consultation

Company

  • About
  • Services
  • Contact
  • Blogs
  • Career

Terms

  • Terms & Conditions
  • Privacy Policy

Contact Us

  • ADDRESS

    Headquarter: Tabernacle Street London India: Vi john Tower, Gurgaon, Haryana
  • EMAIL

    info@podtech.com
  • CONTACT

    +44 (0) 20 8720 6583

Copyright ©2023 PodTech IO. All Rights Reserved

Logo