Tutorial and Demos on Linux Virtual Machine

Slides:



Advertisements
Similar presentations
Intro to Virtualization
Advertisements

Packaging a Presentation on a CD, using PowerPoint 2003 Multimedia Services at The Citadel Updated
Computer System Laboratory
VMWare Workstation Installation. Starting Vmware Workstation Go to the start menu and start the VMware Workstation program. *Note: The following instructions.
ComfortLink™ II Control. ComfortLink™ II Smart Control This is not just a thermostat. It’s an energy command center. Trane ComfortLink™ II is an easy-to-use,
NetAcumen ActiveX Download Instructions
Microprocessor Simulation
How to install the Zelle graphics package
1 Netfilter in Linux Bing Qi Department of Computer Science and Engineering Auburn university.
1 Introduction to Programming Environment Using MetroWerks CodeWarrior and Palm Emulator.
Installing geant4 v9.5 using Windows Daniel Brandt, 06 April 2012 Installing Geant4 v9.5 for Windows A step-by-step guide for Windows XP/Vista/7 using.
Installation Ubuntu for Libraries. Step 1: Download Head on to Pick Ubuntu LTS; just click the big orange.
VMWare Workstation Installation. Starting Vmware Workstation Go to the start menu and start the VMware Workstation program. *Note: The following instructions.
Myrtle Entertainment Network Scanner How to work your way to installing a program via Myrtle Entertainment Network Scanner.
SET UP COMPUTER ** PLEASE BE AWARE SCREENSHOTS MAY NOT MATCH **
WINDOWS 7 AND UBUNTU INSTALLING LINUX WITHIN WINDOWS.
Red Hat Installation. Installing Red Hat Linux is the process of copying operating system files from a CD, DVD, or USB flash drive to hard disk(s) on.
VMWare Workstation Installation. Starting Vmware Workstation Go to the start menu and start the VMware Workstation program. *Note: The following instructions.
Confidential [Offline] Regular Demo installation SOP for ME172V.
Operating System Program 5 I/O System DMA Device Driver.
One to One instructions Installing and configuring samba on Ubuntu Linux to enable Linux to share files and documents with Windows XP.
How to Download and Install a Sharp Print Driver on a Mac.
Copyright© 2003 Avaya Inc. All rights reserved Upgrade to Communication Manager 2.0 with Migration to Linux 8.0 Purpose: This presentation was prepared.
Kernel Development using Virtualization Installing VMWare and using a virtual machine to build and test a Linux Kernel.
For OS Experiments. What Do We Need? A Computer &
VMWare Workstation Installation. Starting Vmware Workstation Go to the start menu and start the VMware Workstation program. *Note: The following instructions.
NUMOSS NURUL ‘IZZATI BINTI OTHMAN A
IT 211 Project Integration and Deployment Lab #11.
Geo CE-XM ch 4 Edited 10/14/05 1 The XM is the newest of the rovers, and unlike other units, it comes with software installed on the unit as well as using.
CPSC 203 Introduction to Computers Lab 23 By Jie Gao.
Linux in a Virtual Environment Nagarajan Prabakar School of Computing and Information Sciences Florida International University.
ECT 250: Survey of E-Commerce Technology FrontPage Publishing pages Unix.
Activating Clarity  Activating Clarity  Activation  Online Activation  Fax Activation  Review and Verify Activation and License Terms  Updating.
1 ITI 1120 Lab # 1 An Introduction to the Lab Environment Contributors: G. Arbez, M. Eid, D. Inkpen, A. Williams, D. Amyot.
← Select Exchange Once logged in. ↓ click Join Course Icon.
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.
1 / 9 Printing the Return Within TaxWise Online © 2006, Universal Tax Systems, Inc. All Rights Reserved. Printing the Return Within TaxWise Online Objectives.
Regis: Academic Research Network: ARN ARN Getting Connected Drive Mapping SQL*Plus Spooling Your Work Presented by “SOETJAHJO”
Implementation of Embedded OS Lab3 Linux Kernel Modules.
General rules 1. Rule: 2. Rule: 3. Rule: 10. Rule: Ask questions ……………………. 11. Rule: I do not know your skill. If I tell you things you know, please stop.
LOGO System Call. Introduction System call is the mechanism used by an application program to request service from the OS. Users use it to communicate.
OS Project 0 February 25, Outline  Linux Installation  Linux Kernel Compilation  System Call Development  Kernel Modules / 452.
2007 TAX YEARERO TRAINING - MODULE 61 ERO (Transmitter) Training Module 6 Federal and State Installation and Updates.
Lab 12 Department of Computer Science and Information Engineering National Taiwan University Lab12 – Driver 2014/12/16 1 /21.
Installing Drivers on HP Plotter Step By Step Instructions by Plotter4u.
Subversion (SVN) is a widely used version control system and an essential piece of the MIMES collaborative modeling environment. It allows us to manage.
Virtual Machines Module 2. Objectives Define virtual machine Define common terminology Identify advantages and disadvantages Determine what software is.
 CSC 215 : Procedural Programming with C C Compilers.
