0% found this document useful (0 votes)
41 views

01 Linux Intro

This document provides an introduction to the course "Introduction to Linux" and discusses some key topics that will be covered. It contains 3 main points: 1. It defines what an operating system is and describes the main functions of an OS, including providing hardware abstractions, interfaces for safe hardware access, and efficient resource utilization policies. 2. It introduces Linux as a widely used open-source operating system and discusses the Linux kernel, which is written in C and assembly and powers many modern systems. 3. It outlines the course structure and labs, which will involve modifying and evaluating the Linux kernel on Raspberry Pi systems to develop hands-on skills and intuition around operating system design and operation. Students are

Uploaded by

Tuan Long Nguyen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views

01 Linux Intro

This document provides an introduction to the course "Introduction to Linux" and discusses some key topics that will be covered. It contains 3 main points: 1. It defines what an operating system is and describes the main functions of an OS, including providing hardware abstractions, interfaces for safe hardware access, and efficient resource utilization policies. 2. It introduces Linux as a widely used open-source operating system and discusses the Linux kernel, which is written in C and assembly and powers many modern systems. 3. It outlines the course structure and labs, which will involve modifying and evaluating the Linux kernel on Raspberry Pi systems to develop hands-on skills and intuition around operating system design and operation. Students are

Uploaded by

Tuan Long Nguyen
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 12

Introduction to Linux

Chris Gill
CSE 422S - Operating Systems Organization
Washington University in St. Louis
St. Louis, MO 63130

Thanks to David Ferry, Brian Kocoloski, James Orr, and Marion Sudvarg, who
have helped to develop and/or refine much of the material in this course

1
What is an Operating System (OS)?
• First and foremost, it is a program, not entirely unlike other programs
you’ve written before

• The primary difference between the OS and other programs is that the
OS runs with high enough privilege to access hardware resources
directly
– Processors (multicore and GPU on your Raspberry Pi)
– I/O devices (keyboard/mouse/network card/etc.)
– Memory (including disk drives and other addressable storage)

• An operating system is a program that


1.Offers abstractions to make applications more portable across different types of
hardware (see arch-specific parts of Linux source)
2.Provides interfaces to applications to safely access hardware (e.g., isolated vs.
shared memory address spaces)
3.Implements policies that efficiently utilize hardware resources

E81 CSE 422S - Operating Systems Organization 2


OS Mediates Applications’ HW Access

User application User application User application

Operating System

Secondary
Peripheral Devices Main memory
CPU Cores memory
(keyboard, WiFi, etc.) (RAM)
(hard drives)

E81 CSE 422S - Operating Systems Organization 3


The Linux kernel
• A widely deployed open-source project

• Powers smartphones and even smaller devices as well


as some of the largest supercomputers

• Supports hundreds of different computer architectures

• Written in a combination of C and architecture-specific


assembly language

E81 CSE 422S - Operating Systems Organization 4


OS and Platform
• Our OS of choice is the Linux kernel

• This course is designed around the Raspberry Pi


– Avoids modifying the kernel on machines others may use
– Reasonably fast, multi-core + GPU, affordable
– Used elsewhere in WUSTL CSE research and education

• The Raspberry Pi family is based on the ARM


processor architecture
– Lots of processor-dependent code (in Linux arm directories)
– We will occasionally mention x86 differences, where relevant

E81 CSE 422S - Operating Systems Organization 5


Assigned Readings
Course textbooks
Linux Kernel Development 3rd Ed., Robert Love, 2010
The Linux Programming Interface, Michael Kerrisk, 2010
– Great starting resources for kernel hackers
– Plan to look at a lot of source code as well
– Course website provides other references too

On-line manual pages (Linux man commands)

Google and Elixir also can be very useful


– Linux is widely documented (but not all pages are current)
– Look at directories, files, etc. in specific kernel source
– We will link resources on course web site and in Canvas

E81 CSE 422S - Operating Systems Organization 6


Learn as you Go
This course will offer many opportunities for students to develop:

1.Intuition about OS structure, operation and design principles


– Syscalls, interrupts, threads, processes, scheduling, synchronization

2.Skills for monitoring the runtime operation of an OS


–Tracers: ftrace (trace-cmd and kernelshark), strace
–User space benchmarking using timers, etc.
–Using the scientific method (hypothesis, prediction, experiment, analysis)

3.Hands-on experience modifying and evaluating an OS


–Source-code intensive course based on Linux
–You’ll be asked to modify, build, and evaluate the OS kernel in different ways
–Studios will help you gain experience and expertise for the lab assignments

E81 CSE 422S - Operating Systems Organization 7


Words of Advice (from experience)
• Kernel hacking requires a lot of patience (and thought)
– Your systems likely will crash from time to time
– Don’t underestimate the power of using pencil and paper before you
start typing

• Work efficiently but persistently


– Our goal is for the time spent “hands-on” to be similar to our intro
courses
– Start early, fail (or succeed) quickly, iterate rapidly, progress steadily
over time

• A few tips for this course (to avoid problems we’ve seen
already)
– Brush up on your C
– Brush up on shell scripting

E81 CSE 422S - Operating Systems Organization 8


Comments from Previous Students
• “You program in C to reconfigure a Linux
Kernel on a Raspberry Pi. Prepare to
optimize your workflow for testing, and
brush up on C – you'll be using it a lot.”

• “[You] learn how the operating system


interfaces with the hardware to allow
users do everything from issue commands
to compiling programs.”

E81 CSE 422S - Operating Systems Organization 9


Comments from Previous Students
• “It made me more interested in the low–
level and hardware aspects of a computer!
It also made the "operating system" a less
scary and complex topic.”

• “ … it felt like we were doing things that


could actually be accomplished in the real
world.”

E81 CSE 422S - Operating Systems Organization 10


Communication and Resources
• Synchronous communication will be via Zoom this semester
– Meeting links and schedule can be found in Canvas
– Get help debugging and discuss alternative solutions via screen sharing during the
scheduled zoom meetings

• Asynchronous communication will be mainly via Piazza


– You should have received a link to the Piazza page already (please let us
know if you have not)
– Post any course-related questions to Piazza
– You will benefit when others ask questions, and others will benefit when you ask
questions

• The course schedule and lots of other details are posed both on the
course web site and in Canvas
– Any significant changes to the schedule or other details will be updated in both
places, and an announcement made in Piazza

E81 CSE 422S - Operating Systems Organization 11


The First Two Studios
• Downloading and Compiling the Linux kernel source
– You won’t need your Raspberry Pi until the second day
– We will use a technique called cross-compiling, on different
machine from where we will ultimately run the kernel (your
Raspberry Pi)

• Downloading and installing a built Linux kernel image


– We will also configure some settings on your Raspberry Pi

Compile the kernel here (studio 1) Install the kernel here (studio 2)

Linux Server

E81 CSE 422S - Operating Systems Organization 12

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy