Drivers and the kernel1-1 Drivers and the kernel UNIX system has three layers: m The hardware m The operating system kernel m The user-level programs Kernel.

Slides:



Advertisements
Similar presentations
Va-scanCopyright 2002, Marchany Unit 8 – Solaris File Systems Randy Marchany VA Tech Computing Center.
Advertisements

Troubleshooting Startup Problems
© 2009 VMware Inc. All rights reserved View Pool Image Configuration Considerations for Gold Images around Application virtualization and performance.
Devices and Drivers (Chapter 7) Khattab Alhabashi UNIX System Administration.
© Tally Solutions Pvt. Ltd. All Rights Reserved 1 Shoper 7.2 Interface with Tally.ERP 9 January 2010.
Hp education services education.hp.com 85 System Crash Dump Version C.00 H4264S Module 9 Slides.
DHCP -Ameeta and Haripriya -cmsc 691x. DHCP ► Dynamic Host Configuration Protocol ► It controls vital networking parameters of hosts with the help of.
Booting and Shutting Down the UNIX Operating System Arcadio A. Sincero Jr. 6/6/2001 CMSC 691X, Section 6080.
Linux Booting Procedure
Linux can be generally divided into four major components: 1. KERNEL – OS, ultimate boss The kernel is the core program that runs programs and manages.
CIS238/DL1 Chapter 15 Rebuilding the Linux Kernel Preparing the Source Code Locating the Source Code Installing the Source Code Read the Documentation.
Linux+ Guide to Linux Certification, Second Edition
Introduction to Unix (CA263) File System
Exploring the UNIX File System and File Security
1 Web Server Administration Chapter 3 Installing the Server.
Guide To UNIX Using Linux Third Edition
Chapter 9 Extra Topics. The Kernel Core of the operating system Similar to UNIX kernel Originally developed and still controlled by Linus Torvalds uname.
Chapter 12 Drivers and the Kernel. Computer Center, CS, NCTU 2 Roles of Kernel  Components of a UNIX System User-level programs Kernel Hardware  Two.
Overview Basic functions Features Installation: Windows host and Linux host.
NDT Tools Tutorial: How-To setup your own NDT server Rich Carlson Summer 04 Joint Tech July 19, 2004.
Linux-MVME Targets Using Motorola Board Support
Introduction to The Linaro Toolchain Embedded Processors Training Multicore Software Applications Literature Number: SPRPXXX 1.
1 Introduction to Tool chains. 2 Tool chain for the Sitara Family (but it is true for other ARM based devices as well) A tool chain is a collection of.
File System and Directory Structure in Linux. What is File System In a computer, a file system is the way in which files are named and where they are.
Linux Operations and Administration
Guide To UNIX Using Linux Fourth Edition
Booting and boot levels
Manage Directories and Files in Linux
Guide to Linux Installation and Administration, 2e1 Chapter 3 Installing Linux.
1 SAM & OLAR. 2 Upon completion of this module, you will be able to: List significant changes to system administration tasks in HP-UX 11i Determine system.
Drivers and The Kernel Chapter 12 Presentation by: Kathleen Pensy.
1 Web Server Administration Chapter 3 Installing the Server.
1 What is a Kernel The kernel of any operating system is the core of all the system’s software. The only thing more fundamental than the kernel is the.
Managing Software Patches 10/15/ Introducing Solaris OE Patches A patch contains collection of files and directories Patch replaces existing files.
Chapter Two Exploring the UNIX File System and File Security.
Agenda Link of the week Use of Virtual Machine Review week one lab assignment This week’s expected outcomes Review next lab assignments Break Out Problems.
Troubleshooting and Performance
Guide to Linux Installation and Administration1 Chapter 4 Running a Linux System.
Manage Directories and Files in Linux. 2 Objectives Understand the Filesystem Hierarchy Standard (FHS) Identify File Types in the Linux System Change.
Chapter Two Exploring the UNIX File System and File Security.
Linux Kernel Management. Module 9 – Kernel Administration ♦ Overview The innermost layer of Linux operating system is the kernel, which is a thin layer.
Guide to Linux Installation and Administration, 2e1 Chapter 11 Using Advanced Administration Techniques.
1 FreeBSD Installation AFNOG X Cairo, Egypt May 2009 Hervey Allen.
System Administration – Part 2. Devices in UNIX are files: A device can be accessed with different file names All device files are stored in /dev or its.
CSC414 “Introduction to UNIX/ Linux” Lecture 2. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
Hp education services education.hp.com hp education services education.hp.com 1 HP World/Interex 2002 Linux Kernel Configuration and Patching Chris Cooper.
OS Project 0 February 25, Outline  Linux Installation  Linux Kernel Compilation  System Call Development  Kernel Modules / 452.
CS 245 – Part 1 Using Operating Systems and Networks for Programmers Jiang Guo Dept. of Computer Science California State University Los Angeles.
Lecture 02 File and File system. Topics Describe the layout of a Linux file system Display and set paths Describe the most important files, including.
The Kernel At a high level, the kernel in an operating system serves as the bridge between applications and the actual data processing of the hardware.
System initialization Unit objectives A.Outline steps necessary to boot a Linux system, configure LILO and GRUB boot loaders, and dual boot Linux with.
1 Setup and Compile Linux Kernel Speaker: Yi-Ji Jheng Date:
Thousands of Linux Installations (and only one administrator) A Linux cluster client for the University of Manchester A V Le Blanc I T Services University.
Rebuilding Linux Kernel Dedicated to penguin lovers everywhere 26 September 20161Rebuilding kernel by Visakh M R.
Linux Administration – Finding You Way on the Command Line The Linux File Directory or Tree.
Operating System Kernel Compilation
bitcurator-access-webtools Quick Start Guide
Guide to Linux Installation and Administration, 2e
UBUNTU INSTALLATION
Drivers and the kernel UNIX system has three layers: Kernel
CONFIGURING HARDWARE DEVICE & START UP PROCESS
Operating System Kernel Compilation
Exploring the UNIX File System and File Security
Operating Systems Lecture 4.
IS3440 Linux Security Unit 7 Securing the Linux Kernel
COP 4343 Unix System Administration
Drivers and the Kernel Chapter 12.
Operating System Kernel Compilation
Presentation transcript:

