[PDF] Linux for Beginners 20-Oct-2021 1 General





Previous PDF Next PDF



Introduction to Linux Operating System

Numbering of the kernel versions – see lab notes or Wikipedia. 7. Linus Torvalds announcing. Linux 1.0. 30.03.1994. Richard Stallman



Linux Programming Notes

Source software development very popular in universities and Free Operating System companies



THE LINUX OPERATING SYSTEM

The mb() operation provides both a load and store barrier. Two important points to note about the barrier operations: 1. The barriers relate to machine 



Unit 10 : An Introduction to Linux OS Unit 10 : An Introduction to Linux OS

Users on the Linux operating system work consistently with the Linux server Note the functions of Shell. c. List the Linux utilities and application ...



AMD Catalyst™ Graphics Driver Installer Notes for Linux® Operating AMD Catalyst™ Graphics Driver Installer Notes for Linux® Operating

31-Aug-2015 conf file before installing your driver package in case you need to restore your system to the state just before your last package installation.



DIGITAL NOTES ON LINUX PROGRAMMING B.TECH III- YEAR – I

Files and Directories- File Concept File types



Linux for Beginners

1 General remarks on the operating system UNIX/Linux. 2 First steps at the Note: Varying from system to system rm without the option -f might need a ...



INTRODUCTION TO LINUX OPERATING SYSTEM INTRODUCTION TO LINUX OPERATING SYSTEM

LINUX OPERATING SYSTEM. Linux operating system consists of Kernel Shell and File System: ➢Shell Types. ➢Bourne Shell (sh) (First shell by Stephen Bourne).



Linux with Operating System Concepts

notes early drafts of this textbook





LINUX PROGRAMMING

Linux is a Unix-like computer operating system assembled under the model Please note that /root is root user's home directory which is not same as /.



Introduction to Linux Operating System

Operating System is a program that mediates between the user and the computer hardware. Numbering of the kernel versions – see lab notes or Wikipedia.



Linux for Beginners

20-Oct-2021 1 General remarks on the operating system UNIX/Linux ... reference for vi: vi reference.pdf. • reference for emacs: emacs reference.pdf.



Introduction to Linux

This guide was created as an overview of the Linux Operating System http://www.tldp.org/guides.html; you can also download PDF and PostScript formatted ...



DIGITAL NOTES ON LINUX PROGRAMMING B.TECH III- YEAR – I

Files and Directories- File Concept File types



Installing and Configuring Linux Guest Operating Systems

This technical note describes installing configuring



Notes on Linux operating system

