19
GNU/Linux Introduction Linux Introduction: Part 1 Simon M. Haller, Sebastian Stabinger iis.uibk.ac.at

Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

  • Upload
    others

  • View
    9

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

GNU/Linux IntroductionLinux Introduction: Part 1

Simon M. Haller, Sebastian Stabinger

iis.uibk.ac.at

Page 2: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Windows / Linux @ Central IT Services

• Windwos 7

• Centos 7.3

• Zugriff von Windows auf Linux (WinSCP, PuTTy)

• Zugriff von Extern über VPN (https://vpn.uibk.ac.at)

Linux Introduction: Part 1 1

Page 3: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Geschichte

Die Anfänge von Unix

• MULTICS (1969)

• UNIX (1971)

• ab 1974 Spaltung in Derivate• IRIX• Solaris• HP/UX• AIX• BSD

http://en.wikipedia.org/wiki/Unix

Linux Introduction: Part 1 2

Page 4: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

GNU/Linux – Einleitung

Unix–Design–Paradigmen

• Everything is a file

• One tool for one job

• Multiuser und Netzwerk

Linus und die ersten Schritte

• Start im Jahr 1991

• erster unter der GPL veröffentlichter Linux Kernel(Version 0.99) 1992

• Version 1.0 erst 1994

Linux Introduction: Part 1 3

Page 5: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Kernel

Betriebssystem

• Verwaltung von Ressourcen (Prozessor,Hauptspeicher, Platte, Netzwerk, . . . )

• Betriebssystem vergibt diese Ressourcen

• Betriebssystem benötigt Ressourcen

Unterschied zwischen Betriebssystem und Kernel

• Kernel ist Teil des Betriebssystems und verwaltet die Hardware

• Ein Betriebssystem besteht zudem noch aus grundlegendenSystemprogrammen, die dem Bootvorgang und der Konfiguration desSystems dienen.

Linux Introduction: Part 1 4

Page 6: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Kernel

Interaktion zwischen Kernel Space, User Space und Hardware

Linux Introduction: Part 1 5

Page 7: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Der Bootvorgang

Linux Introduction: Part 1 6

Page 8: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Systemd Boot

Linux Introduction: Part 1 7

Page 9: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Vom C–Programm zum Maschinencode

Linux Introduction: Part 1 8

Page 10: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Desktopmanager & Windowmanager

Linux Introduction: Part 1 9

Page 11: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Das X–Window–System

X-Server

• Kontrolliert die Anzeige, die Tastatur, die Maus sowie andere Eingabegeräte

• Kommuniziert Ereignisse an den Client

• Verantwortlich für Präsentation der Fenster und Zeichensatz

X-Client

• Anwendungsprogramm verwendet Ein- und Ausgabe-Dienste des X-Servers

• Kann auf demselben oder einem entfernten Rechner laufen

• Wartet (passiv) auf Ereignisse (events) des X-Servers (Tastenanschläge,Mausbewegungen, Klicks,. . . )

• Führt Applikationscode aus

Linux Introduction: Part 1 10

Page 12: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Relative und Absolute Pfadnamen

Relative Pfadnamen

Es wird von aktuellen Arbeitsverzeichnis ausgegangen

• cd ./linuxkurs/Beispielverzeichnis

Absolute Pfadnamen

Beginnen immer mit einem /

• cd /home/simon/linuxkurs/Beispielverzeichnis

Linux Introduction: Part 1 11

Page 13: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Pfadnamen II

Das Arbeitsverzeichnis

• Ist das Verzeichnis, von dem relative Pfadnamen ausgehen.

• Wenn kein Pfadname angegeben wird, dann wird im CWD (current workingdirectory) gesucht

$ cd Directory wechselt in das Verzeichnis Directory (relativ oderabsolut)

$ cd alleine wechselt ins $HOME

$ pwd print working directory

• Speziell:. aktuelles Verzeichnis.. übergeordnetes Verzeichnis

Linux Introduction: Part 1 12

Page 14: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Groß - und Kleinschreibung

Achtung

auf Groß - und Kleinschreibung!

Linux Introduction: Part 1 13

Page 15: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Verzeichnisstruktur I

Root

/bin Systemprogramme

/dev Devices

/etc Konfigurationsdateien

/root Home fur root

/home Homes fur User

/home/csaXXXX

/home/c703xxx

Linux Introduction: Part 1 14

Page 16: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Verzeichnisstruktur II

Root

/lib ‘Shared Libraries’ fur dynamisch gelinkte

Programme des Betriebssystems

/mnt Verzeichnisse mit Mount Points

/media

/usr (unix system ressources), Anwendungen,

Manpages, alles wichtige fur einen User

/usr/bin , /usr/lib ...

/opt meist kommerzielle Software

/proc Prozess-‘Dateisystem’. stellt Kernel-

informationen in Form von Dateien dar.

/sbin Systemprogramme, die mehr Rechte zum Ausfuhren

benotigen

Linux Introduction: Part 1 15

Page 17: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Verzeichnisstruktur III

LPCCS spezifisch

/usr/site . . . Universitätsweit zugängliche Programme

/scratch/cXXX/cXXXXXX . . . Platz für temporäre Dateien und zumDatenaustausch (Unix–Rechtevergabe)

/scratch/.snapshot . . . Stündliches Backup von /scratch/home/cXXXXXX . . . Home$HOME/.snapshot . . . Backup/share/cXXX/cXXXXXX . . . Share–Verzeichnis

Linux Introduction: Part 1 16

Page 18: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Die Shell: Entwicklung

sh

csh

ksh

tcsh

bash

Syntax &Semantik

Funktionalität

Das Bild zeigt eine schematische Entwicklung beginnend bei der Bourne–Shell(/bin/sh) (Ende der 70er Jahre) bis zur Bourne–Again–Shell (/bin/bash)Anfang der 90er.POSIX (Portable Operating System Interface): bietet eine standardisierteSchnittstelle zwischen Applikationen und Betriebssystem.

Linux Introduction: Part 1 17

Page 19: Linux Introduction: Part 1 - Universität Innsbruck · 2018-09-03 · GNU/Linux – Einleitung Unix–Design–Paradigmen • Everything is a file • One tool for one job • Multiuser

Manpages und Infoseiten

• $ man Befehl . . . liefert die Manpage

• $ man -k Suchbegriff . . . sucht nach dem Wort in Manpages (alternativ $

apropos)

• $ info Befehl

• in /usr/share/doc . . . finden sich Paket- u. Distributions spezisfischeDokumentation zu Programmen

LPCCS spezifisch

• http://www.uibk.ac.at/zid/systeme/linux

• Linux–User mailing list: http://lists.uibk.ac.at

Linux Introduction: Part 1 18