Drivers and the kernel1-1 Drivers and the kernel UNIX system has three layers: m The hardware m The operating system kernel m The user-level programs Kernel m Kernel hides the hardware, provides a abstract, high-level programming interface Process Signal and semaphores Virtual memory The filesystem Interprocess communication m Kernel contains device drivers that manage its interaction with specific pieces of hardware. m Size of kernel

Drivers and the kernel1-2 Kernel types Provide the kernel with explicit information about the hardware Depend on kernel prospects for devices on their own m Solaris: almost completely modular kernel m HP-UX: supports a relatively small and well- defined hardware base m FreeBSD: must be told explicitly at kernel compilation time about device m Linux: limited module support

Drivers and the kernel1-3 Kernel types Kernel build directory and location by system SystemBuild Directory Kernel Solaris/kernel/unix HP-UX/stand/stand/vmunix Linux/usr/src/linux/vmlinuz or /boot/vmlinuz FreeBSD/usr/src/sys/kernel

Drivers and the kernel1-4 Why Configure the kernel Generic kernel m Many device drivers m Optional packages Tailor the kernel for your need m Less memory m Well-tuned configuration Add support for new types of device m Some system is simple m Some may need to several steps. Read this: m Building the kernel is not difficult; its just difficult to fix when you break it. m Get a good reference book for your OS

Drivers and the kernel1-5 Configuring a Solaris Kernel Structured around loadable modules m Modules are stored in subdirectories of /kernel Current system configuration m Display loaded modules: modinfo [-c] m Show hardware configurations: prtconf m Display loadable modules, hardware configuration and some tunable kernel: Sysdef

Drivers and the kernel1-6 Configuring a Solaris Kernel Automatic configuration m Probe device and initialize a driver for each device The Solaris kernel area m /kernel Modules common to machines that share an instruction set m /platform/platform-name/kernel Modules specific to one class of hardware Platform example: ultra1, SUN-blade-100 Command: uname -i m /platform/hardware-class-name/kernel Modules specific to one class of hardware For example: sun3u, sun4u Command: uname –m m /usr/kernel

