• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Sysadmins' Rosetta Stone
 

Sysadmins' Rosetta Stone

on

  • 5,377 views

A description of the differences between Red Hat's way of doing things and Debian's way of doing things.

A description of the differences between Red Hat's way of doing things and Debian's way of doing things.

Statistics

Views

Total Views
5,377
Views on SlideShare
5,052
Embed Views
325

Actions

Likes
2
Downloads
51
Comments
1

4 Embeds 325

http://moodle.unibague.edu.co 296
http://www.slideshare.net 26
http://www.linkedin.com 2
https://www.linkedin.com 1

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

CC Attribution-ShareAlike LicenseCC Attribution-ShareAlike License

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel

11 of 1 previous next

  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Sysadmins' Rosetta Stone Sysadmins' Rosetta Stone Presentation Transcript

    • Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Sysadmins’ Rosetta Stone Files Services Mackenzie Morgan Ohio LinuxFest 2009 26 September 2009
    • Outline Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction 1 Introduction Package Management Files 2 Package Management Services 3 Files 4 Services
    • Me Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Mackenzie Morgan Management Computer Science student Files Services *buntu contributor At home: Kubuntu At work: Red Hat (. . . and SUSE. . . and Solaris. . . and AIX. . . )
    • This Talk Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management You: “Red Hat, Red Hat, Red Hat, I sure love Red Hat!” Files Pointy-Haired Boss: We’re switching to Debian Services You: But they don’t even use RPM! (Swap “Debian” for “Red Hat” and vice-versa as necessary)
    • Outline Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction 1 Introduction Package Management Files 2 Package Management Services 3 Files 4 Services
    • Why Package Management First? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Lots of commands Services Use it the most
    • Apt and Yum and Bears, Oh my! Sysadmins’ Rosetta Stone Mackenzie Morgan Common Debian tools: Introduction apt-cache Package Management apt-get Files aptitude Services dpkg tasksel Common Red Hat & Fedora tools: rpm yum
    • Package Naming Conventions: Red Hat Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package python 2.6-1.i386.rpm Management Parts: Files Software name Services Software version Package version Architecture
    • Package Naming Conventions: Debian Sysadmins’ Rosetta Stone Mackenzie Morgan python2.6 2.6.2-3 amd64.deb Introduction python2.6 2.6.2-3ubuntu1 amd64.deb Package Parts: Management Files Software name Services Library version (optional) Software version Debian package version Ubuntu package version (only if Ubuntu modifications exist) Architecture
    • Installing and Removing a Local Package Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Install: Package Management dpkg -i python2.6 2.6.2-3 amd64.deb Files rpm -Uvh python 2.6-1.i386.rpm Services Remove: dpkg -r python2.6 rpm -e python
    • Installing and Removing Packages with Repositories Sysadmins’ Rosetta Stone Mackenzie Morgan Install: Introduction apt-get install python2.6 Package Management aptitude install python2.6 Files yum install python Services Remove: apt-get remove python2.6 aptitude remove python2.6 yum remove python Great! Not much to learn there!
    • Wait. . . Apt-get? Aptitude? Sysadmins’ Rosetta Stone Mackenzie Aptitude: Morgan Always installs “Recommends:” packages Introduction Tracks “manual” versus “automatically” installed packages Package Management Removes “orphaned” packages Files Apt-get: Services Can be configured to automatically install “Recommends:” packages or not (current default: install them) Will prompt about orphaned packages apt-get autoremove will remove orphaned packages Convergence! Aptitude’s main use? Avoiding remembering apt-get and apt-cache
    • How do I find a package? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Debian: Package Management apt-cache search text editor Files Services aptitude search text editor Diff? Aptitude alphabetizes and lists install status Red Hat: yum search text editor
    • What if I want lots of packages? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management List them all! Or. . . Files Metapackages Services Tasksel Groupinstall
    • Metapackages Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Dummy package, depends on lots of other packages Files Ex: Services apt-get install build-essential installs development tools (gcc, kernel headers, etc.)
    • Tasksel Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files TUI to select and install a certain task, ex: LAMP server Services Just run tasksel
    • Groupinstall Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Feature of Yum Files Ex: Services yum groupinstall ‘‘Development Tools’’ is roughly equivalent to the earlier “build-essential” example
    • Speaking of Development Packages. . . Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: -dev packages for headers Services Red Hat: -devel packages for headers
    • Staying up to date Sysadmins’ Rosetta Stone Mackenzie Morgan Get updated list of available packages: Introduction apt-get update or aptitude update Package Management yum check-update Files Install software updates Services apt-get upgrade or aptitude safe-upgrade yum update (does the above and installs in tandem) Install all software updates and remove obsolete packages apt-get dist-upgrade or aptitude full-upgrade yum upgrade
    • What if I only want to update one package? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files apt-get install python2.6 Services yum update python
    • When I remove a package, what happens to config files? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: They’re retained. . . unless apt-get purge Services python2.6 Red Hat: They’re removed
    • Which package is this file in? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Debian: Management Files If file exists dpkg -S $FILENAME Services If not apt-file search $FILENAME Red Hat: rpm -qf $FILENAME
    • What version of a package is installed? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Debian: Management Files dpkg -l $PACKAGE Services apt-cache policy $PACKAGE Red Hat: rpm -qi $PACKAGE | awk ‘/Version/{ print $3 }’
    • Outline Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction 1 Introduction Package Management Files 2 Package Management Services 3 Files 4 Services
    • Speaking of Packages. . . Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Where are repositories configured? Package Management Debian: /etc/apt/sources.list Files Red Hat: /etc/yum.repos.d/*.repo Services Where do downloaded packages go? Debian: /var/cache/apt/archives/ Red Hat: /var/cache/yum/
    • Interface configuration files Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: /etc/network/interfaces Services Red Hat: /etc/sysconfig/network-scripts/ifcfg-* (ex: ifcfg-eth0)
    • Timezones Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: /etc/timezone Services Red Hat: /etc/sysconfig/clock
    • Modules to load Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: /etc/modules Services Red Hat: /etc/sysconfig/udev-stw
    • For the OpenAFS users. . . Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package krb5-config has no standard place Management Files Debian: /usr/bin/krb5-config Services Red Hat: /usr/kerberos/bin/krb5-config SUSE: /usr/mit/bin/krb5-config Solaris: /opt/csw/bin/krb5-config
    • Webserver Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: /etc/apache2/ Services Red Hat: /etc/httpd/
    • Firewall configuration Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Debian: /var/lib/iptables Services Red Hat: /etc/sysconfig/iptables
    • IDs Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction UIDs and GIDs vary Package Management Debian starts at 1000 Files Red Hat starts at 500 Services Filesystem permissions become sad Change here: Debian: /etc/adduser.conf Red Hat: /etc/login.defs
    • Outline Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction 1 Introduction Package Management Files 2 Package Management Services 3 Files 4 Services
    • What’s a Runlevel? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Pre-defined sets of scripts and programs to start in a specific Services state
    • What does each runlevel do? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package That depends. Are you asking: Management Files 1 Someone who read a book on “Linux” once Services 2 Someone who’s poked at their system’s runlevels 3 Someone who’s used many distros 4 Wikipedia
    • Runlevels By Distro Sysadmins’ Rosetta Stone Distro/Runlevel 2 3 4 5 Mackenzie Morgan By the book ♠ ♣ ♦ Debian Introduction Gentoo ♠ ♦ Package Management Red Hat ♣ ♦ Files SUSE ♠ ♣ ♦ Services Key: ♦ = Undefined = Multi-user with display manager ♣ = Multi-user without display manager ♠ = Multi-user without networking or display manager = Multi-user with networking but without most network services
    • How do I change runlevels’ services? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Old Answer: Package Management Debian: manually create/rm symlinks (or Files update-rc.d. . . if you’re a script) Services Red Hat: use chkconfig New Answer: Use chkconfig Yay! Convergence!
    • How do I start/stop/restart a service? Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Old Answer: Management Debian: /etc/init.d/$SERVICE start Files Services Red Hat: service $SERVICE start or that New Answer: service $SERVICE start Yay! Convergence!
    • References Sysadmins’ Rosetta Stone Mackenzie Morgan Introduction Package Management Files Services http://en.wikipedia.org/wiki/Runlevel