SlideShare une entreprise Scribd logo
1  sur  118
Linux
Presentation By
Mayur Verma
MCA 3rd sem
• History and installation of Linux
• Installation and some Feature
• Applications of Red Hat
• Commands
• C programing in shell
• Shell Programing with Vi/G Edit
• Scheduling of Linux
• Memory Management
• Interrupts and Exception
• Interrupts Handling
• Networking
• Samba Configuration
Overview
Why we use LINUX
Linux is free of charge .
Linux is more secured than any other server and computer
It has a wide compatibility to several hardware
Easy to Operate
It comes inclusive of drivers
Smooth and easy Updating Process
Linux has a community support
Less memory use
• In 80’s, Microsoft’s DOS was the dominated OS
for PC
• Apple MAC was better, but expensive
• UNIX was much better, but much, much more
expensive. Only for minicomputer for
commercial applications
• People was looking for a UNIX based system,
which is cheaper and can run on PC
• Both DOS, MAC and UNIX were proprietary,
i.e., the source code of their kernel is protected
• No modification is possible without paying high
license fees
Before Linux
All modern operating systems have their roots in 1969 when Dennis
Ritchie and Ken Thompson developed the C language and the Unix
operating system at AT&T Bell Labs. They shared their source code (yes,
there was open source back in the Seventies) with the rest of the world,
including the hippies in Berkeley California. By 1975, when AT&T started
selling Unix commercially, about half of the source code was written by
others.
In 1969
In 1980
In the Eighties many companies started developing their own Unix: IBM created AIX , Sun
SunOS (later Solaris), HP HP-UX and about a dozen other companies did the same. The
result was a mess of Unix dialects and a dozen different ways to do the same thing. And
here is the first real root of Linux , when Richard Stallman aimed to end this era of Unix
separation and everybody re-inventing the wheel by starting the GNU project (GNU is Not
Unix). His goal was to make an operating system that was freely available to everyone, and
where everyone could work together (like in the Seventies). Many of the command line
tools that you use today on Linux are GNU tools.
• A famous professor Andrew Tanenbaum developed Minix, a
simplified version of UNIX that runs on PC
• Minix is for class teaching only. No intention for commercial use
• In Sept 1991, Linus Torvalds, a second year student of
Computer Science at the University of Helsinki, developed the
preliminary kernel of Linux, known as Linux version 0.0.1.
• He put the source code online, thinking it would never support
anything but 386 hardware. Many people embraced the
combination of this kernel with the GNU tools, and the rest, as
they say, is history.
In 1990’s
GNU project
Established in 1984 by Richard Stallman, who believes that software
should be free from restrictions against copying or modification in
order to make better and efficient computer programs
Today more than 97 percent of the world's supercomputers (including
the complete top 10),more than 80 percent of all smartphones, many
millions of desktop computers, around 70 percent of all web servers, a
large chunk of tablet computers, and several appliances (dvd-players,
washing machines, dsl modems, routers, self-driving cars, space
station laptops...)run Linux . Linux is by far the most commonly used
operating system in the world. Linux kernel version 4.0 was released in
April 2015. Its source code grew by several hundred thousand lines
(compared to version 3.19 from February 2015) thanks to
contributions of thousands of developers paid by hundreds of
commercial companies including Red Hat, Intel, Samsung, Broadcom,
Texas Instruments, IBM, Novell, Qualcomm, Nokia, Oracle, Google,
AMD and even Microsoft (and many more).
In 2015
Today more than 97 percent of
the world's supercomputers
(including the complete top
10),more than 80 percent of all
smartphones, many millions of
desktop computers, around 70
percent of all web servers, a
large chunk of tablet
computers, and several
appliances (dvd-players,
washing machines, dsl modems,
routers, self-driving cars, space
station laptops...)run Linux
Growing and growing…
Linux: No of Users
138712 155679
users registered machines registered
Free software, as defined by the FSF (Free Software Foundation), is
a "matter of liberty, not price." To qualify as free software by FSF
standards, you must be able to:
• Run the program for any purpose you want to, rather than be restricted in what
you can use it for.
• View the program's source code.
• Study the program's source code and modify it if you need to.
• Share the program with others.
• Improve the program and release those improvements so that others can use
them.
Linux - free software
Installing Red Hat
Applications
Red Hat Enterprise Linux includes several text editors, applications that allow you to view and
modify plain text files. Plain text files are files that contain text without any font or style
formatting applied to it, such as system logs and configuration files.
To start gedit, click Main Menu =>
Accessories => Text Editor.
You can also start gedit by typing
gedit at a shell prompt.
Editing Text File (gedit)
If you are not using a graphical desktop and want to read and modify a text or configuration file,
Red Hat Enterprise Linux includes the vi (pronounced vee-eye) text editor. vi is a simple
application that opens within the shell prompt and allows you to view, search, and modify text
files. To start vi, type vi at a shell prompt. To open a file with vi type vi <filename> at a shell
prompt.
Shell Prompt Text Editor
A PDF (Portable Document Format) file is an electronic image of a document. An open source
application called xpdf is included with Red Hat Enterprise Linux. The xpdf toolbar at the bottom
has navigational tools that let you move backward and forward through the PDF document, as
well as standard zoom, print, and find tools. The xpdf man page provides useful information on
the xpdf options. To view the xpdf man page, at a shell prompt type man xpdf
To view a PDF with xpdf:
In your desktop environment, go to Main Menu => Graphics => PDF Viewer. You can also launch
xpdf by typing xpdf at a shell prompt.
Right-click in the xpdf screen to display a list of options.
Select Open to display the file browser.
Select the PDF file you want to view and click Open.
Viewing PDFs
Playing Audio CDs
To play an audio CD, place the CD in your CD-ROM drive. The CD Player application should
appear automatically and begin playing the first audio track. If the interface does not appear,
click Main Menu => Sound & Video => CD Player to launch the CD Player application.
Audio, Video, and General
Amusement
Playing Digital Audio Files
Digital audio has become very popular in recent years. Users enjoy the technology because the
sound quality is excellent compared to analog tape or records, and the files are compact (audio
files can easily be transferred across the Internet).
To take advantage of this technology, Red Hat Enterprise Linux includes the powerful X
Multimedia System (XMMS), a cross-platform multimedia player which allows you to play
several digital audio file formats.
XMMS Interface
XMMS can be used for more than just playing digital audio files. By default XMMS can play Ogg
Vorbis, RIFF wave, and most module formats. Additionally, XMMS can be extended via plugins to
play a number of other digital multimedia formats.
To launch XMMS, go to Main Menu => Sound & Video => Audio Player.
To launch XMMS from a shell prompt, type the command xmms
Applications
Troubleshooting Your Sound Card
If, for some reason, you do not hear sound and know that you do have a sound card installed,
you can run the Sound Card Configuration Tool utility.
To use the Sound Card Configuration Tool, choose Main Menu => System Settings => Soundcard
Detection. A small text box pops up prompting you for your root password.
The Sound Card Configuration Tool utility probes your system for sound cards. If the utility
detects a plug and play sound card, it automatically tries to configure the correct settings for
your card. You can then click the Play test sound button to play a sound sample. If you can hear
the sample, select OK and your sound card configuration is complete.
If the Sound Card Configuration Tool does not work then you can edit your modules.conf file.
You can manually edit your /etc/modules.conf file to include the sound card module that it
should use
Manual Sound Card
Configuration
Video card configuration is handled during the Red Hat Enterprise Linux installation . However, if
you did not choose to configure a video card at that time, or if you need to reconfigure your
settings, you can use the X Configuration Tool utility.
To run the X Configuration Tool, click Main Menu => System Settings => Display. A pop-up
window prompts you for your root password. You can also start from a shell prompt by typing
the command redhat-config-xfree86, which then prompts you to enter your root password. If
you are working from a shell prompt and X is not working, redhat-config-xfree86 attempts to
start a minimal X session to allow you to continue your configuration. Follow the instructions
that appear on the screen. The X Configuration Tool attempts to automatically configure your
video card and monitor settings for you.
Troubleshooting your
video card
X Configuration Tool
To configure your monitor manually, click the Advanced tab, then click the Configure... button
next to the Monitor Type entry. A pop-up window displays a list of monitor models. Choose your
model and click OK. You can also let the X Configuration Tool probe your monitor for the correct
model and vertical/horizontal frequency settings.
To configure your video card manually, click the Advanced tab, then click the Configure... button
next to the Video Card entry. A pop-up window displays a list of video card models. Choose your
model and click OK. You can also let the X Configuration Tool probe your video card for the
correct model and settings by clicking the Probe Videocard button.
When you have finished reconfiguring your video card and monitor, you should be able to start
an X session and enjoy your graphical desktop environment.
Game availability depends on the variant of Red Hat Enterprise Linux you installed. You must
have those game packages installed before they appear under the Main Menu => Games menu.
Refer to the Red Hat Enterprise Linux System Administration Guide for details on installing
additional packages.
Games
Red Hat Enterprise Linux supports over 100 digital camera models. So, whether your camera
uses a USB or serial port to communicate with your computer, it is likely that Red Hat Enterprise
Linux supports it.
gtKam is a graphical application that allows you to interface with your digital camera. gtKam
works directly with your digital camera, allowing you to open, view, save, and delete images
directly
To start gtKam, choose Main Menu => Graphics => Digital Camera Tool. You can also start
gtKam by typing gtkam at a shell prompt.
Before you begin using gtKam, you need to configure it to work with your digital camera. From
the menu, choose Camera => Add Camera.... From the pop-up dialog, you can choose your
camera from the drop-down list or let gtKam automatically find your camera by clicking Detect.
Click Apply to accept the changes and OK to close the dialog box.
Using gtKam
Adding a Camera in gtKam
Once you have added your camera, it will be shown as an icon on the left panel of the main
gtKam window. You only have to configure gtKam for your camera once; the settings will be
saved with each additional use.
Directories shown below the icon may differ depending on your brand of camera. Select the
directory that commonly stores your images and the stored images will immediately load as
thumbnail images in the main panel. From this panel,
click on the images you want, which you can
then save to disk by choosing File =>
Save Selected Photos. If you want to
save all of the stored images, choose
Select => All, then save the images to disk.
Directories: File and directory paths in UNIX use the forward slash "/" to separate
directory names in a path.
examples:
/ "root" directory
/usr directory usr (sub-directory of / "root" directory)
/usr/STRIM100 STRIM100 is a subdirectory of /usr
Moving around the file system:
pwd Show the "present working directory", or current directory.
cd Change current directory to your HOME directory.
cd .. Change current directory to the parent directory of the current
directory.
Linux Command
Listing directory contents:
ls : list a directory
ls -l : list a directory in long ( detailed ) format for example:
ls –a : List the current directory including hidden files. Hidden files start with "."
Manipulating files
Vi text editor
By far, the most useful and powerful thing you can do with I/O redirection is to connect multiple
commands together with what are called pipes(|). With pipes, the standard output of one
command is fed into the standard input of another. Here is my absolute favorite:
[me@linuxbox me]$ ls -l | less
In this example, the output of the ls command is fed into less. By using this "| less" trick, you can
make any command have scrolling output. I use this technique all the time.
Pipes
Commands that let you determine what is going on with your system.
pwd
Print working directory, i.e., display the name of my current directory on the screen.
hostname
Print the name of the local host (the machine on which I am working). Use netconf (as root) to
change the name of the machine.
whoami
Print my login name.
id username
Print user id (uid) and his/her group id (gid), effective id (if different than the real id) and the
supplementary groups.
date
Print the operating system current date, time and timezone. For an ISO standard format, I have
to use date -Iseconds.
Some Commands
who
Determine the users logged on the machine.
w
Determine who is logged on the system, find out what they are doing, their processor ussage,
etc. Handy security command.
rwho -a
(=remote who) Determine users logged on other computers on your network. The rwho service
must be enabled for this command to run. If it isn't, run setup (RedHat specific) as root to
enable "rwho".
finger user_name
System info about a user. Try: finger root . One can use finger with any networked computer that
exposes the finger service to the world, e.g., I can do (try): finger @finger.kernel.org
last
Show listing of users last logged-in on your system. Really good idea to check it from time to
time as a security measure on your system.
lastb
("=last bad") Show the last bad (unsuccessful) login attempts on my system.
Some Commands
history | more
Show the last (1000 or so) commands executed from the command line on the current account.
The "| more" causes the display to stop after each screen-full. To see what another user was
doing on your system, login as "root" and inspect his/her "history".
comman
Run the most recent command from my bash history commands that starts with the string
"comman". This is usefull for re-running often the same, command which may be complicated
to type.
uptime
Show the amount of time since the last reboot.
ps
(="print status" or "process status") List the processes currently run by the current user.
Some Commands
free
Memory info (in kilobytes). "Shared" memory is the memory that can be shared between
processes (e.g., executable code is "shared").
df -h
(=disk free) Print disk info about all the filesystems (in human-readable form).
du / -bh | more
(=disk usage) Print detailed disk usage for each subdirectory starting at the "/" (root) directory
(in human legible form).
cat /proc/cpuinfo
Cpu info - shows the content of the file cpuinfo. Note that the files in the /proc directory are no
real files - they are hooks to look at information available to the kernel.
cat /proc/interrupts
List the interrupts in use. May need to find out before setting up new hardware.
cat /proc/version
Linux version and other info.
Some Commands
cat /proc/filesystems
Show the types of filesystems currently in use.
cat /etc/printcap |more
Show the setup of printers.
Some Commands
C programming in Linux
Shell Scripting
Working with Shell Scripting
Shell Scripts
Loops
While Loop
Condition
Condition (Case)
Comparison
Comparison
Array
Functions
Parameter
Scheduling in Linux
Process Scheduling
Two Level Implementation
Linux vs. Two Level
Advantage
Linux File Structure
• Linux: first developed on a minix system
• Both OSs shared space on the same disk
• So Linux reimplemented minix file system
• Two severe limitations in the minix FS
– Block addresses are 16-bits (64MB limit)
– Directories use fixed-size entries (w/filename)
Cross-development
Originally written by Chris Provenzano
Extensively rewritten by Linux Torvalds
Initially released in 1992
Removed the two big limitations in minix
Used 32-bit file-pointers (filesizes to 2GB)
Allowed long filenames (up to 255 chars)
Question: How to integrate ext into Linux?
Extended File System
Multiple file systems need to coexist
But filesystems share a core of common
concepts and high-level operations
So can create a filesystem abstraction
Applications interact with this VFS
The Virtual File System idea
Task 1 Task 2 Task n…
user space
kernel space
VIRTUAL FILE SYSTEM
minix ext2 msdos proc
device driver
for hard disk
device driver
for floppy disk
Buffer Cache
software
hardware
Hard Disk Floppy Disk
Linux Kernel
• Two new filesystems introduced in 1993
• Both tried to overcome Ext’s limitations
• Xia was based on existing minix code
• Ext2 was based on Torvalds’ Ext code
• Xia was initially more stable (smaller)
• But flaws in Ext2 were eventually fixed
• Ext2 soon became a ‘de facto’ standard
Xia and Ext2 File systems
• Files are represented by inodes
• Directories are special files (dentries)
• Devices accessed by I/O on special files
• UNIX filesystems can implement ‘links’
Common concepts
Directory
•These are structured in a tree hierarchy
•Each can contain both files and directories
•A directory is just a special type of file
•Special user-functions for directory access
•Each directory contains filename + inode-no
•Kernel searches the directory tree
•translates a pathname to an inode-number
Linux Directory Structure
1. / root:
• Every single file and directory starts from the root directory.
• Only root user has write privilege under this directory.
• It treat every thing as file.
2 /boot – Boot Loader Files
• Contains boot loader related files.
• Grub(Grand unified boot loader) files are located under /boot.
3 /home – Home Directories
• Home directories for all users to store their personal files.
• For example: /home/mohan or /home/sohan
Directory is Mapping b/w user and folder
Some Directories
4 /usr – User Programs
• Contains binaries, libraries, documentation, and source-code for second level programs.
• /usr/bin contains binary files for user programs. If you can’t find a user binary under /bin,
look under /usr/bin.
• /usr/local contains users programs that you install from source. For example, when you
install apache from source, it goes under /usr/local/apache2
5 /etc – Configuration Files
• Contains configuration files required by all programs in plain text format.
• This also contains startup and shutdown shell scripts used to start/stop individual
programs.
6 /tmp – Temporary Files
• Directory that contains temporary files created by system and users.
• Files under this directory are deleted when system is rebooted.
Inode Table Directory
i1
i2
i3
i4
name1
name2
name3
name4
Directory diagram
• A structure that contains file’s description:
– Type
– Access rights
– Owners
– Timestamps
– Size
– Pointers to data blocks
• Kernel keeps the inode in memory (open)
Inode
inode
File info
Direct blocks
Indirect blocks
Double
Indirect
Blocks
Inode diagram
• Multiple names can point to same inode
• The inode keeps track of how many links
• If a file gets deleted, the inode’s link-count gets
decremented by the kernel
• File is deallocated if link-count reaches 0
• This type of linkage is called a ‘hard’ link
• Hard links may exist only within a single FS
• Hard links cannot point to directories (cycles)
Links
Network Configuration
Networking
General Network Configuration Procedure
To connect a host to the network, the administrator needs the following information.
 Host name for the system
 Domain name for the system
 IP address for the system
 Netmask for the network (if applicable)
 Default router (gateway) for the network
 Name service used on the network
 Name or address of the machine providing name service