Drivers and the kernel1-7 Configuring a Solaris Kernel m Subdirs under each kernel dir: drvloadable modules for device drivers Note: you can specify the device specific configuration parameters here. miscLoadable object files for misc kernel routines cpuCPU-specific module for the UltraSPARC strmodSTREAMS modules schedOperating system schedulers sys loadable system calls fs Filesystem-related kernel modules

Drivers and the kernel1-8 Configuring a Solaris Kernel /etc/system m Master configuration file Take a look at your /etc/system in the lab –Long dev name comes from the link –Force to load certain module –Set the search path –Non default values for variables can be added with set command »Example: set maxusers=40 m Consulted at boot time Specify another /etc/system with boot –a Or boot with /dev/null if no good copy –You will be prompted to answer questions

Drivers and the kernel1-9 Accessing New Device Drivers Solaris drivers are usually distributed as a package m Run pkgadd Should you add new device drivers they should be installed in /kernel. You can m add drivers with the add_drv command, then run drvconfig m remove them with the rm_drv command. m Once the driver is installed and the new device connected reboot the system with: Ok boot -r

Drivers and the kernel1-10 Accessing New Device Drivers m Alternatively, you can create the file /reconfigure before rebooting. The kernel will then be reconfigured during the boot process. # touch /reconfigure # reboot m One of these procedures is required for all drivers not installed initially. It causes the kernel to properly recognize the new drivers during the boot process.

Drivers and the kernel1-11 Building an HP-UX kernel Use SAM for the first few time Kernel configuration file /stand/system Run mk_kernel to rebuild the kernel Copy the new kernel in place to /stand/vmunix

Drivers and the kernel1-12 Building an Tru64Unix kernel Digital UNIX recommends that you be in single user mode when building the kernel. m cp /vmunix /vmunix.save save the old kernel m cp /genunix /vmunix install the generic kernel to be the running kernel m /usr/sbin/shutdown -r +5 reboot the system m /usr/sbin/shutdown +1 Log on as root and take the system down to single user mode m mount /usr remount the /usr file system

Drivers and the kernel1-13 Building an Tru64Unix kernel m /usr/sbin/doconfig – you will be prompted for system configuration information. If you need to edit the resulting configuration file answer "yes" at the prompt. The new kernel will then be built and the path to it will be displayed. m mv /sys/{hostname}/vmunix /vmunix move the kernel from the path displayed in the step above to the root directory m /usr/sbin/shutdown -r now reboot the system m If the system fails to boot you can reboot to single user mode using the generic kernel (/genunix) and try again. The master configure file is /etc/sysconfigtab

Drivers and the kernel1-14 Configuring a Linux kernel Save the current kernel m #cp /vmlinuz /safe Save the current kernel source if applys m #cd /usr/src; tar zcvf old-tree.tar.gz Unpack the source code and apply the patches m #cd /usr/src m # tar xvfz XXX.gz m # zcat YYY??.gz | patch –p0

Drivers and the kernel1-15 Configuring a Linux kernel Use tool m make menuconfig m make xconfig m make config Building the linux kernel binary m Run make xconfig/menuconfig/config m Run make dep m Run make clean m Run make bzImage m Run make modules m Run make modules_install m Copy image file to /boot/vmlinuz m Config lilo/grub about the new kernel

Drivers and the kernel1-16 Configuring a Linux kernel /proc m Allow to view and set kernel options at run time m Are not remembered across reboots

Drivers and the kernel1-17 Loadable kernel modules in Linux Check the currently loaded module m Run lsmod Insert module m Run insmod/modprode m Can only be removed explicitly Remove a module m Run rmmod

Drivers and the kernel1-18 Summary Again, what we covered here does NOT intend to give you exact step by step instructions for a particular OS on a particular platform m The basic flow/idea remains same for a relatively long period of time for particular vendor. m Things change from one release to another and vendor to vendor m Check the vendors latest documents for: Release notes New feature updates Installation and upgrade documents System administration documents …