Monday, September 7, 2009

Package(RPM) Management

RPM:
- Is a tool for the management of source files, packages, build process
- Includes a distribution method and formart for binery files, including pre and postinstall scrpits

Database of the installed packages - /var/lib/rpm
To access the database, use the rpm command

To install a package:
# rpm -ivh package-name.rpm

To upgrade a package:
# rpm -Uvh package-name.rpm

To erase/uninstall a package:
# rpm -evh package-name.rpm

To freshen a package: [ Only installs if the old version was installed ]
# rpm -F package-name.rpm

Query a package:
# rpm -q package-name

To list all the installed packages:
# rpm -qa

To show the package owning a specific file:
# rpm -qf /usr/bin/ls


To list the files owned by a package:
# rpm -ql package-name.rpm

To display package information:
# rpm -qi package-name.rpm

To verifiy a package:
# rpm -V package-name

To verify the package signature:
# rpm --checksig package-name.rpm

To import a public key for a package:
# rpm --import path-to-public-key-file

Integrated package Management:
RdHat: redhat-config-packages
SuSE: yast

Red Hat Online Update:
- Create and manage account and systems thru http://rhn.redhat.com
- Register individual systems with
# up2date --register
- User 'up2date' command to update the systems

SuSE Online Update:
- Command:
'you' or
'yast' -> Online Update
- It downloads and installs the patches freom any SuSE mirror server
- You can create internal mirrors in your network

No comments: