School on Digital Radio Communications for...

48
Linux Overview Marx Jerez [email protected] Alejandro Gonzalez [email protected] Gilberto Diaz [email protected] Los Andes University - Fundacite Mérida - Venezuela School on Digital Radio Communications for Research and Training in Developing Countries - Febreary 2004

Transcript of School on Digital Radio Communications for...

Linux OverviewMarx Jerez [email protected]

Alejandro Gonzalez [email protected] Diaz [email protected]

Los Andes University - FundaciteMérida - Venezuela

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Until now, according to the networking world, we havestudied the details of the layer 1 of OSI model (physic layer)

One of ours aims is create an infrastructure to exchageinformation

In order to satisfy this, we need some network service, but before we need use a good platform to do it.

What is Linux?

Linux is the core of a operating system, the so called “kernel”. It executes the applications and interacts withthe hardware. It was written in 1991 by Linus Torvalds butnow include code of thousand of programmers around theworld.

This kernel is combined with many others applications andtools that all together form the operating system knownas Linux o GNU/Linux

http://www.lugatgt.org/articles/overview/

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

What are Distributions?

Currently, there are a lot of applications and programs to do different tasks and they are dedicated to satisfy differentpurposes: image processing, editors, communications, network services, etc.

Companies like Red Hat, Slackware, SUSE, Debian, etc.collect their own set of applications, modify the kerneland build an installation program.

This compilation of applications, kernels and installers are called distribution.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

GPL

Gnu Public License: This license establish that any software developed under it can be used in any way, modified andcopied. But, you can not claim falsely that you wrote theentire application, and any change that you do must beshared with the community.

Linux kernel and it application is under GPL.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Who owns and control Linux?

There is not a single entity in charge of Linux or owns it.This is by and for hobbyists, hackers, and professionals worldwide. However, Linus does own the name, "Linux"

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Why use Linux in wireless networks?

§ Stable operating system

§ Best cost – effective solution for: routers, AP, firewall, monitoring station, etc.

§ Easy remote administration and is not heavy to do it troughthe network

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Linux Structure

Hardware

Kernel

Shells

Applications

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

The Kernel

1. Is the part of the O.S that interacts directly with the hardware.

2. Its main function is:- Memory management.- Computer access control.- Maintenance the file systems, interrupts management.- Error and IO services management. .

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

End of quantum- Time sharing

The Kernel

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

- Multitasking- Multiuser- Almost completely written in C.- TCP/IP- POSIX.

The Kernel

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

The Shell

1. Is the interface between the user and the O.S.2. Command interpreter.3. Read instructions and interpret them as programs

execution.. 4. Has its own program language.5. Controls how and when the instructions are

executed..

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

The Shell

§ sh UNIX standard shell (Bourne shell).

§ bash GNU Version of the standard shell.§ csh California shell.§ jsh Job shell (sh extension)§ ksh Korn shell.§ tcsh Improved version of csh.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Applicatins and Services

- Telnet, ssh - Firewalls- FTP - Router- NIS - DHCP- NFS - Print server- DNS - Communication server- WEB - O.S server- Data Bases - E-mail server - etc.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Installation, Booting andStopping Linux

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Slackware 9.1 Installation First prompt: some special parameters§ Keyboards selection§ Login as root§ Disk partitions (fdisk)§ Setup menu§ Source installation selection§ Target installation selection (what partition)§ Packages selection§ Format partition (whether or not check)§ File system type selection§ Inode size

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Partition information:

- Swap partition (type 82) = at least same RAM size.- Linux native (type 83) = All available space in disk.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

- Load the kernel- Hardware check. Devices detection and creation- Start system processes.

- init process /etc/inittab

- File systems check- Mount file systems

Boot process

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Init Configuration file "inittab"

id:3:initdefault:

#System initializationsi::sysinit:/etc/rc.d/rc.sysinit

.

.l3:3:wait:/etc/rc.d/rc 3

.

.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Boot process

Comando shutdownReinicio, detención o tareas administrativas de bajo nivel

- Envio de señal SIGTERM a los procesos.

- Bloqueo de login.

- Ejecución del procesos init en nivel 0. desmontaje de sistemas de archivos.

School on Digital Radio Communications for Research and Training in Developing Countries -

Febreary 2004

Stopping the system

Linux Basic Commands

School on Digital Radio Communications for Research and Training in Developing Countries

Febreary 2004

Files management

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

hawee jose

graphics management

Reportgraphics1

manual

ls

rm graphics

lpr grafico1

cp graphics graphics/graphics

more report

cat report

tail report

mv report management/

wc report

Files management

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

§ Exercise(1):§ Run the following commands:§ ls§ ls -l§ ls -a§ ls -la§ What do you look at in each command?§ more report.txt§ cat report.txt§ less report.txt§ tail report.txt

Files management

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

§ Exercise (2):§ Run the following commands:§ cp report.txt report.txt.old§ mv report.txt.old report.txt.orig§ ls -a§ ls -la§ What do you look at in each command?§ more report.txt§ cat report.txt§ less report.txt§ tail report.txt tail –l 15 report.txt

Files management

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

§ Exercise (3):§ Run the following commands:§ gzip report.txt§ gunzip report.txt.gz

§ wc report.txt§ diff report.txt report.txt.changed

Basic Unix Command

School on Digital Radio Communications for Research and Training in Developing Countries

Febreary 2004

Directory management

pwdmkdir graphicscd graphicscd ..rmdir graphics

home

luis

graphics

report

Search

find / -name .login -print

Directory management

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

§ Exercise(1):§ Run the following commands:§ cd Return tu your local home § mkdir mydirectory§ cd mydirectory§ cp ../report.txt ./mydirectory§ cd ..§ rmdir mydirectory§ Does it work?§ rm -rf mydirectory

Directory management

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

§ Exercise(1):§ Run the following commands:§ cd Return tu your local home § mkdir mydirectory§ cd mydirectory§ cp ../report.txt ./mydirectory§ cd ..§ rmdir mydirectory§ Does it work?§ rm -rf mydirectory

Finding things

School on Digital Radio Communications for Research and Training in Developing Countries

Febrary 2004

• grep, egrep, fgrep -- print lines matching a patternExample:grep string filename(s) • find -- search for files in a directory hierarchyExamplefind / -name “report.txt” –print• Locate -- Index and quickly search for files on your systemExample:locate httpd

About other people

School on Digital Radio Communications for Research and Training in Developing Countries

Febreary 2004

w -- Show who is logged on and what they are doing.who -- show who is logged onfinger username -- user information lookup programlast -1 username-- show listing of last logged in userstalk username -- talk to another userwrite username -- send a message to another user

About yourself

School on Digital Radio Communications for Research and Training in Developing Countries

Febreary 2004

whoami --- print effective useridfinger--- user information lookup programpasswd --- update a user's authentication tokens(s)ps -u yourusername --- report process statuskill PID --- terminate a processquota -v --- terminate a process

du filename --- estimate file space usagelast yourusername --- show listing of last logged in users

Miscellaneous tools

School on Digital Radio Communications for Research and Training in Developing Countries

Febreary 2004

cal --- print calendardate --- print or set the system date and time man --- manual pages about commands