Once you have this information, you can configure the machine and “plug it in” to the
network.
Common UNIX Configuration Files
Network configuration information is stored in several files on the
system.
Most of the OS installers ask for the previously listed information
and configure the system for network operation.
Where is all of this information stored?
How do you make changes to the network configuration without
reloading the operating system?
/etc/hostname.if_name File
Many versions of UNIX use files in the /etc directory to aid in the
configuration of individual interfaces on the system.
For example, Solaris uses files with the generic name /etc/hostname.if_name
to simplify system configuration at boot time.
The device name of the network interface is substituted for the if_name
portion of the file name.
For a host with an on-board hme Ethernet device, connected to a single
network, the /etc/hostname.hme0 file would contain the host name to be
used by that interface.
Machines connected to multiple networks would have multiple /etc/host-
name.if_name files.
Solaris also uses a file called /etc/hostname6.if_name to configure any Ipv6
interfaces on the system.
ifconfig
The ifconfig command is used to bind the IP address, host name, net mask, broadcast
address, and other network configuration parameters to a particular network interface.
The ifconfig command is run at boot time by the startup scripts called by the init process.
Unfortunately, every vendor has added its own options to the ifconfig command, with the
list of options growing daily.
This fact makes it almost impossible to tabulate all options available for every operating
system environment.
You can use the ifconfig command to examine and/or modify interface parameters while
the system is up and running.
When issued with the –a flag, ifconfig prints the configuration information for all
interfaces.
Note that IPv4 and IPv6 information is listed separately on dual-stack hosts.
Because the implementation details may differ on various versions of UNIX, it is best to
consult the ifconfig manual page on your system for more information on this command.
route
The route command is used to add and manage static routing tables
on the host.
Static routes are, as the name implies, routes that should not change
very often.
Many sites configure their systems to send all packets to the
site/building/group router nearest the host’s location.
The routers then decide how to deliver the data to the final
destination.
The route command allows the administrator to manually add a static
route to this “default gateway” router.
The generic call to the route command is as follows.
route [-f] keyword [type] destination gateway [metric]
Solaris
To configure the DHCP Server service under Solaris, the administrator should use the
dhcpconfig command. The dhcpconfig command is a front end to the dhtadm and pntadm
utilities that build and maintain DHCP configuration tables. The dhcpconfig command
allows the administrator to configure DHCP and Boot Relay services (required for remote
DHCP), or to unconfigure the DHCP service.
The dhcpconfig command will guide the user through several questions, collecting the
information necessary to set up DHCP on the server. Once the information is collected by
dhcpconfig, it will invoke the dhtadm and pntadm commands to create the DHCP database
files, and start the DHCP service.
If this DHCP server were required to provide DHCP service for remote networks, the
administrator would have to set up/configure the BOOTP Relay service. The DHCP
registration requests are sent as broadcast packets. By default, routers will not forward
broadcast packets to other networks. For the DHCP registration request packets to get to
the server, a relay service has to forward them through the router.
Network Monitoring and Troubleshooting
As with most computer operations, networks are bound to have problems. Troubleshooting
networks can be a tedious process.
One method of troubleshooting is to use monitoring tools that determine how the network is
being used. In some cases, it may not be possible to monitor a network because physical
connections may be damaged or gateways may be down.
Another method of monitoring the network is to watch the console error messages generated by
the machines connected to the network.
Console Error Messages
The error messages sent to the system console provide you with a lot of information about the
health of the system and the network.
Unfortunately, many administrators do not pay attention to console messages (or worse yet,
close the console window, or leave the console window iconized).
Fortunately, UNIX provides the administrator with a simple facility for capturing all console
messages in a single location.
The UNIX kernel uses the syslog facility to log messages to the system console. However, syslog
also allows these messages to be sent to remote hosts.
/etc/syslog.conf File
The /etc/syslog.conf file controls the action of the syslog facility. The
UNIX kernel defines several levels of message severity.
Entries in the syslog.conf file configure the syslog facility to handle
these different message categories.
For example, a simple informational message may be ignored,
whereas a system hardware error may be reported to the console
with much fanfare.
Host Configuration
• Network Monitoring
• Although kernel syslog messages may provide some information about the health of the network,
it is sometimes necessary to more closely examine the network.
• Simple Network Management Protocol (SNMP)
• A more sophisticated method of monitoring networks is to use a network management tool based
on the simple network management protocol (SNMP).
• The SNMP package allows a network administration host to constantly monitor the network.
Information available to the SNMP software includes network utilization, host error counts, host
packet counts, and routing information. SNMP allows you to determine normal usage of the net-
work and implement alarms to warn of impending problems.
• SNMP operates in a client/server mode. One machine on the network is designated as the SNMP
network monitor station. It is configured to poll hosts on the local network in order to collect data
into a central repository. The data may be made available to other packages in order to implement
alarms, generate graphs of network utilization, and other off-line processing.
• The other hosts on the network are configured as SNMP clients. These hosts run a process that
watches for polling requests from the network management station. When such a request is
received, the SNMP agent code collects the data from the workstation’s kernel and forwards it to
the management station.
Host Configuration
• Configuring SNMP
– Under most operating systems, the default SNMP configuration is horribly insecure. For this
reason, many sites disable the SNMP client code on their systems. If you must run SNMP,
there are several things you should do in an attempt to protect the security of your systems.
– Change the public and private community strings. By default, the public string is public.
Private community strings vary by vendor, but are usually easy to find. Access to the private
string gives an intruder the capability to reconfigure your hosts/network equipment.
Change these strings and protect them as you would the root password. The SNMP
community strings are just as dangerous as a compromised root password!
– Block TCP and UDP ports 161, 162, and 1993 at your border routers. There should be no
reason for someone outside your organization to access your site using SNMP.
– Keep current with patches. Watch for SNMP security advisories, and make sure your hosts
are patched.
– If you generate OpenView or MRTG information for your network, do not allow it to be
viewed without proper authentication. The data available from OpenView and/or MRTG
packages often gives intruders important information about your network.
– With these rules in mind, the following sections briefly discuss how to configure the SNMP
client on various operating systems.
Host Configuration
• SNMP Under Solaris
– Under Solaris, the following four files are responsible for the configuration and
startup of the SNMP package.
–  /etc/rc2.d/S76snmpdx: Startup script for the snmp daemon.
–  /etc/rc2.d/S77dmi: Startup script for the DMI processes that are part of the
snmp package.
–  /etc/snmp/conf/snmpdx.acl: File containing a list of IP addresses allowed to
contact the SNMP daemon on this system. The default file contains comments
that explain how to add the IP addresses, and community strings for each host
allowed to contact the local SNMP daemon.
–  /etc/snmp/conf/snmpd.conf: Text configuration file for snmpd.
– The administrator needs to edit the configuration file and set the read and write
community strings to something unique to the local site, as shown in the following
example.
Host Configuration
• SNMP Under Linux
– By default, most Linux installers no longer install the SNMP package.
– To use SNMP, you must install the SNMP utilities from the distribution medium, or from
a downloaded RPM.
– If you do run SNMP, you need to edit the /etc/snmp.conf file to set the runtime
parameters for the SNMP utilities.
• SNMP Under HPUX
– Under HPUX, the following two files are responsible for the configuration and startup of
the SNMP package.
– /usr/sbin/snmpd: Startup script for the snmp daemon
– /etc/SnmpAgent.d/snmpd.conf: Text configuration file for snmpd
– The snmpd.conf file allows the administrator to define several variables that control the
actions of the SNMP daemon.
Host Configuration
• SNMP Under Windows
– Under Windows, the SNMP package is not installed by default.
– To use the SNMP package under Windows the administrator must load the package
from the distribution medium.
– This may be accomplished using the Add/Remove Programs control panel.
– Click on the Add/Remove Windows Components button, select the Management
and Monitoring Tools option, and click on the Details button.
– Next, select Simple Network Management Protocol, and click on OK.
– Once the SNMP protocol has been installed, select Control Panel | Administrative
Tools | Services GUI to select the SNMP agent.
– This will cause a pop-up window to appear. The pop-up window contains entries for
the configuration and management of the SNMP process
24.2. Configuring a Samba Server
The default configuration file (/etc/samba/smb.conf) allows users to view their home directories
as a Samba share. It also shares all printers configured for the system as Samba shared printers.
In other words, you can attach a printer to the system and print to it from the Windows
machines on your network.
24.2.1. Graphical Configuration.
The Samba Server Configuration Tool is a graphical interface for managing Samba shares, users,
and basic server settings. It modifies the configuration files in the /etc/samba/ directory. Any
changes to these files not made using the application are preserved.
To use this application, you must be running the X Window System, have root privileges, and
have the redhat-config-samba RPM package installed. To start the Samba Server Configuration
Tool from the desktop, go to the Main Menu Button (on the Panel) => System Settings =>
Server Settings => Samba or type the command redhat-config-samba at a shell prompt (for
example, in an XTerm or a GNOME terminal).
Configuration Samba Server
24.2.1.1. Configuring Server Settings
The first step in configuring a Samba server is to configure the basic settings for the server and a
few security options. After starting the application, select Preferences => Server Settings from
the pulldown menu.
Contd..
On the Basic tab, specify which workgroup the computer should be in as well as a brief
description of the computer. They correspond to the workgroup and server string options in
smb.conf.
Contd..
The Security tab contains the following options:
Authentication Mode — This corresponds to the security option. Select one of the
following types of authentication.
ADS — The Samba server acts as a domain member in an Active Directory Domain
(ADS) realm.
Domain — The Samba server relies on a Windows NT Primary or Backup Domain Controller
to verify the user. The server passes the username and password to the Controller and
waits for it to return.
The Encrypted Passwords option must be set to Yes if this is selected.
Server — The Samba server tries to verify the username and password combination by
passing them to another Samba server. If it can not, the server tries to verify using the user
authentication mode.
Share — Samba users do not have to enter a username and password combination on a per
Samba server basis. They are not prompted for a username and password until they try to
connect to a specific shared directory from a Samba server.
User — (Default) Samba users must provide a valid username and password on a per
Samba server basis. Select this option if you want the Windows Username option to work.
Contd..
Encrypt Passwords — This option must be enabled if the clients are connecting from a Windows
98, Windows NT 4.0 with Service Pack 3, or other more recent versions of Microsoft Windows.
The passwords are transferred between the server and the client in an encrypted format instead
of in as a plain-text word that can be intercepted. This corresponds to the encrypted passwords
option.
Guest Account — When users or guest users log into a Samba server, they must be mapped to a
valid user on the server. Select one of the existing usernames on the system to be the guest
Samba account. When guests logs in to the Samba server, they have the same privileges as this
user. This corresponds to the guest account option.
Contd..
Managing Samba Users
The Samba Server Configuration Tool requires that an
existing user account be active on the system acting as
the Samba server before a Samba user can be added.
Adding a Share
Contd..

