Linux Fundamentals Course Length: 5 Days Course Code: GL120

Total Page:16

File Type:pdf, Size:1020Kb

Linux Fundamentals Course Length: 5 Days Course Code: GL120 Linux Fundamentals Course Length: 5 Days Course Code: GL120 Course Description Lesson 2: Login and Exploration The GL120 is a challenging course that focuses on the Logging In fundamental tools and concepts of Linux and Unix. Running Programs Students gain proficiency using the command line. Interacting with Command Line Beginners develop a solid foundation in Unix, while The X Window System advanced users discover patterns and fill in gaps in their Starting X knowledge. Like all Guru Labs courses, the course Gathering Login Session Info material is designed to provide extensive hands-on Gathering System Info experience. Topics include: basic file manipulation; basic and advanced filesystem features; I/O redirection and uptime pipes; text manipulation and regular expressions; got root? managing jobs and processes; vi, the standard Unix Switching User Contexts editor; automating tasks with shell scripts; managing sudo software; secure remote administration; and more. Help from Commands and Documentation whereis Prerequisites Getting Help Within the Graphical Desktop Getting Help with man & info Students should be comfortable with computers. No familiarity with Linux or other Unix operating systems is required. Lesson 3: The Linux Filesystem Filesystem Support Course Content Unix/Linux Filesystem Features Filesystem Hierarchy Standard Lesson 1: What is Linux Navigating the Filesystem Unix and its Design Principles Displaying Directory Contents FSF and GNU Filesystem Structures GPL – General Public License Determining Disk Usage With df and du The Linux Kernel Determining Disk Usage (GUI) Linux Kernel and Versioning Disk Usage with Quotas Components of a Distribution File Ownership Slackware Default Group Ownership SUSE Linux Products File and Directory Permissions Debian File Creation Permissions with umask Ubuntu SUID and SGID on files Red Hat Linux Products SGID and Sticky Bit on Directories Oracle Linux Changing File Permissions User Private Group Scheme Lesson 4: Manipulating Files Lesson 8: Regular Expressions Directory Manipulation Regular Expression Overview File Manipulation Regular Expressions Deleting and Creating Files RE Character Classes Physical Unix File Structure Regex Quantifiers Filesystem Links RE Parenthesis File Extensions and Content Displaying Files Lesson 9: Text Editing Previewing Files Text Editing Producing File Statistics Pico/GNU Nano Displaying Binary Files Pico/Nano Interface Searching the Filesystem Nano configuration Alternate Search Method Pico/Nano Shortcuts vi and Vim Lesson 5: Shell Basics Learning Vim Role of Command Shell Basic vi Communication Channels Intermediate vi File Redirection Piping Commands Together Lesson 10: Messaging Filename Matching System Messaging Commands File Globbing and Wildcard Patterns Controlling System Messaging Brace Expansion Internet Relay Chat Shell and Environment Variables Instant Messenger Clients Key Environment Variables Electronic Mail Which and Type Sending Email with sendmail General Quoting Rules Sending and Receiving Email with mailx Nesting Commands Sending and Receiving Email with mutt Sending Email with Pine Lesson 6: Archiving and Compression Evolution Archives with tar Archives with cpio Lesson 11: Command Shells The gzip Compression Utility Shells The bzip2 Compression Utility Identifying the Shell The XZ Compression Utility Changing the Shell The PKZIP Archiving/Compression format Configuration Files GNOME File Roller Script Execution Shell Prompts Lesson 7: Text Processing Bash: Bourne-Again Shell Searching Inside Files Bash: Configuration Files The Streaming Editor Bash: Command Line History Text Processing with Awk Bash: Command Editing Replacing Text Characters Bash: Command Completion Text Sorting Bash: "shortcuts" Duplicate Removal Utility Bash: prompt Extracting Columns of Text Setting Resource Limits via ulimit Combining Files and Merging Text Comparing File Changes Lesson 12: Introduction to Shell Scripting Lesson 15: Managing Software Shell Script Strengths and Weaknesses Downloading with FTP Example Shell Script FTP Positional Parameters lftp Input & Output Command Line Internet – Non-interactive Doing Math Command Line Internet – Interactive Comparisons with test Managing Software Dependencies Exit Status Using the Yum command Conditional Statements YUM package groups Flow Control: case Configuring Yum The for Loop yumdownloader The while and until Loops Popular Yum Repositories Using the Zypper command Lesson 13: Process Management and Job Control Zypper Services and Catalogs The dselect & APT Frontends to dpkg What is a Process? Aptitude Process Lifecycle Configuring APT Process States Viewing Processes Lesson 16: The Secure Shell (SSH) Signals Tools to Send Signals Secure Shell nohup and disown ssh and sshd Configuration Managing Processes Accessing Remote Shells Tuning Process Scheduling Transferring Files Job Control Overview Alternative sftp Clients Job Control Commands SSH Key Management Persistent Shell Sessions with Screen ssh-agent Using screen Advanced Screen Lesson 17: Mounting Filesystems & Managing Removable Media Lesson 14: At and Cron Filesystems Concept Review Automating Tasks Mounting Filesystems at/batch NFS cron SMB The crontab Command Filesystem Table (/etc/fstab) crontab Format AutoFS /etc/cron.*/ Directories Removable Media Anacron Lesson 18: Printing Legacy Print Systems Common UNIX Printing System Defining a Printer Standard Print Commands Format Conversion Utilities enscript and mpage Lesson 19: The X Window System X Modularity X.Org Drivers Configuring X Manually Automatic X Configuration Xorg and Fonts Installing Fonts for Modern Applications Installing Fonts for Legacy Applications The X11 Protocol and Display Names Display Managers and Graphical Login Starting X Apps Automatically X Access Control Remote X Access (historical/insecure) Remote X Access (modern/secure) XDMCP Remote Graphical Access With VNC and RDP Specialized X Servers Lesson 20: Emacs Emacs The Emacs Interface Basic Emacs More Emacs Commands .
Recommended publications
  • Tortoisemerge a Diff/Merge Tool for Windows Version 1.11
    TortoiseMerge A diff/merge tool for Windows Version 1.11 Stefan Küng Lübbe Onken Simon Large TortoiseMerge: A diff/merge tool for Windows: Version 1.11 by Stefan Küng, Lübbe Onken, and Simon Large Publication date 2018/09/22 18:28:22 (r28377) Table of Contents Preface ........................................................................................................................................ vi 1. TortoiseMerge is free! ....................................................................................................... vi 2. Acknowledgments ............................................................................................................. vi 1. Introduction .............................................................................................................................. 1 1.1. Overview ....................................................................................................................... 1 1.2. TortoiseMerge's History .................................................................................................... 1 2. Basic Concepts .......................................................................................................................... 3 2.1. Viewing and Merging Differences ...................................................................................... 3 2.2. Editing Conflicts ............................................................................................................. 3 2.3. Applying Patches ...........................................................................................................
    [Show full text]
  • Editores, Compilación Y Ejecución)
    Guía práctica de estudio 06: Entorno de C (editores, compilación y ejecución) Elaborado por: Ing. Laura Sandoval Montaño Juan Francisco De reza Trujillo Guía práctica de estudio 06: Entorno de C (editores, compilación y ejecución) Objetivo: Conocer y usar los ambientes y herramientas para el desarrollo y ejecución de programas en Lenguaje C, como editores y compiladores en diversos sistemas operativos. Actividades: . Utilizando un editor de GNU/Linux, crear un archivo de texto . Modificar/actualizar un archivo ya existente con un editor GNU/Linux. Crear, compilar y ejecutar un programa simple escrito en C en GNU/Linux . En algún entorno de desarrollo de Windows, crear, compilar y ejecutar un programa simple escrito en C. Introducción Un lenguaje de programación permite expresar una serie de instrucciones que podrán ser realizadas por una computadora. Unos de los lenguajes de programación mayormente difundidos es el lenguaje C. Éste es muy utilizado ya que la forma de dar instrucciones es muy cercana a lo que un humano podría abstraer, es decir, las instrucciones no son tal cual las que una computadora podría entender, para ello se necesitaría conocer a fondo el microprocesador, el sistema operativo entre otros aspectos. Por esta razón, C es conocido como un lenguaje de alto nivel, esto significa a que las instrucciones podrían ser entendidas fácilmente por un humano. En contraparte, un lenguaje de bajo nivel, son instrucciones que son cercanas a lo que la máquina puede entender y difícilmente pueden ser comprendidas por una persona que no tenga conocimientos de la máquina en que operarán. Algunos autores consideran al lenguaje C como un lenguaje de mediano nivel, ya que no es totalmente transparente sino tiene elementos que tienen que ver con la arquitectura de la máquina a la hora de programar.
    [Show full text]
  • Vim for Humans Release 1.0
    Vim for humans Release 1.0 Vincent Jousse August 12, 2015 CONTENTS 1 Preamble 1 1.1 Disclaimer .................... ..................... 1 1.2 Paid book but free price .................... ..................... 1 1.3 Free license .................... ..................... 1 1.4 Thanks .................... ..................... 1 2 Introduction 3 2.1 For who? .................... ..................... 4 2.2 What you will be learning .................... .................... 4 2.3 What you will not be learning .................... .................. 4 2.4 The hardest part is to get started .................... ................. 5 3 Having a usable Vim 7 3.1 Essential preamble: the insert mode .................... ............... 8 3.2 Modes: the powerful Vim secrets .................... 10 3.3 The lifesaver default configuration .................... 12 3.4 And now, the color! .................... ..................... 13 3.5 Ourfirst plugin: thefile explorer .................... 17 3.6 Here we go .................... ..................... 19 4 The text editor you’ve always dreamed of 23 4.1 Learning how to move: the copy/paste use case ..................... 23 4.2 Forgetting the directional keys .................... 26 4.3 Doing without the Esc key .................... .................... 29 4.4 Combining keys and moves .................... ................... 29 4.5 Search / Move quickly .................... ..................... 30 4.6 Visual mode .................... ..................... 31 4.7 It’s your turn! .................... ....................
    [Show full text]
  • Linux Fundamentals (GL120) U8583S This Is a Challenging Course That Focuses on the Fundamental Tools and Concepts of Linux and Unix
    Course data sheet Linux Fundamentals (GL120) U8583S This is a challenging course that focuses on the fundamental tools and concepts of Linux and Unix. Students gain HPE course number U8583S proficiency using the command line. Beginners develop a Course length 5 days solid foundation in Unix, while advanced users discover Delivery mode ILT, vILT patterns and fill in gaps in their knowledge. The course View schedule, local material is designed to provide extensive hands-on View now pricing, and register experience. Topics include basic file manipulation; basic and View related courses View now advanced filesystem features; I/O redirection and pipes; text manipulation and regular expressions; managing jobs and processes; vi, the standard Unix editor; automating tasks with Why HPE Education Services? shell scripts; managing software; secure remote • IDC MarketScape leader 5 years running for IT education and training* administration; and more. • Recognized by IDC for leading with global coverage, unmatched technical Prerequisites Supported distributions expertise, and targeted education consulting services* Students should be comfortable with • Red Hat Enterprise Linux 7 • Key partnerships with industry leaders computers. No familiarity with Linux or other OpenStack®, VMware®, Linux®, Microsoft®, • SUSE Linux Enterprise 12 ITIL, PMI, CSA, and SUSE Unix operating systems is required. • Complete continuum of training delivery • Ubuntu 16.04 LTS options—self-paced eLearning, custom education consulting, traditional classroom, video on-demand
    [Show full text]
  • A.5.1. Linux Programming and the GNU Toolchain
    Making the Transition to Linux A Guide to the Linux Command Line Interface for Students Joshua Glatt Making the Transition to Linux: A Guide to the Linux Command Line Interface for Students Joshua Glatt Copyright © 2008 Joshua Glatt Revision History Revision 1.31 14 Sept 2008 jg Various small but useful changes, preparing to revise section on vi Revision 1.30 10 Sept 2008 jg Revised further reading and suggestions, other revisions Revision 1.20 27 Aug 2008 jg Revised first chapter, other revisions Revision 1.10 20 Aug 2008 jg First major revision Revision 1.00 11 Aug 2008 jg First official release (w00t) Revision 0.95 06 Aug 2008 jg Second beta release Revision 0.90 01 Aug 2008 jg First beta release License This document is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 United States License [http:// creativecommons.org/licenses/by-nc-sa/3.0/us/]. Legal Notice This document is distributed in the hope that it will be useful, but it is provided “as is” without express or implied warranty of any kind; without even the implied warranties of merchantability or fitness for a particular purpose. Although the author makes every effort to make this document as complete and as accurate as possible, the author assumes no responsibility for errors or omissions, nor does the author assume any liability whatsoever for incidental or consequential damages in connection with or arising out of the use of the information contained in this document. The author provides links to external websites for informational purposes only and is not responsible for the content of those websites.
    [Show full text]
  • Text Editing in UNIX: an Introduction to Vi and Editing
    Text Editing in UNIX A short introduction to vi, pico, and gedit Copyright 20062009 Stewart Weiss About UNIX editors There are two types of text editors in UNIX: those that run in terminal windows, called text mode editors, and those that are graphical, with menus and mouse pointers. The latter require a windowing system, usually X Windows, to run. If you are remotely logged into UNIX, say through SSH, then you should use a text mode editor. It is possible to use a graphical editor, but it will be much slower to use. I will explain more about that later. 2 CSci 132 Practical UNIX with Perl Text mode editors The three text mode editors of choice in UNIX are vi, emacs, and pico (really nano, to be explained later.) vi is the original editor; it is very fast, easy to use, and available on virtually every UNIX system. The vi commands are the same as those of the sed filter as well as several other common UNIX tools. emacs is a very powerful editor, but it takes more effort to learn how to use it. pico is the easiest editor to learn, and the least powerful. pico was part of the Pine email client; nano is a clone of pico. 3 CSci 132 Practical UNIX with Perl What these slides contain These slides concentrate on vi because it is very fast and always available. Although the set of commands is very cryptic, by learning a small subset of the commands, you can edit text very quickly. What follows is an outline of the basic concepts that define vi.
    [Show full text]
  • BSD UNIX Toolbox 1000+ Commands for Freebsd, Openbsd
    76034ffirs.qxd:Toolbox 4/2/08 12:50 PM Page iii BSD UNIX® TOOLBOX 1000+ Commands for FreeBSD®, OpenBSD, and NetBSD®Power Users Christopher Negus François Caen 76034ffirs.qxd:Toolbox 4/2/08 12:50 PM Page ii 76034ffirs.qxd:Toolbox 4/2/08 12:50 PM Page i BSD UNIX® TOOLBOX 76034ffirs.qxd:Toolbox 4/2/08 12:50 PM Page ii 76034ffirs.qxd:Toolbox 4/2/08 12:50 PM Page iii BSD UNIX® TOOLBOX 1000+ Commands for FreeBSD®, OpenBSD, and NetBSD®Power Users Christopher Negus François Caen 76034ffirs.qxd:Toolbox 4/2/08 12:50 PM Page iv BSD UNIX® Toolbox: 1000+ Commands for FreeBSD®, OpenBSD, and NetBSD® Power Users Published by Wiley Publishing, Inc. 10475 Crosspoint Boulevard Indianapolis, IN 46256 www.wiley.com Copyright © 2008 by Wiley Publishing, Inc., Indianapolis, Indiana Published simultaneously in Canada ISBN: 978-0-470-37603-4 Manufactured in the United States of America 10 9 8 7 6 5 4 3 2 1 Library of Congress Cataloging-in-Publication Data is available from the publisher. No part of this publication may be reproduced, stored in a retrieval system or transmitted in any form or by any means, electronic, mechanical, photocopying, recording, scanning or otherwise, except as permitted under Sections 107 or 108 of the 1976 United States Copyright Act, without either the prior written permission of the Publisher, or authorization through payment of the appropriate per-copy fee to the Copyright Clearance Center, 222 Rosewood Drive, Danvers, MA 01923, (978) 750-8400, fax (978) 646-8600. Requests to the Publisher for permis- sion should be addressed to the Legal Department, Wiley Publishing, Inc., 10475 Crosspoint Blvd., Indianapolis, IN 46256, (317) 572-3447, fax (317) 572-4355, or online at http://www.wiley.com/go/permissions.
    [Show full text]
  • The Unix Shell Introduction to the Shell Files and the File System Creating and Deleting Files
    The Unix Shell Introduction to the shell Files and the file system Creating and deleting files Copyright © Software Carpentry 2010 This work is licensed under the Creative Commons Attribution License See http://software-carpentry.org/license.html for more information. The Unix Shell Introduction Copyright © Software Carpentry 2010 This work is licensed under the Creative Commons Attribution License See http://software-carpentry.org/license.html for more information. The Unix Shell Introduction The Unix Shell Introduction Run Programs The Unix Shell Introduction Run Store Programs Data The Unix Shell Introduction Run Store Programs Data Communicate with each other The Unix Shell Introduction Run Store Programs Data Communicate Interact with each other with us The Unix Shell Introduction Interact with us The Unix Shell Introduction Interact with us Telepathy The Unix Shell Introduction Interact with us Telepathy Speech The Unix Shell Introduction Interact with us Telepathy Speech WIMP (windows, icons, mice, pointers) The Unix Shell Introduction Interact with us Rewiring Telepathy Speech WIMP The Unix Shell Introduction Interact with us Rewiring Telepathy Typewriter Speech WIMP The Unix Shell Introduction Typewriter The Unix Shell Introduction Typewriter Line printer + keyboard The Unix Shell Introduction Typewriter Line printer + keyboard Text only The Unix Shell Introduction Typewriter Line printer + keyboard Text only The Unix Shell Introduction Typewriter Line printer + keyboard Text only CLUI: command-line user interface The Unix Shell
    [Show full text]
  • Research Computing and Cyberinfrastructure Team
    Research Computing and CyberInfrastructure team ! Working with the Linux Shell on the CWRU HPC 31 January 2019 7 February 2019 ! Presenter Emily Dragowsky KSL Data Center RCCI Team: Roger Bielefeld, Mike Warfe, Hadrian Djohari! Brian Christian, Emily Dragowsky, Jeremy Fondran, Cal Frye,! Sanjaya Gajurel, Matt Garvey, Theresa Griegger, Cindy Martin, ! Sean Maxwell, Jeno Mozes, Nasir Yilmaz, Lee Zickel Preface: Prepare your environment • User account ! # .bashrc ## cli essentials ! if [ -t 1 ] then bind '"\e[A": history-search-backward' bind '"\e[B": history-search-forward' bind '"\eOA": history-search-backward' bind '"\eOB": history-search-forward' fi ! This is too useful to pass up! Working with Linux • Preamble • Intro Session Linux Review: Finding our way • Files & Directories: Sample work flow • Shell Commands • Pipes & Redirection • Scripting Foundations • Shell & environment variables • Control Structures • Regular expressions & text manipulation • Recap & Look Ahead Rider Cluster Components ! rider.case.edu ondemand.case.edu University Firewall ! Admin Head Nodes SLURM Science Nodes Master DMZ Resource ! Data Manager Transfer Disk Storage Nodes Batch nodes GPU nodes SMP nodes Running a job: where is it? slide from Hadrian Djohari Storing Data on the HPC table from Nasir Yilmaz How data moves across campus • Buildings on campus are each assigned to a zone. Data connections go from every building to the distribution switch at the center of the zone and from there to the data centers at Kelvin Smith Library and Crawford Hall. slide
    [Show full text]
  • Bash Guide for Beginners
    Bash Guide for Beginners Machtelt Garrels Garrels BVBA <tille wants no spam _at_ garrels dot be> Version 1.11 Last updated 20081227 Edition Bash Guide for Beginners Table of Contents Introduction.........................................................................................................................................................1 1. Why this guide?...................................................................................................................................1 2. Who should read this book?.................................................................................................................1 3. New versions, translations and availability.........................................................................................2 4. Revision History..................................................................................................................................2 5. Contributions.......................................................................................................................................3 6. Feedback..............................................................................................................................................3 7. Copyright information.........................................................................................................................3 8. What do you need?...............................................................................................................................4 9. Conventions used in this
    [Show full text]
  • Linux Cheat Sheet
    1 of 4 ########################################### # 1.1. File Commands. # Name: Bash CheatSheet # # # # A little overlook of the Bash basics # ls # lists your files # # ls -l # lists your files in 'long format' # Usage: A Helpful Guide # ls -a # lists all files, including hidden files # # ln -s <filename> <link> # creates symbolic link to file # Author: J. Le Coupanec # touch <filename> # creates or updates your file # Date: 2014/11/04 # cat > <filename> # places standard input into file # Edited: 2015/8/18 – Michael Stobb # more <filename> # shows the first part of a file (q to quit) ########################################### head <filename> # outputs the first 10 lines of file tail <filename> # outputs the last 10 lines of file (-f too) # 0. Shortcuts. emacs <filename> # lets you create and edit a file mv <filename1> <filename2> # moves a file cp <filename1> <filename2> # copies a file CTRL+A # move to beginning of line rm <filename> # removes a file CTRL+B # moves backward one character diff <filename1> <filename2> # compares files, and shows where differ CTRL+C # halts the current command wc <filename> # tells you how many lines, words there are CTRL+D # deletes one character backward or logs out of current session chmod -options <filename> # lets you change the permissions on files CTRL+E # moves to end of line gzip <filename> # compresses files CTRL+F # moves forward one character gunzip <filename> # uncompresses files compressed by gzip CTRL+G # aborts the current editing command and ring the terminal bell gzcat <filename> #
    [Show full text]
  • Parallel Processing Here at the School of Statistics
    Parallel Processing here at the School of Statistics Charles J. Geyer School of Statistics University of Minnesota http://www.stat.umn.edu/~charlie/parallel/ 1 • batch processing • R package multicore • R package rlecuyer • R package snow • grid engine (CLA) • clusters (MSI) 2 Batch Processing This is really old stuff (from 1975). But not everyone knows it. If you do the following at a unix prompt nohup nice -n 19 some job & where \some job" is replaced by an actual job, then • the job will run in background (because of &). • the job will not be killed when you log out (because of nohup). • the job will have low priority (because of nice -n 19). 3 Batch Processing (cont.) For example, if foo.R is a plain text file containing R commands, then nohup nice -n 19 R CMD BATCH --vanilla foo.R & executes the commands and puts the printout in the file foo.Rout. And nohup nice -n 19 R CMD BATCH --no-restore foo.R & executes the commands, puts the printout in the file foo.Rout, and saves all created R objects in the file .RData. 4 Batch Processing (cont.) nohup nice -n 19 R CMD BATCH foo.R & is a really bad idea! It reads in all the objects in the file .RData (if one is present) at the beginning. So you have no idea whether the results are reproducible. Always use --vanilla or --no-restore except when debugging. 5 Batch Processing (cont.) This idiom has nothing to do with R. If foo is a compiled C or C++ or Fortran main program that doesn't have command line arguments (or a shell, Perl, Python, or Ruby script), then nohup nice -n 19 foo & runs it.
    [Show full text]