Dustin Harman VM Workshop 2015 RPM Basics. What is RPM? Red Hat Package Manager Native package manager on RHEL, Fedora, SUSE, some Mandriva RPM/SRPM files.

Slides:



Advertisements
Similar presentations
Biopackages.net Operating System Packages for Bioinformatics Allen Day
Advertisements

Linux+ Guide to Linux Certification, Third Edition Chapter 11 Compression, System Backup, and Software Installation.
Installing Linux softwares Sirak Kaewjamnong. 2 Software packets  When Linux developers create their software they typically bundle all the executable.
Git: Part 1 Overview & Object Model These slides were largely cut-and-pasted from tutorial/, with some additions.
Chapter 11 Compression, System Backup, and Software Installation.
Downloading & Installing Software Chapter 13. Maintaining the System Yum Pirut BitTiorrent Rpm Keeping Software Up To Date Up2date Red Hat Network Wget.
Module 10 – Linux Installations. Wikipedia: Red Hat Package Manager or RPM Package Manager (RPM) is a package management system. The name RPM variously.
Managing Software using RPM. ♦ Overview In Linux, Red Hat Package Manager referred as RPM is a tool used for managing software packages and its main function.
Debian package manager Presenter: Lilian Wang. Install Software  先別管 package 了, 你有聽過重灌嗎 ?  Chrome/Firefox, Office, pietty, Notepad++, PCMan, LOL, …
SUSE Linux Enterprise Server Administration (Course 3037) Chapter 4 Manage Software for SUSE Linux Enterprise Server.
LPIC-1 TRAINING COURSE Topic 102: Linux Installation and package management.
Package Management How to use rpms. Topics The Problem of Software Installation Package Management Systems Using RPM Finding RPMs Building RPMs.
October, Scientific Linux INFN/Trieste B.Gobbo – Compass R.Gomezel - T.Macorini - L.Strizzolo INFN - Trieste.
Linux Package Management Dr. Michael L. Collard 1.
DB server + PHPMyAdmin ดรัสวิน วงศ์ปรเมษฐ์ สาขาวิชาเทคโนโลยีสารสนเทศ คณะ วิทยาศาสตร์ มรภ. บร. 19/10/56.
MAE Continuous Integration Administration guide July 8th, 2013.
CIT 470: Advanced Network and System AdministrationSlide #1 CIT 470: Advanced Network and System Administration Package Management.
CERN Manual Installation of a UI – Oxford July - 1 LCG2 Administrator’s Course Oxford University, 19 th – 21 st July Developed.
Install Software. UNIX Shell The UNIX/LINUX shell is a program important part of a Unix system. interface between the user & UNIX kernel starts running.
A Practical Guide to Fedora and Red Hat Enterprise Linux Unit 8: Installing Software in Linux Chapter 13: Downloading and Installing Software By Fred R.
SUSE Linux Enterprise Desktop Administration Chapter 6 Manage Software.
March 11, 2008 USCMS Tier-2 Workshop Oh Dear God Alain made a PowerPoint presentation 1.
Installation of packages Objectives –Using software packaging tools Contents –Application delivered as –Where to get commonly used rpm’s –Autofs on! –Getting.
SPMA & SWRep: Basic exercises HEPiX hands-on, NIKHEF 5/03 German Cancio
EMI is partially funded by the European Commission under Grant Agreement RI SA2 – Development Tools Andres Abad Rodriguez SA2.4 Tools Activity Leader.
J.P. Wellisch, CERN/EP/SFT SCRAM Information on SCRAM J.P. Wellisch, C. Williams, S. Ashby.
Installation of packages Objectives –Using software packaging tools Contents –Application delivered as –Where to get commonly used rpm’s –Autofs on! –Getting.
CSCI 330 UNIX and Network Programming Unit XX: Linux Administration.
Yannick Patois - Datagrid Software Repository Presentation - March, n° 1 Datagrid Software Repository Presentation CVS, packages and automatic.
Tanner Lovelace – Slide 1 RPM Packaging 101 Tanner Lovelace Triangle Linux Users Group 11/Jan/2003.
RedHat Package Management RPM and YUM in RedHat Enterprise, Fedora, Suse and Centos.
Installing Applications in FreeBSD lctseng. Computer Center, CS, NCTU 2 Before we start  Permission issue root: the super user Like administrator in.
Installing Applications in FreeBSD. Computer Center, CS, NCTU 2 Install software  Package Pre-built rpm, yum, dpkg, … FreeBSD: pkg_add, pkg_delete, pkg_info.
INFSOM-RI Training: Build using the ETICS Service The ETICS Build Process Alberto Di Meglio ETICS Project.
SCD Monthly Projects Meeting 2014 Scientific Linux Update Rennie Scott January 14, 2014.
Embedded Software Design Week II Linux Intro Linux Kernel.
ITMT 1371 – Windows 7 configuration Chapter 2: Installing Windows 7 ITMT 1371 – Windows 7 Configuration.
The EPIKH Project (Exchange Programme to advance e-Infrastructure Know-How) 马兰馨 IHEP, CAS Setting Up a Repository.
Tito Miroslav Suchý Red Hat
System Administration Application Management. ● A common task for a system administrator is the installation, updating and removal of software. Several.
Getting Started in RPM Packaging Izhar Firdaus / KageSenshi Contributor Fedora Project
Into Fedora RPM packages Lubomir Rintel Presented by Fedora Package Maintainer Creative Commons Attribution-ShareAlike license applies. Packaging Gems.
Perl in RPM-Land Dave Cross Magnum Solutions Ltd YAPC::Europe 15 th August 2008.
How to participate Introduction in creating RPM packages.
From Source Code to Packages for Various Distributions Andreas Jaeger Program Manager openSUSE
1 April 2, Software Packaging and Releasing Best Practices William Cohen NCSU CSC 591W April 2, 2008.
Workshop: Advanced Packaging
Packaging Software for Debian Roberto C. Sánchez Ohio Linuxfest Saturday, September 29, 2007.
Karsten Wade Sr. Developer Community Mgr, Red Hat.
RPM101: A gentle intro to creating your own packages Richard Keech Red Hat Asia-Pacific.
The RPM Package Manager
Building Good RPM Packages
New Tools Used by the Scientific Linux Team
Build process of ovirt-node and the plugins
application into a Flatpak
From Source Code to Packages for Various Distributions
How to make good RPM Packages
RPM Packaging for Sysadmins
Packaging a Structural Biology Application – imod / 3dmod
Packaging Example All Hands Meeting, Padova,
IBM Tivoli Provisioning Manager Red Hat 5 patch management
ATLAS Software Distribution
Workshop: Building Good Fedora Packages
Spacewalk and Koji at Fermilab
More Scripting & Chapter 11
RedHat Package Management
Lab #1 Install Linux & How to Build Live CD
University of Texas Rio Grande Valley Systems Administration CSCI 6175
Tanner Lovelace Triangle Linux Users Group 11/Jan/2003
Perl in RPM-Land Dave Cross Magnum Solutions Ltd YAPC::Europe
Presentation transcript:

Dustin Harman VM Workshop 2015 RPM Basics

What is RPM? Red Hat Package Manager Native package manager on RHEL, Fedora, SUSE, some Mandriva RPM/SRPM files contain binaries and/or source code

Why use RPM? Software installation and removal Configuration changes Same packing process for source, script, binary, config files, other For the end user

“rpm” command

Yum Uses RPM and provides additional package management functionality Install, delete, update, search, dependencies Pointed at repositories (local or external)

RPM build setup $ sudo yum install rpm-build redhat-rpm-config $ sudo yum install rpmlint make gcc $ mkdir -p ~/rpmbuild/{BUILD,RPMS,SOURCES,SPECS,SRPMS} $ echo '%_topdir %(echo $HOME)/rpmbuild' > ~/.rpmmacros $ echo '%packager First Last ' >> ~/.rpmmacros

RPM build setup

RPM build directory %_topdir (set via ~/.rpmmacros) –SOURCES –SPECS –RPMS noarch s390x... –SRPMS –BUILD

Spec file Tags –Name, Version, Release, Summary –Group, License, URL, SourceN, PatchN –Requires, BuildRequires –BuildRoot, BuildArch Scripts –%prep, %build, %install, %clean Other –%description –%files –%changelog

RPM Macros %setup %patchN %configure %{_bindir}... %config,%config(noreplace) %define

Conditionals %ifarch s390x %ifnarch s390x %else %endif

Generate patch files $ cp -rp./source./source-new [Make your changes to new source] $ diff -ru./source./source-new >| ~/rpmbuild/SOURCES/source.patch Patch1: source.patch %patch1 -p0

“rpmbuild” command rpmbuild -bs –Build source RPM rpmbuild -bb –Build binary RPM rpmbuild -ba –Build all RPMs (binary and source) rpmbuild --rebuild

“rpmbuild” magic Requires Debuginfo packages

Debugging Check the rpmbuild/BUILD directory rpm --eval %macro rpmlint

Compatibility issues Third-party repositories Mock Hash algorithm changes

Yum Repository Creation $ sudo yum install createrepo $ createrepo /srv/example/repo [examplerepo] name = Example Repository baseurl = file:///srv/example/repo/ baseurl =

Recommended reading rpm(8), rpmbuild(8), yum(8), createrepo(8) Maximum RPM:

Spec file walkthrough and demo

Questions?