Contenu connexe

Tendances

Microsoft windows operating concept
Microsoft windows operating conceptMicrosoft windows operating concept
Microsoft windows operating concept
Mi L
 
Operating system presentation
Operating system  presentationOperating system  presentation
Operating system presentation
Descon
 
Installing mandriva linux mandriva community wiki
Installing mandriva linux   mandriva community wikiInstalling mandriva linux   mandriva community wiki
Installing mandriva linux mandriva community wiki
Adolfo Nasol
 
Chapter 7 Storage
Chapter 7 StorageChapter 7 Storage
Chapter 7 Storage
norzaini
 
Windows 7 project.pptx
Windows 7 project.pptxWindows 7 project.pptx
Windows 7 project.pptx
Tea Trebicka
 

Tendances (20)

Evolution of Microsoft windows operating systems
Evolution of Microsoft windows operating systemsEvolution of Microsoft windows operating systems
Evolution of Microsoft windows operating systems
 
Windows series operating system
Windows series operating systemWindows series operating system
Windows series operating system
 
Network operating system practicle file
Network operating system practicle fileNetwork operating system practicle file
Network operating system practicle file
 
Operating system windows XP
Operating system windows XPOperating system windows XP
Operating system windows XP
 
Introduction to-computers
Introduction to-computersIntroduction to-computers
Introduction to-computers
 
