This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
lx103:managing_software [2024/04/28 03:59] 114.119.130.33 old revision restored (2023/11/28 12:32) |
lx103:managing_software [2024/05/14 14:29] (current) 114.119.138.183 old revision restored (2023/10/22 22:47) |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ======Package Management====== | + | ====== RPM ====== |
- | Is controlling software (Packages) in a Linux environment. | + | |
- | ---- | + | |
- | **RPM / YUM / DNF** present on: | + | |
- | *Redhat | + | |
- | *CentOS | + | |
- | *Fedora | + | |
- | *Suse | + | |
- | + | ||
- | **apt-get / dpkg** present on: | + | |
- | *Debian | + | |
- | *Ubuntu | + | |
- | *Mint | + | |
- | + | ||
- | ===== RPM Package Management===== | + | |
Redhat Package Manager -- now recursive -- RPM Package Manager -- after being adopted by multiple distros. | Redhat Package Manager -- now recursive -- RPM Package Manager -- after being adopted by multiple distros. | ||
Package file naming conventions (NOT A REQUIREMENT): | Package file naming conventions (NOT A REQUIREMENT): | ||
- | * // | + | // |
- | * **Package Name** - name of package, like.. samba | + | |
- | * **Version Number** - (a.b.c) this is the package version number like 3.6.5 -- the programmer assigns this number. | + | |
- | * **Build Number** - number following version number (x) represents minor changes (patches, tweaks) made by package container. | + | |
- | * **Architecture** - Defines the architecture the package was made to run on. i386 is common. there are further archs like: i586, i686, x86_64, PPC, noarch(scripts) | + | |
Line 28: | Line 11: | ||
* **-U** -- Upgrade if already installed | * **-U** -- Upgrade if already installed | ||
* **-q** -- Query, get info about packages | * **-q** -- Query, get info about packages | ||
- | |||
- | |||
- | =====DEB Based Package Management===== | ||
- | apt-get / dpkg | ||
- | |||
- | ====dpkg==== | ||
- | ***'' | ||
- | ***'' | ||
- | ***'' | ||
- | ***'' | ||
- | ***'' | ||
- | ====apt==== | ||
- | Config file located in /// | ||
- | *apt-get update -- updates repo list. DOES NOT UPGRADE. | ||
- | |||
- | ===apt-cache=== | ||
- | ***search** //thing// -- searches packages on local package cache for //thing// to download from server. | ||
- | ***stats** -- shows stats based on the metadata downloaded about our repos. | ||
- | ***depends** apache2 -- shows dependencies for the apache2 package. | ||
- | ***unmet** -- shows pkgs that have unmet depends. | ||
- | |||
- | *apt-get install //apache2// - install apache2 + deps from repos. | ||
- | *apt-get upgrade -- upgrades out of date packages. | ||
- | *apt-get clean -- cleans up local pkg files, temp files, etc. | ||
- | *apt-get autoclean -- only cleans out packages that are no longer avail in our source repo. These can no longer be downloaded and are largely useless files. | ||
- | *apt-get install -s php5 -- -s says simulate install php5. useful! | ||
- | *apt-get install -y php5 -- will auto input YES on prompts. | ||
- | *apt-get install -y -q php5 -- -q omits some terminal output. | ||
- | *apt-get source php5 -- this will download the source files php5 and not the PACKAGE php5. | ||
- | * **apt-get dist-upgrade** -- RTFM, performs upgrade but also handles changing of dependencies of new versions of a package. As a result, some packages may be removed. | ||
- | |||
- | ====aptitude==== | ||
- | Ncurses/CLI based management tool. An option for those who don't like entering commandline args. | ||
- | |||
- | ====dselect==== | ||
- | ---- | ||
- | No longer maintained but still an option for package management. It's not unlike the curses interface for aptitude but you might as well just stick with the cli args like '' | ||
- | |||
- | ===== DEB ===== | ||
- | ====apt-get==== | ||
- | You can edit sources in / | ||
- | < | ||
- | deb | ||
- | deb-src http:// | ||
- | deb | ||
- | deb-src http:// | ||
- | </ | ||
- | deb entries specify debian PACKAGES where as deb-src specifies SOURCE PACKAGES, upon which to compile a package/ | ||
- | |||
- | Useful commands: | ||
- | *apt-get update | ||
- | |||
- | =====CENTOS===== | ||
- | *Uses yum/rpm. | ||
- | *Repos listed in **/ | ||
- | |||
- | ====rpm==== | ||
- | *-ivh // | ||
- | *-uvh - Same as -ive but upgrades a a package if already installed? | ||
- | *-q //pkgname// - Queries to see if // | ||
- | *-e //pkgname// - remove //pkgname// from system. | ||
- | |||
- | ====yum==== | ||
- | *yum makecache fast - updates local cache of repo contents. Similar to Pacman -Syy | ||
- | *yum search //name// - searches repos for pkgs named //name// | ||
- | *yum install //httpd// - installs //httpd// and deps from repos. | ||
- | *yum update -- updates all packages on system. | ||
- | |||
- |