Downloading and Installing GRASP-AF Workshop Ian Robson Information Analyst, North of England Cardiovascular Network.
How to use Drupal Awdhesh Kumar (Team Leader) Presentation Topic.
bitcurator-access-webtools Quick Start Guide
EE516: Embedded Software Project 1
CSC227: Operating Systems
Seamless Guest OS's and more!
Computer System Laboratory
Using Linux and Lab Setup OS Lab 1
Create A Virtual Machine
INSTALLING AND SETTING UP APACHE2 IN A LINUX ENVIRONMENT
Open your lesson using Adobe Reader XI. Fill in your answer
Intro to Kernel Modules and /proc
1. Open Visual Studio 2008.
Getting Started: Amazon AWS Account Creation
CS 6560 Operating System Design
Lab 4 Kernel Module Operating System Lab.
CS 6560 Operating System Design Kernel Loadable Modules
Implementation of Embedded OS
bitcurator-access-webtools Quick Start Guide
Operating System Kernel Compilation
Presentation transcript:

Tutorial and Demos on Linux Virtual Machine CSC 4320/6320 - Operating Systems Summer 2015

Outline How to install Virtual Machine(VM)? How to install a Linux Operating using VM? Install Guest Addition for Linux. Demo: linux Kernel module

How to install Virtual Machine?(1) Install a virtual machine, e.g. Virtual Box. Download Virtual Box from website https://www.virtualbox.org/wiki/Downloads . (Note:Please choose the right platform package for your host OS). Install Virtubal Box in your computer.

How to install Virtual Machine?(2) Once the installation is done, you can find a similar GUI for Virtual Box as follows……

How to install Virtual Machine?(2) Once the installation is done, you can find the GUI for Virtual Box.

How to install a Linux system using VM?(1) Install Ubuntu System using Virtual Box Download the latest Ubuntu system from website http://www.ubuntu.com/download/desktop. Follow the tutorial to install Ubuntu. Note: Please install a new Ubuntu instead try Ubuntu. The installation takes about 20 minutes.

How to install a Linux system using VM?(2) Once the installation is done, you can login in it and the system is as follows……

Install Guest Addition for Linux(1) Goal: enable other strong features(e.g. folder sharing with host , screen enlarging). Steps: In menu bar, choose Devices -> Insert Guest addition CD Image. Click Yes when asked to start VBOXADDITIONS. Authenticate the installation. The installation opens a terminal and displays the procedure. Press Return when it is finished. Log out and then log in.

Install Guest Addition for Linux(2) Share folders with host OS. Steps: Create a folder on Host computer. (e.g. shareName) Open Virtual Box and your Ubuntu System. In Menu Bar, select Devices-> Shared folder settings.

Install Guest Addition for Linux(3) Click at right most of popped up window to add a folder. Machine Folders are permanent folders that will be shared until you remove them, while Transient Folders are temporary and will be removed when the virtual machine restarts or shuts down.