09-Jan-2007 I often give files Windows-like extensions (like .txt .pdf



OPERATING SYSTEMS Lecture Notes

systems (including virtually all versions of UNIX Linux



AMD Catalyst™ Graphics Driver Installer Notes for Linux® Operating

31-Aug-2015 software to remove the AMD. Catalyst™ proprietary driver. In order to restore the system to the previous state before the last installation the ...



THE LINUX OPERATING SYSTEM

Operating Systems: Internals and Design Principles Fifth Edition 6.8 LINUX KERNEL CONCURRENCY MECHANISMS. ... Note that this function.



[PDF] LINUX PROGRAMMING - IARE

Linux is a Unix-like computer operating system assembled under the model of free and open source software development and distribution The defining component 



[PDF] Unit 10 : An Introduction to Linux OS

Linux is a true 32/64-bit operating system that run on different platforms It is a multi-user multi-tasking and time sharing operating system



[PDF] Introduction to Linux Operating System - students

30 mar 1994 · Operating System is a program that mediates between the user and the computer hardware • Hides hardware details of the computer system by 



[PDF] Linux for Beginners

The operating system Linux and programming languages An introduction Joachim Puls and Michael Wegner Contents: 1 General remarks on the operating system 



[PDF] Operating Systems (Linux)

A brief introduction to Linux Where is Linux headed? Questions? Page 4 My experiences with Linux Started with a 



[PDF] DIGITAL NOTES ON LINUX PROGRAMMING BTECH III- YEAR

(R15A0527)LINUX PROGRAMMING Objectives: • To develop the skills necessary for Unix systems programming including file system



[PDF] INTRODUCTION TO LINUX OPERATING SYSTEM - CERN TWiki

?Linux treats everything as a file including hardware devices Arranged as a directory hierarchy ?The top level directory is known as “root (/)”



[PDF] Linux-Tutorialpdf

There are online manual pages that tell you what options a particular command can take and how each option modifies the behaviour of the command



[PDF] Introduction to Linux

This guide was created as an overview of the Linux Operating System http://www tldp org/guides html; you can also download PDF and PostScript formatted 



[PDF] [PDF] Introduction to Linux

Other useful commands to find out more: ? Several built-in references are available within the operating system • info more detailed tutorials and examples

  • What is Linux operating system notes?

    Linux® is an open source operating system (OS). An operating system is the software that directly manages a system's hardware and resources, like CPU, memory, and storage. The OS sits between applications and hardware and makes the connections between all of your software and the physical resources that do the work.
  • What are the 3 main parts of Linux operating system?

    In general, the Linux operating system is made up of three parts; the kernel, the shell, and the programs.
  • How to learn Linux operating system?

    How to Learn Linux: Understanding the Basics

    1Find solid resources and learning matieral.2Learn and practice the basics.3Spend time exploring the OS.4Start a project and put your knowledge into practice.5Keep practicing to refine your skills and learn more.
  • An operating system is a type of system software that manages and controls the resources and computing capability of a computer or a computer network, and provides users a logical interface for accessing the physical computer to execute applications.

The operating system Linux

and programming languages

An introduction

Joachim Puls and Michael Wegner

Contents:

1 General remarks on the operating system UNIX/Linux 2

First steps at the computer

3

File systems

4

Editing and printing text files

More important commands

5

UNIX-shells

6

Process administration

7

The programming language C++ - an overview

8

Fortran 90/95 - an overview

9

Creating executable programsAdditional material

•vibasics: vi brief.pdf •reference forvi: vi reference.pdf •reference foremacs: emacs reference.pdf

Acknowledgements. Many thanks to Tadziu Hoff-

mann for carefully reading the manuscript and useful comments. c ?2010, Joachim Puls & Michael Wegner (1st ed.)

1 General remarks on the operat-

ing system UNIX/Linux

Classification of UNIX/Linux

UNIX is aMulti-User/Multi-Tasking operating system and exists in many different versions ("derivates"):

Solaris, AIX, XENIX, HP-UX, SINIX,Linux.

application programsOperating systemHardwareUser

Operating system (OS): Sum of all programs which

arerequired to operate a computerand which control and monitor the application programs. 1

Essential features

UNIX

•has been originally written in the programminglanguage C, and is therefore a classical platformfor C-programs. UNIX contains well suited en-vironments for program development (C, C++,Java, Fortran, ...).

•is mainly used for scientific-technical applicationson mainframes and workstations, but has be-come, because ofLinux, also popular for classical

PC-applications throughout the last years.

•is perfectly suited for application in networks.Larger systems and networks require an admin-istrator.

•offers various alternatives for the solution of mosttasks. The multitude of commands (more thanin any other OS) are brief and flexible.

•is originally command-line oriented, but can beused via a graphical user interface (X Window system). Linuxis available (also via internet) in differentdis- tributions(S.u.S.E., Fedora, Debian etc.). Mean- while there is a variety ofdirect-start (live) systems, which can be started, without installation, directly from CD or other bootable storage devices (Knop- pix, Ubuntu, . . . ). There are also interesting "mini versions" (<100 MB) designed for a start from USB- sticks (e.g., Puppy). The source code of Linux is free. 2

Literature

•Peek, J., et al.:Unix Power Tools.

O"Reilly Media 2002 (3rd edition).

•Gilly, D., et al.:UNIX in a Nutshell.

O"Reilly, K¨oln. 1998 (1st edition).

•Wielsch,M.:Das große Buch zu UNIX.

Data Becker, D¨usseldorf. 1994 (1st edition).

•and numerous other text books •online-tutorial http://www.ee.surrey.ac.uk/Teaching/Unix 3

2 First steps at the computer

User, logon, logoff

Since UNIX is amulti-useroperating system, it can

deal with several users simultaneously. Each user needs auser account.

Each user has a personal environment (home di-

rectory, shell), which can be accessed only by her- /himself (and by the system adminstrator and those people who know the password - legitimate or by hacking). Inside the system the user is identified by hisuser ID (UID) and his group identity (group ID, GID).

There are two user types:

•'normal" users withrestrictedrights and the •system administrator (root) with all privileges. The latter is responsible for the installation, con- figuration and maintenance of the system as well as the user administration. Each user has to logon and to logoff from the system (login/logout). Each user account is protected by a password.

Exercise:

Login to the system with your user account!

4 Graphical user interfaceOriginally, UNIX is command-line oriented. TheX

Window systemenables convenient interaction via a

window-oriented graphical interface, similar to other OS.

Thewindow manageris responsible for the manage-

ment and display of the individual windows. Each window manager (and there are a variety of such man- agers) can be distinguished by its ownLook and Feel (appearance of window decorations and control de- vices etc.). Most window managers can be choosen at the login-menu.

Examples for simple window managers:

•twm: very simple and resource-saving •mwm: Motif window manager, more common and more advanced •xfce: convenient, simple, and resource-saving (recommended for use in virtual machines)

Moreover, almost all Linux distributions provide

graphicaldesktop environmentssuch asKDEor GNOME, which have a functionality far beyond simple window managers. 5 command xterm

Syntax:

xterm [options]

Though there is a graphical interface, UNIX needs

the possibility for direct command input for practical use. Therefore, at least one terminal window needs to be open. This can be accomplished via the window manager or the desktop environment ('console")

More windows can then be opened with the command

xterm.

Generally, all UNIX commands have a variety ofop-

tions, which usually begin with-. For the commands which will be introduced in the following, we will pro- vide only the most important ones.

Example:

wegner@arber:~ > xterm -geo 80x40 -fn 10x20

The commandxtermis called with two options-geo,

-fn, which, in this case, need additionalarguments (width and height of window, font name & size).

Exercise:

1. Open a terminal window ("terminal program") via KDE.

2. From there, start anotherxterm!

6 command man

Syntax:

man command man -k expression displays the manual pages ("man pages") for the pro- videdcommand.man -ksearches for man pages contain- ing theexpressionin theNAMEsection. A man page usually consists of the following sections •NAMEcommand and purpose •SYNOPSISsyntax of command •DESCRIPTIONof command effect •FILESwhich are modified and/or needed •OPTIONSif present •EXAMPLE(S)for application (rarely) •BUGSerrors, if known •SEE ALSOother commands in the same context

Exercise:

Display information about the commandxterm!

7 command passwd

Syntax:

passwd sets a new password. Passwords should be constructed from a combination of letters, digits and special characters, and should not appear in any dictionary or similar list. Otherwise, the password can be hacked by systematic search al- gorithms.

The command to set/change the password and

the required conventions (length, number of dig- its/letters/special characters) can vary from system to system. The following example is a common one, e.g., valid for the workstations at the CIP Pool (but not for the workstations of the USM).

Example:

wegner@arber:~ > passwd

Changing password for wegner

Old password:

myoldpasswd

Enter the new password

(minimum of 5, maximum of 8 characters)

Please use a combination

of upper and lower case letters and numbers.

New password:

mynewpasswd

Re-enter new password:

mynewpasswd

Password changed.

8

Example:

----> Ihr neues Passwort ist in 5 Minuten im gesamten Pool aktiv! <-----

Connection to 141.84.136.1 closed.

wegner@arber:~ > 9 command who, whoami

Syntax:

who whoami whodisplays information about all users which are logged into the system •user name, •terminal where the corresponding user is working, •time of login. whoamiis self-explanatory.

Example:

wegner@arber:~ > whoami arber!wegner pts/5 Oct 20 12:45 10

Working at external terminalsTo login to a distant host, one has to provide thecorresponding IP address, either numerical or as thecomplete host namename.domain. In local networks

(CIP-Pool), the brief host name (without domain) is sufficient. To establish the connection and to encrypt the transmitted data, one should use exclusively the so-called "secure" commands. Avoidftpand usesftp instead. Withftp, even the password isnotencoded! command ssh

Syntax:

ssh (-4) -X -l username hostname ssh (-4) -X username@hostname Enables logging in to an arbitrary host which can be located via an IP address (if one knows the user ac- count and the password). Logoff withexit,Ctrl-Dor logout.

In case, the option-4(without brackets) forces an

IPv4 connection (if IPv6 is not working)

Example:

wegner@arber:~ > ssh -X -l wegner lxsrv1.lrz-muenchen.de

Password:

mypasswd

Last login: Sun Oct 22 ...

Mitteilungen

wegner@lxsrv1:~ > logout

Connection to lxsrv1.lrz-muenchen.de closed.

11

OR (if connection within "own" cluster)

Example:

wegner@arber:~ > ssh -X wegner@arber

Last login: Sun Oct 22 ...

etc. (keine Passwort-Abfrage)

An additional advantage of thesecure shellis that

the distant hosthostnamecan display X applications on the local terminal, without requiring the command xhost(as in earlier times). For certain hosts, the com- mandsshrequires the option-Xto enable this feature. command scp To copy files from one host to another, the command scp("secure copy") is used, see alsocp.

Syntax:

scp (-4) file1 username@hostname:file2 scp (-4) username@hostname:file1 file2 The first command copies the local filefile1to the external host under namefile2, the second command vice versa. Note the colon!scp -renables to copy complete directoriesrecursively, comparecp -r. 12

3 File systemsLogics, file types"In UNIX everything is a file."The followingfile-system objectscan be found

•'normal" (text-) files •executable files (binary files orshell scripts) •directories •device files •pipes •symbolic or hardlinks(references to files) All files and file system objects are ordered within a hierarchicalfile treewith exactly oneroot directory

In contrast to the MS-Windows file system, the

UNIX file system does not distinguish between dif- ferent drives. All physical devices (hard disks, DVD,

CDROM, USB, floppy) are denoted by specific files

inside a certain directory within the file tree (usually within/dev). File names consist of a sequence of letters, digits and certain special characters, and must not contain slashes(for convenience, they should neither contain empty spaces). 13 Avoid characters which might be interpreted by the shellin a special way. A file can be referenced within the file tree by either anabsoluteor arelative path name. An absolute path name consists of all directories leading to the file and the file name, and always begins with a/(the root directory). In many shells and application programs, the tilde de- notes the home directory. command pwd

Syntax:

pwd displays the current directory.

Example:

wegner@arber:~ > pwd /home/wegner wegner@arber:~ >

Exercise:

Display the current directory!

14 command cd

Syntax:

cd [directory] Changes into the given directory, or into the home directory when no parameter is provided.

As in MS-DOS/Windows, ".." denotes the parent

and "." the current directory.

Example:

wegner@arber:~ > cd /home/puls wegner@arber:/home/puls > pwd /home/puls wegner@arber:/home/puls > cd .. wegner@arber:/home > pwd /home wegner@arber:/home > cd wegner@arber:~ > pwd /home/wegner wegner@arber:~ >

Exercise:

Change to the directory/usr/share/templatesand back to your home directory! (→file name completion withTAB)

Check for successful change withpwd!

15

Search pattern for file names

In principle, theshellis a specific program which deals with the interpretation of input commands. If these commands have parameters which are file names, sev- eral files can be addressed simultaneously by means of a search pattern, which isexpandedby the shell. In any case, the file name expansion is performedprior to the execution of the command.expression meaning 'almost" arbitrary (incl. empty) stringof characters asingle'almost" arbitrary character a range of characters a negated range of characters 'almost" arbitrary: leading dot (e.g., hidden files,../ etc.) excluded command ls

Syntax:

ls [-alR] [file/directory] displays the names (and, optionally, the properties) of files or lists the content of a directory. File and directory names can be be absolute or relative. 16

Important options

-alist also files/directories which begin with a dot(hidden) -llong listing format. Displays permissions, userand group, time stamp, size, etc. -Rfor directories, all sub-directories will be displayedrecursively.

Example:

wegner@arber:~ > ls hello* hello.cpp hello.f90 nsmail/ wegner@arber:~ > ls -a ./ .bash_history .netscape/ hello.cpp ../ .bashrc* .ssh/ hello.f90 .Xauthority .history hello* nsmail/ wegner@arber:~ > ls /var/X11R6 app-defaults/ bin/ lib@ sax/ scores/ xfine/ xkb/ wegner@arber:~ > ls .b* .bash_history .bashrc* wegner@arber:~ > ls [a-h]* hello* hello.cpp hello.f90 wegner@arber:~ > ls *.?[9p]? hello.cpp hello.f90 wegner@arber:~ >

Exercise:

List the complete content of your home directory!

What is displayed withls .*?

17

Copy, move and delete files/directories

In addition tolsthere are other commands for working with files which can be used together with file name patterns. command mkdir, rmdir

Syntax:

mkdir directory rmdir directory mkdircreates an empty directory,rmdirdeletes anquotesdbs_dbs20.pdfusesText_26
[PDF] linux rust

[PDF] linux scanner drivers

[PDF] linux tshark tutorial

[PDF] linux written in rust

[PDF] lionsgate films management

[PDF] lipid ncert

[PDF] lipolysis

[PDF] lipschitz condition differential equation

[PDF] lipschitz condition solved examples

[PDF] liquid density experiment

[PDF] liquid dmg benefits for autism

[PDF] liquid hand sanitizer dispenser

[PDF] liquidity regulation

[PDF] liquidity reporting

[PDF] liquidity risk metrics