Microsoft windows operating concept
Microsoft windows operating conceptMicrosoft windows operating concept
Microsoft windows operating concept
 
Advancements in Microsoft Windows
Advancements in Microsoft WindowsAdvancements in Microsoft Windows
Advancements in Microsoft Windows
 
Windows 111
Windows 111Windows 111
Windows 111
 
Operating system presentation
Operating system  presentationOperating system  presentation
Operating system presentation
 
Introduction to ms windows
Introduction to ms windowsIntroduction to ms windows
Introduction to ms windows
 
Ict 5
Ict 5Ict 5
Ict 5
 
Features of windows operating system
Features of windows operating systemFeatures of windows operating system
Features of windows operating system
 
Installing mandriva linux mandriva community wiki
Installing mandriva linux   mandriva community wikiInstalling mandriva linux   mandriva community wiki
Installing mandriva linux mandriva community wiki
 
Windows operating systems
Windows operating systemsWindows operating systems
Windows operating systems
 
Introduction To Windows Xp Class 1
Introduction To Windows Xp   Class 1Introduction To Windows Xp   Class 1
Introduction To Windows Xp Class 1
 
Chapter 7 Storage
Chapter 7 StorageChapter 7 Storage
Chapter 7 Storage
 
Installing Operating System
Installing Operating System Installing Operating System
Installing Operating System
 
Windows 7 project.pptx
Windows 7 project.pptxWindows 7 project.pptx
Windows 7 project.pptx
 
introduction to Operating system. (windows)
introduction to Operating system. (windows)introduction to Operating system. (windows)
introduction to Operating system. (windows)
 
Mayur rawat
Mayur rawatMayur rawat
Mayur rawat
 

En vedette

PhD thesis presentation 2012
PhD thesis presentation 2012PhD thesis presentation 2012
PhD thesis presentation 2012
vsharma78
 
Пространственно-распределенная мультикластерная вычислительная система: архит...
Пространственно-распределенная мультикластерная вычислительная система: архит...Пространственно-распределенная мультикластерная вычислительная система: архит...
Пространственно-распределенная мультикластерная вычислительная система: архит...
Mikhail Kurnosov
 
An Introduction To Linux Development Environment
An Introduction To Linux Development EnvironmentAn Introduction To Linux Development Environment
An Introduction To Linux Development Environment
S. M. Hossein Hamidi
 
Introducción a la administración f08
Introducción a la administración f08Introducción a la administración f08
Introducción a la administración f08
Skepper63
 

En vedette (20)

DSS ITSEC 2013 Conference 07.11.2013 - Accellion - The Secure File-Sharing P...
DSS ITSEC 2013 Conference 07.11.2013  - Accellion - The Secure File-Sharing P...DSS ITSEC 2013 Conference 07.11.2013  - Accellion - The Secure File-Sharing P...
DSS ITSEC 2013 Conference 07.11.2013 - Accellion - The Secure File-Sharing P...
 
Lee Clark 7th June 2010
Lee Clark 7th June 2010Lee Clark 7th June 2010
Lee Clark 7th June 2010
 
Sp ws1 ulrich teichler
Sp ws1 ulrich teichlerSp ws1 ulrich teichler
Sp ws1 ulrich teichler
 
PhD thesis presentation 2012
PhD thesis presentation 2012PhD thesis presentation 2012
PhD thesis presentation 2012
 
cIHMS
cIHMScIHMS
cIHMS
 
Пространственно-распределенная мультикластерная вычислительная система: архит...
Пространственно-распределенная мультикластерная вычислительная система: архит...Пространственно-распределенная мультикластерная вычислительная система: архит...
Пространственно-распределенная мультикластерная вычислительная система: архит...
 
Jaba sat explorer-710
Jaba sat explorer-710Jaba sat explorer-710
Jaba sat explorer-710
 
Almoços Convívio Cerberus
Almoços Convívio CerberusAlmoços Convívio Cerberus
Almoços Convívio Cerberus
 
아름다운+이별 김건모
아름다운+이별 김건모아름다운+이별 김건모
아름다운+이별 김건모
 
Finding Time to Study for the CIH Exam
Finding Time to Study for the CIH ExamFinding Time to Study for the CIH Exam
Finding Time to Study for the CIH Exam
 
An Introduction To Linux Development Environment
An Introduction To Linux Development EnvironmentAn Introduction To Linux Development Environment
An Introduction To Linux Development Environment
 
QIP 2012
QIP 2012QIP 2012
QIP 2012
 
Introducción a la administración f08
Introducción a la administración f08Introducción a la administración f08
Introducción a la administración f08
 
Lecture 13
Lecture 13Lecture 13
Lecture 13
 
Cyber Crime
Cyber CrimeCyber Crime
Cyber Crime
 
Desktop environment
Desktop environmentDesktop environment
Desktop environment
 
Cyber crime
Cyber crimeCyber crime
Cyber crime
 
презентация земноводные и пресмыкающиеся
презентация земноводные и пресмыкающиесяпрезентация земноводные и пресмыкающиеся
презентация земноводные и пресмыкающиеся
 
IT Security and Wire Fraud Awareness Slide Deck
IT Security and Wire Fraud Awareness Slide DeckIT Security and Wire Fraud Awareness Slide Deck
IT Security and Wire Fraud Awareness Slide Deck
 
