CSE1222: Unix IntroThe Ohio State University1. Common Directory Commands  lsList directory contents  cd {dir}Change working directory to {dir}  pwdPrint.

Slides:



Advertisements
Similar presentations
UNIX Overview. 2 UNIX UNIX is a multi-user and multi-tasking operating system. Multi-tasking: Multiple processes can run concurrently. Example: different.
Advertisements

Introduction to the Omega Server CSE Overview Intro to Omega Basic Unix Command Files Directories Printing C and C++ compilers GNU Debugger.
ENEE150: Discussion 1 Section 0104 Please Sit Down at a Computer and Login!
Unix. Outline Commands Environment Variables Basic Commands CommandMeaning lslist files and directories ls -alist all files and directories mkdirmake.
NETW-240 Shells Last Update Copyright Kenneth M. Chipps Ph.D. 1.
Dayu Zhang 9/8/2014 Lab02. Example of Commands pwd --- show your current directory This is home of venus, not your home directory Tilde: means you are.
Linux & Applications Sean GavinWayne State University multi-user environment -- log in: user name and password -- you never turn the computer on or off.
CS 202 Computer Science II Lab Fall 2009 August 27.
1 Basics of Linux On linux machine: Login at your home directory Open a “shell” or “terminal” or “xterm” workspace (4) On windows machine Intall linux.
Unix Basics. Systems Programming: Unix Basics 2 Unix Basics  Unix directories  Important Unix file commands  File and Directory Access Rights through.
Embedded Programming and Robotics Lesson 13 Basic Linux 1.
A Mini UNIX Tutorial. What’s UNIX?  An operating system run on many servers/workstations  Invented by AT&T Bell Labs in late 60’s  Currently there.
Using Macs and Unix Nancy Griffeth January 6, 2014 Funding for this workshop was provided by the program “Computational Modeling and Analysis of Complex.
Systems Programming Concepts
Learning basic Unix command IT 325 operating system.
1 THE UNIX FILE SYSTEM By Chokechai Chuensukanant ID COSC 513 Operating System.
Lesson 1. PC vs. Multi-user System  Personal Computer – each user gets his/her own processor (or multicore processor).  Multi-user system – The processor,
Essential Unix at ACEnet Joey Bernard, Computational Research Consultant.
The UNIX development environment CS 400/600 – Data Structures.
1 N305 C Programming. 2 Objectives for the Lab ä Learn problem solving strategies ä Achieve intermediate knowledge of C Programming Language ä Gain experience.
PROGRAMMING PROJECT POLICIES AND UNIX INTRO Sal LaMarca CSCI 1302, Fall 2009.
CPSC 217 T03 Week I Part #1: Unix and HELLO WORLD Hubert (Sathaporn) Hu.
Chapter 0 A “Quick-Start” into the UNIX Operating System.
Next Unix Topics Tuesday, 2/11 & 18/2014. Change Password (by 2/14/14) ssh to account on – faclinux.cse.ohio-state.edu – stdlinux.cse.ohio-state.edu passwd.
Second edition Your UNIX: The Ultimate Guide Das © 2006 The McGraw-Hill Companies, Inc. All rights reserved. UNIX Commands cal – will print a calendar.
L&T Infotech1 UNIX – Getting Started - Aneesh Ramani.
November 5, 2015CIS 118 Intro to UNIX What’s a Unix? Unix is an Operating System Designed for high-traffic usage Many variants –Linux, BSD: free versions.
Introduction to UNIX Geraint Vaughan. What is UNIX? Command-line operating system (not point- and click) Designed for ‘experts’ Lots of different variants.
Welcome to CS323 Operating System lab 1 TA: Nouf Al-Harbi NoufNaief.net.
Basic Unix Commands CGS 3460, Lecture 6 Jan 23, 2006 Zhen Yang.
Unix, Linux, DOS, Windows Command Line CSE 660 May 12, 2008.
1May 16, 2005 Week 2 Lab Agenda Command Line FTP Commands Review More UNIX commands to learn File name expansion - * Introduction of vi.
CSE 374 Programming Concepts & Tools Hal Perkins Fall 2015 Lecture 2a – A Unix Command Sampler (Courtesy of David Notkin, CSE 303)
COP3502: Introduction to Computer Science Yashas Shankar Lecture #2.
More on Using onyx 8/28/13. Program 1 Due a week from today. See website for details.
ENEE150: Discussion 1 Section 0104/0105 Please Sit Down at a Computer and Login!
Basic Unix Commands & GCC Saurav Karmakar Spring 2007.
AN INTRO TO UNIX/LINUX COMMANDS BY: JIAYANG WANG.
 Last lesson, the Windows Operating System was discussed along with the Windows command shell  Unix is a computer operating system, that similarly manages.