Install Guest Addition for Linux(4) Select the folder path and choose Auto-mount and Make Permanent.

Install Guest Addition for Linux(5) Click Ok to finish the settings.

Install Guest Addition for Linux(6) Open a terminal Open the dash, type “terminal”, select Terminal from the appeared results. Type the following command sudo adduser $USER vboxsf Note: you have to add current user into group vboxsf by above command, otherwise you will be warned permission denied when access to the shared folder.

Install Guest Addition for Linux(7)

Install Guest Addition for Linux(8) Shut down Ubuntu, then reboot Virtual Box and Ubuntu. Find the shared folder sf_shareName in /media.

Demo: Linux Kernel Modules List all kernel modules loaded currently. $lsmod Module Size Used by Vboxsf 39690 1 ………… ………. …..

Demo: Linux Kernel Modules -----Part I (1) Create a Kernel Module “simple”. (Page 96-99 ) Create a program named simple.c (prints appropriate messages when the kernel module is loaded and unloaded). Create a Makefile for compiling the program.

simple.c #include <linux/init.h> #include <linux/module.h> /* Macros for registering module entry and exit points. */ #include <linux/kernel.h> module_init( simple_init ); /* This cis called when the module is loaded. */ module_exit( simple_exit ); int simple_init(void) MODULE_LICENSE("GPL"); { MODULE_DESCRIPTION("Simple Module"); printk(KERN_INFO "Loading Module\n"); MODULE_AUTHOR("SGG"); return 0; } /* This function is called when the module is removed. */ void simple_exit(void) { printk(KERN_INFO "Removing Module\n");

Makefile Note: Makefile should be in the same directory as simple.c obj-m += simple.o all: make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules clean: make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean Note: Makefile should be in the same directory as simple.c

Demo: Linux Kernel Modules -----Part I (2) Compile kernel module simple.c $make Note: if the compiling succeeds, several files are produced.

Demo: Linux Kernel Modules -----Part I (3) Load Kernel Module $sudo insmod simple.ko Check out contents in kernel log buffer. $dmesg

Demo: Linux Kernel Modules -----Part I (4) Remove Kernel Module $sudo rmmod simple Check out contents in kernel log buffer. $dmesg

Demo 1

Demo: Linux Kernel Modules -----Part II Create a Kernel Module “simple-solution”.(Page 99-101 ) Create a program named simple-solution.c. In the module entry point, create a linked list containing five struct birthday elements and traverse the linked list. The name of first struct birthday element should be your own name. In the module exit point, remove the elements from the linked list and return the free memory back to the kernel Create a Makefile for compiling the program.

simple-solution.c (incomplete version ) #include <linux/init.h> /* Create a linked list containing five struct birthday elements*/ #include <linux/module.h> #include <linux/kernel.h> #include <linux/list.h> /* Traverse the linked list */ #include <linux/slab.h> } struct birthday void simple_exit(void) { { int month; /* Remove the elements from the linked list and return the free memory back to the kernel */ int day; int year; char *name; struct list_head list; }; module_init( simple_init ); module_exit( simple_exit ); static LIST_HEAD(birthday_list); MODULE_LICENSE("GPL"); int simple_init(void) MODULE_DESCRIPTION("Kernel Data Structures"); MODULE_AUTHOR("SGG");

Makefile obj-m += simple-solution.o all: make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules clean: make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean Note: Makefile should be in the same directory as simple_solution.c

Demo 2

Practice project1 to-do list See Project 1 requirement from D2L. Download files from D2L and follow the steps. For Part II: Add codes in simple-solution.c based on the instruction in Project Part 2 (Page 99-101) of textbook. Compile simple-solution.c and then try to load and remove kernel module. Use dmesg to check out the kernel log content right after loading and removing kernel module. Save the kernel log contents into screenshots.

What to submit? A complete version of simple-solution.c Project report including required screenshots and source code of simple-solution.c (a sample is provided in D2L).