How to identify credit card fraud
How to identify credit card fraudHow to identify credit card fraud
How to identify credit card fraud
 

Similaire à Linux Installation And Shamba Server

Similaire à Linux Installation And Shamba Server (20)

Linux
LinuxLinux
Linux
 
Linux
LinuxLinux
Linux
 
Be Free Be Linux
Be Free Be LinuxBe Free Be Linux
Be Free Be Linux
 
Linux basics
Linux basicsLinux basics
Linux basics
 
Linux
Linux Linux
Linux
 
welcome to linux
welcome to linuxwelcome to linux
welcome to linux
 
windows vs Linux
windows vs Linuxwindows vs Linux
windows vs Linux
 
Linux
Linux Linux
Linux
 
Introduction to FOSS
Introduction to FOSSIntroduction to FOSS
Introduction to FOSS
 
Programming and problem solving 3
Programming and problem solving 3Programming and problem solving 3
Programming and problem solving 3
 
I Am Linux-Introductory Module on Linux
I Am Linux-Introductory Module on LinuxI Am Linux-Introductory Module on Linux
I Am Linux-Introductory Module on Linux
 
Linux Intro
Linux   IntroLinux   Intro
Linux Intro
 
Linuxseminar os
Linuxseminar osLinuxseminar os
Linuxseminar os
 
Linux
LinuxLinux
Linux
 
Overview_Linux ppt
Overview_Linux pptOverview_Linux ppt
Overview_Linux ppt
 
Linux
LinuxLinux
Linux
 
Chapter 8 - nsa Introduction to Linux.ppt
Chapter 8 -  nsa Introduction to Linux.pptChapter 8 -  nsa Introduction to Linux.ppt
Chapter 8 - nsa Introduction to Linux.ppt
 
History of Operting System Windows and a simple comparision
History of Operting System Windows and a simple comparisionHistory of Operting System Windows and a simple comparision
History of Operting System Windows and a simple comparision
 
linux introduction
linux introductionlinux introduction
linux introduction
 
Introduction to linux ppt
Introduction to linux pptIntroduction to linux ppt
Introduction to linux ppt
 

Dernier

在线制作约克大学毕业证(yu毕业证)在读证明认证可查
在线制作约克大学毕业证(yu毕业证)在读证明认证可查在线制作约克大学毕业证(yu毕业证)在读证明认证可查
在线制作约克大学毕业证(yu毕业证)在读证明认证可查
ydyuyu
 
Russian Escort Abu Dhabi 0503464457 Abu DHabi Escorts
Russian Escort Abu Dhabi 0503464457 Abu DHabi EscortsRussian Escort Abu Dhabi 0503464457 Abu DHabi Escorts
Russian Escort Abu Dhabi 0503464457 Abu DHabi Escorts
Monica Sydney
 
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
pxcywzqs
 
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
ydyuyu
 
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
ayvbos
 
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
gajnagarg
 
75539-Cyber Security Challenges PPT.pptx
75539-Cyber Security Challenges PPT.pptx75539-Cyber Security Challenges PPT.pptx
75539-Cyber Security Challenges PPT.pptx
Asmae Rabhi
 
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
ydyuyu
 
Indian Escort in Abu DHabi 0508644382 Abu Dhabi Escorts
Indian Escort in Abu DHabi 0508644382 Abu Dhabi EscortsIndian Escort in Abu DHabi 0508644382 Abu Dhabi Escorts
Indian Escort in Abu DHabi 0508644382 Abu Dhabi Escorts
Monica Sydney
 
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girlsRussian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Monica Sydney
 

Dernier (20)

20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
20240507 QFM013 Machine Intelligence Reading List April 2024.pdf
 
在线制作约克大学毕业证(yu毕业证)在读证明认证可查
在线制作约克大学毕业证(yu毕业证)在读证明认证可查在线制作约克大学毕业证(yu毕业证)在读证明认证可查
在线制作约克大学毕业证(yu毕业证)在读证明认证可查
 
2nd Solid Symposium: Solid Pods vs Personal Knowledge Graphs
2nd Solid Symposium: Solid Pods vs Personal Knowledge Graphs2nd Solid Symposium: Solid Pods vs Personal Knowledge Graphs
2nd Solid Symposium: Solid Pods vs Personal Knowledge Graphs
 
Microsoft Azure Arc Customer Deck Microsoft
Microsoft Azure Arc Customer Deck MicrosoftMicrosoft Azure Arc Customer Deck Microsoft
Microsoft Azure Arc Customer Deck Microsoft
 
20240508 QFM014 Elixir Reading List April 2024.pdf
20240508 QFM014 Elixir Reading List April 2024.pdf20240508 QFM014 Elixir Reading List April 2024.pdf
20240508 QFM014 Elixir Reading List April 2024.pdf
 
Russian Escort Abu Dhabi 0503464457 Abu DHabi Escorts
Russian Escort Abu Dhabi 0503464457 Abu DHabi EscortsRussian Escort Abu Dhabi 0503464457 Abu DHabi Escorts
Russian Escort Abu Dhabi 0503464457 Abu DHabi Escorts
 
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
一比一原版(Offer)康考迪亚大学毕业证学位证靠谱定制
 
APNIC Updates presented by Paul Wilson at ARIN 53
APNIC Updates presented by Paul Wilson at ARIN 53APNIC Updates presented by Paul Wilson at ARIN 53
APNIC Updates presented by Paul Wilson at ARIN 53
 
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrStory Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
Story Board.pptxrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrr
 
20240510 QFM016 Irresponsible AI Reading List April 2024.pdf
20240510 QFM016 Irresponsible AI Reading List April 2024.pdf20240510 QFM016 Irresponsible AI Reading List April 2024.pdf
20240510 QFM016 Irresponsible AI Reading List April 2024.pdf
 
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
哪里办理美国迈阿密大学毕业证(本硕)umiami在读证明存档可查
 
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
一比一原版(Flinders毕业证书)弗林德斯大学毕业证原件一模一样
 
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
best call girls in Hyderabad Finest Escorts Service 📞 9352988975 📞 Available ...
 
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
Top profile Call Girls In Dindigul [ 7014168258 ] Call Me For Genuine Models ...
 
75539-Cyber Security Challenges PPT.pptx
75539-Cyber Security Challenges PPT.pptx75539-Cyber Security Challenges PPT.pptx
75539-Cyber Security Challenges PPT.pptx
 
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
原版制作美国爱荷华大学毕业证(iowa毕业证书)学位证网上存档可查
 
Indian Escort in Abu DHabi 0508644382 Abu Dhabi Escorts
Indian Escort in Abu DHabi 0508644382 Abu Dhabi EscortsIndian Escort in Abu DHabi 0508644382 Abu Dhabi Escorts
Indian Escort in Abu DHabi 0508644382 Abu Dhabi Escorts
 
"Boost Your Digital Presence: Partner with a Leading SEO Agency"
"Boost Your Digital Presence: Partner with a Leading SEO Agency""Boost Your Digital Presence: Partner with a Leading SEO Agency"
"Boost Your Digital Presence: Partner with a Leading SEO Agency"
 
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girlsRussian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
Russian Call girls in Abu Dhabi 0508644382 Abu Dhabi Call girls
 
Power point inglese - educazione civica di Nuria Iuzzolino
Power point inglese - educazione civica di Nuria IuzzolinoPower point inglese - educazione civica di Nuria Iuzzolino
Power point inglese - educazione civica di Nuria Iuzzolino
 