Unix Fundamentals CS 127. File navigation cd - change directory cd /var/log cd /etc/apache2 cd ~/Desktop ~ is a shortcut for the home directory.
Basic Unix Commands. Listing files and directories ● ls:command is used to list the files and ● directories in present working directory ● ls command.
ICE UNIX TUTORIAL. File System Commands cd – change directory cd – change directory ls – list contents ls – list contents rm – remove/delete rm – remove/delete.
Learning basic Unix command It 325 operating system.
Chapter 2: Exploring the UNIX File System (For Tuesday Section) File and File Systems.
Linux Tutorial Lesson Two *Getting Help in Linux *Data movement and manipulation *Relative and Absolute path *Processes Note: see chapter 1,2,3 from Linux.
CS 120 Extra: The CS1 Server Tarik Booker CS 120.
Linux CSE 1222 CSE1222: Lecture 1BThe Ohio State University1.
1 N305 C Programming. 2 Objectives for the Lab ä Learn problem solving strategies ä Achieve intermediate knowledge of C Programming Language ä Gain experience.
Tutorial Six Linux Basics CompSci Semester Two 2016.
ENEE150 Discussion 01 Section 0101 Adam Wang.
UNIX To do work for the class, you will be using the Unix operating system. Once connected to the system, you will be presented with a login screen. Once.
A “Quick-Start” into the UNIX Operating System
Commands Basic syntax of shell commands UNIX or shell commands have a basic structure command -options target command comes first (such as cd or ls) any.
UNIX The Basics Source:
Andy Wang Object Oriented Programming in C++ COP 3330
Useful Linux Commands.
Eric Shook Department of Geography Kent State University
Welcome to CSCI 230! Problem Solving using C
CSE 374 Programming Concepts & Tools
Welcome to CSCI 230! Problem Solving using C
CS 60 Discussion Review.
Operating Systems and Using Linux
Operating Systems Lecture 5.
The Unix File System.
Lab 00 Discussion Linux Basics
Andy Wang Object Oriented Programming in C++ COP 3330
Using emacs and G++ at U. W.
Module 6 Working with Files and Directories
Lab 2: Terminal Basics.
Presentation transcript:

CSE1222: Unix IntroThe Ohio State University1

Common Directory Commands  lsList directory contents  cd {dir}Change working directory to {dir}  pwdPrint working directory  mkdirMake a new directory  rmdir {dir}Delete directory {dir} CSE1222: Unix IntroThe Ohio State University2

Example > cd lab1 > pwd /home/3/yourusername/lab1 > ls a.out first.cppfirst.cpp~ > cd > pwd /home/3/yourusername CSE1222: Unix IntroThe Ohio State University3

Example > cd > pwd /home/3/yourusername > mkdir lab2 > cd lab2 > pwd /home/3/yourusername/lab2 > ls > CSE1222: Unix IntroThe Ohio State University4

Common File Commands  cp {f1} {f2}Copy file {f1} into {f2}  mv {f1} {f2}Move file {f1} to {f2}  rm {f1}Delete file {f1}  g++ {f1} Compile C++ file {f1} using g++ compiler. CSE1222: Unix IntroThe Ohio State University5

Example > cd > pwd /home/3/yourusername > mkdir lab2 > cp lab1/first.cpp lab2/second.cpp > cd lab2 > ls second.cpp > CSE1222: Unix IntroThe Ohio State University6

Example > cd lab2 > ls second.cpp > g++ second.cpp > ls a.outsecond.cpp > rm a.out > ls second.cpp > CSE1222: Unix IntroThe Ohio State University7

More File Commands  more {f1}View file {f1}  less {f1}View file {f1}  emacs {f1}Edit file {f1} using emacs  lp –d lj_cl_112_a {f1} Print file {f1} on printer lj_cl_112_a. CSE1222: Unix IntroThe Ohio State University8

More Unix Commands  control-CInterrupt a program or command  control-ZSuspend a program  bgPlace suspended program in background.  fgPlace suspended program in foreground.  jobsList background programs. CSE1222: Unix IntroThe Ohio State University9

Example of Background Jobs > emacs first.cpp & [1] > jobs [1] + Running emacs first.cpp > emacs second.cpp & [2] > jobs [1] + Runningemacs first.cpp [2] – Runningemacs second.cpp CSE1222: Unix IntroThe Ohio State University10

Example of Background Jobs > jobs [1] + Runningemacs first.cpp [2] – Runningemacs second.cpp > fg emacs first.cpp Suspended > bg [1] emacs first.cpp & CSE1222: Unix IntroThe Ohio State University11

emacs Example > emacs first.cpp g++ first.cpp CSE1222: Unix IntroThe Ohio State University12

emacs Example > emacs first.cpp g++ first.cpp ls CSE1222: Unix IntroThe Ohio State University13

emacs Example > emacs first.cpp g++ first.cpp ls Why won’t my computer respond? What’s wrong? CSE1222: Unix IntroThe Ohio State University14

emacs Example > emacs first.cpp g++ first.cpp ls Why won’t my computer respond? What’s wrong? Please help me Mr. Instructor. CSE1222: Unix IntroThe Ohio State University15

emacs Example Either:  Use the ‘&’ to place the emacs program in background, i.e.: > emacs first.cpp & [1] > Or:  Close the emacs window before issuing any other commands. > emacs first.cpp > CSE1222: Unix IntroThe Ohio State University16

List of Common Unix Commands  lsList directory contents  cd {dir}Change working directory to {dir}  pwdPrint working directory  mkdirMake a new directory  rmdir {dir}Delete directory {dir}  cp {f1} {f2}Copy file {f1} into {f2}  mv {f1} {f2}Move file {f1} to {f2}  rm {f1}Delete file {f1}  g++ {f1}Compile C++ file {f1} using g++ compiler  more {f1}View file {f1}  less {f1}View file {f1}  emacs {f1}Edit file {f1} using emacs  lp –d lj_cl_112_a {f1}Print file {f1} on printer lj_cl_112_a  control-CInterrupt a program/command  control-ZSuspend a program  bgPlace suspended program in background.  fgPlace suspended program in foreground.  jobsList background programs. CSE1222: Unix IntroThe Ohio State University17