Linux Installation And Shamba Server

  • 2. • History and installation of Linux • Installation and some Feature • Applications of Red Hat • Commands • C programing in shell • Shell Programing with Vi/G Edit • Scheduling of Linux • Memory Management • Interrupts and Exception • Interrupts Handling • Networking • Samba Configuration Overview
  • 3. Why we use LINUX Linux is free of charge . Linux is more secured than any other server and computer It has a wide compatibility to several hardware Easy to Operate It comes inclusive of drivers Smooth and easy Updating Process Linux has a community support Less memory use
  • 4. • In 80’s, Microsoft’s DOS was the dominated OS for PC • Apple MAC was better, but expensive • UNIX was much better, but much, much more expensive. Only for minicomputer for commercial applications • People was looking for a UNIX based system, which is cheaper and can run on PC • Both DOS, MAC and UNIX were proprietary, i.e., the source code of their kernel is protected • No modification is possible without paying high license fees Before Linux
  • 5. All modern operating systems have their roots in 1969 when Dennis Ritchie and Ken Thompson developed the C language and the Unix operating system at AT&T Bell Labs. They shared their source code (yes, there was open source back in the Seventies) with the rest of the world, including the hippies in Berkeley California. By 1975, when AT&T started selling Unix commercially, about half of the source code was written by others. In 1969
  • 6. In 1980 In the Eighties many companies started developing their own Unix: IBM created AIX , Sun SunOS (later Solaris), HP HP-UX and about a dozen other companies did the same. The result was a mess of Unix dialects and a dozen different ways to do the same thing. And here is the first real root of Linux , when Richard Stallman aimed to end this era of Unix separation and everybody re-inventing the wheel by starting the GNU project (GNU is Not Unix). His goal was to make an operating system that was freely available to everyone, and where everyone could work together (like in the Seventies). Many of the command line tools that you use today on Linux are GNU tools.
  • 7. • A famous professor Andrew Tanenbaum developed Minix, a simplified version of UNIX that runs on PC • Minix is for class teaching only. No intention for commercial use • In Sept 1991, Linus Torvalds, a second year student of Computer Science at the University of Helsinki, developed the preliminary kernel of Linux, known as Linux version 0.0.1. • He put the source code online, thinking it would never support anything but 386 hardware. Many people embraced the combination of this kernel with the GNU tools, and the rest, as they say, is history. In 1990’s
  • 8. GNU project Established in 1984 by Richard Stallman, who believes that software should be free from restrictions against copying or modification in order to make better and efficient computer programs
  • 9. Today more than 97 percent of the world's supercomputers (including the complete top 10),more than 80 percent of all smartphones, many millions of desktop computers, around 70 percent of all web servers, a large chunk of tablet computers, and several appliances (dvd-players, washing machines, dsl modems, routers, self-driving cars, space station laptops...)run Linux . Linux is by far the most commonly used operating system in the world. Linux kernel version 4.0 was released in April 2015. Its source code grew by several hundred thousand lines (compared to version 3.19 from February 2015) thanks to contributions of thousands of developers paid by hundreds of commercial companies including Red Hat, Intel, Samsung, Broadcom, Texas Instruments, IBM, Novell, Qualcomm, Nokia, Oracle, Google, AMD and even Microsoft (and many more). In 2015
  • 10. Today more than 97 percent of the world's supercomputers (including the complete top 10),more than 80 percent of all smartphones, many millions of desktop computers, around 70 percent of all web servers, a large chunk of tablet computers, and several appliances (dvd-players, washing machines, dsl modems, routers, self-driving cars, space station laptops...)run Linux Growing and growing… Linux: No of Users
  • 11. 138712 155679 users registered machines registered
  • 12. Free software, as defined by the FSF (Free Software Foundation), is a "matter of liberty, not price." To qualify as free software by FSF standards, you must be able to: • Run the program for any purpose you want to, rather than be restricted in what you can use it for. • View the program's source code. • Study the program's source code and modify it if you need to. • Share the program with others. • Improve the program and release those improvements so that others can use them. Linux - free software
  • 14.
  • 15.
  • 16.
  • 17.
  • 18.
  • 19.
  • 20.
  • 21.
  • 22.
  • 23.
  • 24.
  • 25.
  • 26.
  • 27.
  • 28.
  • 29.
  • 30.
  • 31.
  • 32.
  • 33.
  • 34.
  • 35.
  • 36.
  • 37.
  • 39. Red Hat Enterprise Linux includes several text editors, applications that allow you to view and modify plain text files. Plain text files are files that contain text without any font or style formatting applied to it, such as system logs and configuration files. To start gedit, click Main Menu => Accessories => Text Editor. You can also start gedit by typing gedit at a shell prompt. Editing Text File (gedit)
  • 40. If you are not using a graphical desktop and want to read and modify a text or configuration file, Red Hat Enterprise Linux includes the vi (pronounced vee-eye) text editor. vi is a simple application that opens within the shell prompt and allows you to view, search, and modify text files. To start vi, type vi at a shell prompt. To open a file with vi type vi <filename> at a shell prompt. Shell Prompt Text Editor
  • 41. A PDF (Portable Document Format) file is an electronic image of a document. An open source application called xpdf is included with Red Hat Enterprise Linux. The xpdf toolbar at the bottom has navigational tools that let you move backward and forward through the PDF document, as well as standard zoom, print, and find tools. The xpdf man page provides useful information on the xpdf options. To view the xpdf man page, at a shell prompt type man xpdf To view a PDF with xpdf: In your desktop environment, go to Main Menu => Graphics => PDF Viewer. You can also launch xpdf by typing xpdf at a shell prompt. Right-click in the xpdf screen to display a list of options. Select Open to display the file browser. Select the PDF file you want to view and click Open. Viewing PDFs
  • 42.
  • 43. Playing Audio CDs To play an audio CD, place the CD in your CD-ROM drive. The CD Player application should appear automatically and begin playing the first audio track. If the interface does not appear, click Main Menu => Sound & Video => CD Player to launch the CD Player application. Audio, Video, and General Amusement
  • 44. Playing Digital Audio Files Digital audio has become very popular in recent years. Users enjoy the technology because the sound quality is excellent compared to analog tape or records, and the files are compact (audio files can easily be transferred across the Internet). To take advantage of this technology, Red Hat Enterprise Linux includes the powerful X Multimedia System (XMMS), a cross-platform multimedia player which allows you to play several digital audio file formats. XMMS Interface XMMS can be used for more than just playing digital audio files. By default XMMS can play Ogg Vorbis, RIFF wave, and most module formats. Additionally, XMMS can be extended via plugins to play a number of other digital multimedia formats. To launch XMMS, go to Main Menu => Sound & Video => Audio Player. To launch XMMS from a shell prompt, type the command xmms Applications
  • 45. Troubleshooting Your Sound Card If, for some reason, you do not hear sound and know that you do have a sound card installed, you can run the Sound Card Configuration Tool utility. To use the Sound Card Configuration Tool, choose Main Menu => System Settings => Soundcard Detection. A small text box pops up prompting you for your root password. The Sound Card Configuration Tool utility probes your system for sound cards. If the utility detects a plug and play sound card, it automatically tries to configure the correct settings for your card. You can then click the Play test sound button to play a sound sample. If you can hear the sample, select OK and your sound card configuration is complete.
  • 46. If the Sound Card Configuration Tool does not work then you can edit your modules.conf file. You can manually edit your /etc/modules.conf file to include the sound card module that it should use Manual Sound Card Configuration
  • 47. Video card configuration is handled during the Red Hat Enterprise Linux installation . However, if you did not choose to configure a video card at that time, or if you need to reconfigure your settings, you can use the X Configuration Tool utility. To run the X Configuration Tool, click Main Menu => System Settings => Display. A pop-up window prompts you for your root password. You can also start from a shell prompt by typing the command redhat-config-xfree86, which then prompts you to enter your root password. If you are working from a shell prompt and X is not working, redhat-config-xfree86 attempts to start a minimal X session to allow you to continue your configuration. Follow the instructions that appear on the screen. The X Configuration Tool attempts to automatically configure your video card and monitor settings for you. Troubleshooting your video card
  • 48. X Configuration Tool To configure your monitor manually, click the Advanced tab, then click the Configure... button next to the Monitor Type entry. A pop-up window displays a list of monitor models. Choose your model and click OK. You can also let the X Configuration Tool probe your monitor for the correct model and vertical/horizontal frequency settings. To configure your video card manually, click the Advanced tab, then click the Configure... button next to the Video Card entry. A pop-up window displays a list of video card models. Choose your model and click OK. You can also let the X Configuration Tool probe your video card for the correct model and settings by clicking the Probe Videocard button. When you have finished reconfiguring your video card and monitor, you should be able to start an X session and enjoy your graphical desktop environment.
  • 49. Game availability depends on the variant of Red Hat Enterprise Linux you installed. You must have those game packages installed before they appear under the Main Menu => Games menu. Refer to the Red Hat Enterprise Linux System Administration Guide for details on installing additional packages. Games
  • 50. Red Hat Enterprise Linux supports over 100 digital camera models. So, whether your camera uses a USB or serial port to communicate with your computer, it is likely that Red Hat Enterprise Linux supports it. gtKam is a graphical application that allows you to interface with your digital camera. gtKam works directly with your digital camera, allowing you to open, view, save, and delete images directly To start gtKam, choose Main Menu => Graphics => Digital Camera Tool. You can also start gtKam by typing gtkam at a shell prompt. Before you begin using gtKam, you need to configure it to work with your digital camera. From the menu, choose Camera => Add Camera.... From the pop-up dialog, you can choose your camera from the drop-down list or let gtKam automatically find your camera by clicking Detect. Click Apply to accept the changes and OK to close the dialog box. Using gtKam
  • 51. Adding a Camera in gtKam Once you have added your camera, it will be shown as an icon on the left panel of the main gtKam window. You only have to configure gtKam for your camera once; the settings will be saved with each additional use. Directories shown below the icon may differ depending on your brand of camera. Select the directory that commonly stores your images and the stored images will immediately load as thumbnail images in the main panel. From this panel, click on the images you want, which you can then save to disk by choosing File => Save Selected Photos. If you want to save all of the stored images, choose Select => All, then save the images to disk.
  • 52. Directories: File and directory paths in UNIX use the forward slash "/" to separate directory names in a path. examples: / "root" directory /usr directory usr (sub-directory of / "root" directory) /usr/STRIM100 STRIM100 is a subdirectory of /usr Moving around the file system: pwd Show the "present working directory", or current directory. cd Change current directory to your HOME directory. cd .. Change current directory to the parent directory of the current directory. Linux Command
  • 53. Listing directory contents: ls : list a directory ls -l : list a directory in long ( detailed ) format for example: ls –a : List the current directory including hidden files. Hidden files start with "."
  • 54.
  • 57. By far, the most useful and powerful thing you can do with I/O redirection is to connect multiple commands together with what are called pipes(|). With pipes, the standard output of one command is fed into the standard input of another. Here is my absolute favorite: [me@linuxbox me]$ ls -l | less In this example, the output of the ls command is fed into less. By using this "| less" trick, you can make any command have scrolling output. I use this technique all the time. Pipes
  • 58.
  • 59. Commands that let you determine what is going on with your system. pwd Print working directory, i.e., display the name of my current directory on the screen. hostname Print the name of the local host (the machine on which I am working). Use netconf (as root) to change the name of the machine. whoami Print my login name. id username Print user id (uid) and his/her group id (gid), effective id (if different than the real id) and the supplementary groups. date Print the operating system current date, time and timezone. For an ISO standard format, I have to use date -Iseconds. Some Commands
  • 60. who Determine the users logged on the machine. w Determine who is logged on the system, find out what they are doing, their processor ussage, etc. Handy security command. rwho -a (=remote who) Determine users logged on other computers on your network. The rwho service must be enabled for this command to run. If it isn't, run setup (RedHat specific) as root to enable "rwho". finger user_name System info about a user. Try: finger root . One can use finger with any networked computer that exposes the finger service to the world, e.g., I can do (try): finger @finger.kernel.org last Show listing of users last logged-in on your system. Really good idea to check it from time to time as a security measure on your system. lastb ("=last bad") Show the last bad (unsuccessful) login attempts on my system. Some Commands
  • 61. history | more Show the last (1000 or so) commands executed from the command line on the current account. The "| more" causes the display to stop after each screen-full. To see what another user was doing on your system, login as "root" and inspect his/her "history". comman Run the most recent command from my bash history commands that starts with the string "comman". This is usefull for re-running often the same, command which may be complicated to type. uptime Show the amount of time since the last reboot. ps (="print status" or "process status") List the processes currently run by the current user. Some Commands
  • 62. free Memory info (in kilobytes). "Shared" memory is the memory that can be shared between processes (e.g., executable code is "shared"). df -h (=disk free) Print disk info about all the filesystems (in human-readable form). du / -bh | more (=disk usage) Print detailed disk usage for each subdirectory starting at the "/" (root) directory (in human legible form). cat /proc/cpuinfo Cpu info - shows the content of the file cpuinfo. Note that the files in the /proc directory are no real files - they are hooks to look at information available to the kernel. cat /proc/interrupts List the interrupts in use. May need to find out before setting up new hardware. cat /proc/version Linux version and other info. Some Commands
  • 63. cat /proc/filesystems Show the types of filesystems currently in use. cat /etc/printcap |more Show the setup of printers. Some Commands
  • 66. Working with Shell Scripting
  • 68. Loops
  • 74. Array
  • 80. Linux vs. Two Level
  • 83. • Linux: first developed on a minix system • Both OSs shared space on the same disk • So Linux reimplemented minix file system • Two severe limitations in the minix FS – Block addresses are 16-bits (64MB limit) – Directories use fixed-size entries (w/filename) Cross-development
  • 84. Originally written by Chris Provenzano Extensively rewritten by Linux Torvalds Initially released in 1992 Removed the two big limitations in minix Used 32-bit file-pointers (filesizes to 2GB) Allowed long filenames (up to 255 chars) Question: How to integrate ext into Linux? Extended File System
  • 85.
  • 86. Multiple file systems need to coexist But filesystems share a core of common concepts and high-level operations So can create a filesystem abstraction Applications interact with this VFS The Virtual File System idea
  • 87. Task 1 Task 2 Task n… user space kernel space VIRTUAL FILE SYSTEM minix ext2 msdos proc device driver for hard disk device driver for floppy disk Buffer Cache software hardware Hard Disk Floppy Disk Linux Kernel
  • 88. • Two new filesystems introduced in 1993 • Both tried to overcome Ext’s limitations • Xia was based on existing minix code • Ext2 was based on Torvalds’ Ext code • Xia was initially more stable (smaller) • But flaws in Ext2 were eventually fixed • Ext2 soon became a ‘de facto’ standard Xia and Ext2 File systems
  • 89. • Files are represented by inodes • Directories are special files (dentries) • Devices accessed by I/O on special files • UNIX filesystems can implement ‘links’ Common concepts
  • 90. Directory •These are structured in a tree hierarchy •Each can contain both files and directories •A directory is just a special type of file •Special user-functions for directory access •Each directory contains filename + inode-no •Kernel searches the directory tree •translates a pathname to an inode-number
  • 92. 1. / root: • Every single file and directory starts from the root directory. • Only root user has write privilege under this directory. • It treat every thing as file. 2 /boot – Boot Loader Files • Contains boot loader related files. • Grub(Grand unified boot loader) files are located under /boot. 3 /home – Home Directories • Home directories for all users to store their personal files. • For example: /home/mohan or /home/sohan Directory is Mapping b/w user and folder Some Directories
  • 93. 4 /usr – User Programs • Contains binaries, libraries, documentation, and source-code for second level programs. • /usr/bin contains binary files for user programs. If you can’t find a user binary under /bin, look under /usr/bin. • /usr/local contains users programs that you install from source. For example, when you install apache from source, it goes under /usr/local/apache2 5 /etc – Configuration Files • Contains configuration files required by all programs in plain text format. • This also contains startup and shutdown shell scripts used to start/stop individual programs. 6 /tmp – Temporary Files • Directory that contains temporary files created by system and users. • Files under this directory are deleted when system is rebooted.
  • 95. • A structure that contains file’s description: – Type – Access rights – Owners – Timestamps – Size – Pointers to data blocks • Kernel keeps the inode in memory (open) Inode
  • 96. inode File info Direct blocks Indirect blocks Double Indirect Blocks Inode diagram
  • 97. • Multiple names can point to same inode • The inode keeps track of how many links • If a file gets deleted, the inode’s link-count gets decremented by the kernel • File is deallocated if link-count reaches 0 • This type of linkage is called a ‘hard’ link • Hard links may exist only within a single FS • Hard links cannot point to directories (cycles) Links
  • 100. General Network Configuration Procedure To connect a host to the network, the administrator needs the following information.  Host name for the system  Domain name for the system  IP address for the system  Netmask for the network (if applicable)  Default router (gateway) for the network  Name service used on the network  Name or address of the machine providing name service Once you have this information, you can configure the machine and “plug it in” to the network.
  • 101. Common UNIX Configuration Files Network configuration information is stored in several files on the system. Most of the OS installers ask for the previously listed information and configure the system for network operation. Where is all of this information stored? How do you make changes to the network configuration without reloading the operating system?
  • 102. /etc/hostname.if_name File Many versions of UNIX use files in the /etc directory to aid in the configuration of individual interfaces on the system. For example, Solaris uses files with the generic name /etc/hostname.if_name to simplify system configuration at boot time. The device name of the network interface is substituted for the if_name portion of the file name. For a host with an on-board hme Ethernet device, connected to a single network, the /etc/hostname.hme0 file would contain the host name to be used by that interface. Machines connected to multiple networks would have multiple /etc/host- name.if_name files. Solaris also uses a file called /etc/hostname6.if_name to configure any Ipv6 interfaces on the system.
  • 103. ifconfig The ifconfig command is used to bind the IP address, host name, net mask, broadcast address, and other network configuration parameters to a particular network interface. The ifconfig command is run at boot time by the startup scripts called by the init process. Unfortunately, every vendor has added its own options to the ifconfig command, with the list of options growing daily. This fact makes it almost impossible to tabulate all options available for every operating system environment. You can use the ifconfig command to examine and/or modify interface parameters while the system is up and running. When issued with the –a flag, ifconfig prints the configuration information for all interfaces. Note that IPv4 and IPv6 information is listed separately on dual-stack hosts. Because the implementation details may differ on various versions of UNIX, it is best to consult the ifconfig manual page on your system for more information on this command.
  • 104. route The route command is used to add and manage static routing tables on the host. Static routes are, as the name implies, routes that should not change very often. Many sites configure their systems to send all packets to the site/building/group router nearest the host’s location. The routers then decide how to deliver the data to the final destination. The route command allows the administrator to manually add a static route to this “default gateway” router. The generic call to the route command is as follows. route [-f] keyword [type] destination gateway [metric]
  • 105. Solaris To configure the DHCP Server service under Solaris, the administrator should use the dhcpconfig command. The dhcpconfig command is a front end to the dhtadm and pntadm utilities that build and maintain DHCP configuration tables. The dhcpconfig command allows the administrator to configure DHCP and Boot Relay services (required for remote DHCP), or to unconfigure the DHCP service. The dhcpconfig command will guide the user through several questions, collecting the information necessary to set up DHCP on the server. Once the information is collected by dhcpconfig, it will invoke the dhtadm and pntadm commands to create the DHCP database files, and start the DHCP service. If this DHCP server were required to provide DHCP service for remote networks, the administrator would have to set up/configure the BOOTP Relay service. The DHCP registration requests are sent as broadcast packets. By default, routers will not forward broadcast packets to other networks. For the DHCP registration request packets to get to the server, a relay service has to forward them through the router.
  • 106. Network Monitoring and Troubleshooting As with most computer operations, networks are bound to have problems. Troubleshooting networks can be a tedious process. One method of troubleshooting is to use monitoring tools that determine how the network is being used. In some cases, it may not be possible to monitor a network because physical connections may be damaged or gateways may be down. Another method of monitoring the network is to watch the console error messages generated by the machines connected to the network. Console Error Messages The error messages sent to the system console provide you with a lot of information about the health of the system and the network. Unfortunately, many administrators do not pay attention to console messages (or worse yet, close the console window, or leave the console window iconized). Fortunately, UNIX provides the administrator with a simple facility for capturing all console messages in a single location. The UNIX kernel uses the syslog facility to log messages to the system console. However, syslog also allows these messages to be sent to remote hosts.
  • 107. /etc/syslog.conf File The /etc/syslog.conf file controls the action of the syslog facility. The UNIX kernel defines several levels of message severity. Entries in the syslog.conf file configure the syslog facility to handle these different message categories. For example, a simple informational message may be ignored, whereas a system hardware error may be reported to the console with much fanfare.
  • 108. Host Configuration • Network Monitoring • Although kernel syslog messages may provide some information about the health of the network, it is sometimes necessary to more closely examine the network. • Simple Network Management Protocol (SNMP) • A more sophisticated method of monitoring networks is to use a network management tool based on the simple network management protocol (SNMP). • The SNMP package allows a network administration host to constantly monitor the network. Information available to the SNMP software includes network utilization, host error counts, host packet counts, and routing information. SNMP allows you to determine normal usage of the net- work and implement alarms to warn of impending problems. • SNMP operates in a client/server mode. One machine on the network is designated as the SNMP network monitor station. It is configured to poll hosts on the local network in order to collect data into a central repository. The data may be made available to other packages in order to implement alarms, generate graphs of network utilization, and other off-line processing. • The other hosts on the network are configured as SNMP clients. These hosts run a process that watches for polling requests from the network management station. When such a request is received, the SNMP agent code collects the data from the workstation’s kernel and forwards it to the management station.
  • 109. Host Configuration • Configuring SNMP – Under most operating systems, the default SNMP configuration is horribly insecure. For this reason, many sites disable the SNMP client code on their systems. If you must run SNMP, there are several things you should do in an attempt to protect the security of your systems. – Change the public and private community strings. By default, the public string is public. Private community strings vary by vendor, but are usually easy to find. Access to the private string gives an intruder the capability to reconfigure your hosts/network equipment. Change these strings and protect them as you would the root password. The SNMP community strings are just as dangerous as a compromised root password! – Block TCP and UDP ports 161, 162, and 1993 at your border routers. There should be no reason for someone outside your organization to access your site using SNMP. – Keep current with patches. Watch for SNMP security advisories, and make sure your hosts are patched. – If you generate OpenView or MRTG information for your network, do not allow it to be viewed without proper authentication. The data available from OpenView and/or MRTG packages often gives intruders important information about your network. – With these rules in mind, the following sections briefly discuss how to configure the SNMP client on various operating systems.
  • 110. Host Configuration • SNMP Under Solaris – Under Solaris, the following four files are responsible for the configuration and startup of the SNMP package. –  /etc/rc2.d/S76snmpdx: Startup script for the snmp daemon. –  /etc/rc2.d/S77dmi: Startup script for the DMI processes that are part of the snmp package. –  /etc/snmp/conf/snmpdx.acl: File containing a list of IP addresses allowed to contact the SNMP daemon on this system. The default file contains comments that explain how to add the IP addresses, and community strings for each host allowed to contact the local SNMP daemon. –  /etc/snmp/conf/snmpd.conf: Text configuration file for snmpd. – The administrator needs to edit the configuration file and set the read and write community strings to something unique to the local site, as shown in the following example.
  • 111. Host Configuration • SNMP Under Linux – By default, most Linux installers no longer install the SNMP package. – To use SNMP, you must install the SNMP utilities from the distribution medium, or from a downloaded RPM. – If you do run SNMP, you need to edit the /etc/snmp.conf file to set the runtime parameters for the SNMP utilities. • SNMP Under HPUX – Under HPUX, the following two files are responsible for the configuration and startup of the SNMP package. – /usr/sbin/snmpd: Startup script for the snmp daemon – /etc/SnmpAgent.d/snmpd.conf: Text configuration file for snmpd – The snmpd.conf file allows the administrator to define several variables that control the actions of the SNMP daemon.
  • 112. Host Configuration • SNMP Under Windows – Under Windows, the SNMP package is not installed by default. – To use the SNMP package under Windows the administrator must load the package from the distribution medium. – This may be accomplished using the Add/Remove Programs control panel. – Click on the Add/Remove Windows Components button, select the Management and Monitoring Tools option, and click on the Details button. – Next, select Simple Network Management Protocol, and click on OK. – Once the SNMP protocol has been installed, select Control Panel | Administrative Tools | Services GUI to select the SNMP agent. – This will cause a pop-up window to appear. The pop-up window contains entries for the configuration and management of the SNMP process
  • 113. 24.2. Configuring a Samba Server The default configuration file (/etc/samba/smb.conf) allows users to view their home directories as a Samba share. It also shares all printers configured for the system as Samba shared printers. In other words, you can attach a printer to the system and print to it from the Windows machines on your network. 24.2.1. Graphical Configuration. The Samba Server Configuration Tool is a graphical interface for managing Samba shares, users, and basic server settings. It modifies the configuration files in the /etc/samba/ directory. Any changes to these files not made using the application are preserved. To use this application, you must be running the X Window System, have root privileges, and have the redhat-config-samba RPM package installed. To start the Samba Server Configuration Tool from the desktop, go to the Main Menu Button (on the Panel) => System Settings => Server Settings => Samba or type the command redhat-config-samba at a shell prompt (for example, in an XTerm or a GNOME terminal). Configuration Samba Server
  • 114. 24.2.1.1. Configuring Server Settings The first step in configuring a Samba server is to configure the basic settings for the server and a few security options. After starting the application, select Preferences => Server Settings from the pulldown menu. Contd..
  • 115. On the Basic tab, specify which workgroup the computer should be in as well as a brief description of the computer. They correspond to the workgroup and server string options in smb.conf. Contd.. The Security tab contains the following options: Authentication Mode — This corresponds to the security option. Select one of the following types of authentication. ADS — The Samba server acts as a domain member in an Active Directory Domain (ADS) realm.
  • 116. Domain — The Samba server relies on a Windows NT Primary or Backup Domain Controller to verify the user. The server passes the username and password to the Controller and waits for it to return. The Encrypted Passwords option must be set to Yes if this is selected. Server — The Samba server tries to verify the username and password combination by passing them to another Samba server. If it can not, the server tries to verify using the user authentication mode. Share — Samba users do not have to enter a username and password combination on a per Samba server basis. They are not prompted for a username and password until they try to connect to a specific shared directory from a Samba server. User — (Default) Samba users must provide a valid username and password on a per Samba server basis. Select this option if you want the Windows Username option to work. Contd..
  • 117. Encrypt Passwords — This option must be enabled if the clients are connecting from a Windows 98, Windows NT 4.0 with Service Pack 3, or other more recent versions of Microsoft Windows. The passwords are transferred between the server and the client in an encrypted format instead of in as a plain-text word that can be intercepted. This corresponds to the encrypted passwords option. Guest Account — When users or guest users log into a Samba server, they must be mapped to a valid user on the server. Select one of the existing usernames on the system to be the guest Samba account. When guests logs in to the Samba server, they have the same privileges as this user. This corresponds to the guest account option. Contd..
  • 118. Managing Samba Users The Samba Server Configuration Tool requires that an existing user account be active on the system acting as the Samba server before a Samba user can be added. Adding a Share Contd..