Learning basic Unix command IT 325 operating system.

Slides:



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

Pre-Assessment Questions
Unix. Outline Commands Environment Variables Basic Commands CommandMeaning lslist files and directories ls -alist all files and directories mkdirmake.
ATS Programming Short Course I INTRODUCTORY CONCEPTS Tuesday, Jan. 27 th, 2009 Essential Unix Commands.
Exploring the UNIX File System and File Security
Linux+ Guide to Linux Certification, Second Edition
Linux Files. Files and directories As in Windows directories are structures which contain –Other directories –Files.
Guide To UNIX Using Linux Third Edition
UNIX Overview. 2 UNIX UNIX is a multi-user and multi-tasking operating system. Multi-tasking: Multiple processes can run concurrently. Multi-user: different.
Basic UNIX © McGraw Hill All rights reserved.
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.
CS 141 Labs are mandatory. Attendance will be taken in each lab. Make account on moodle. Projects will be submitted via moodle.
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
COMP1070/2002/lec4/H.Melikian COMP1070 Lecture #5  Files and directories in UNIX  Various types of files  File attributes  Notion of pathname  Commands.
Notes Assignment #1 is due next Friday by 11:59 pm via Test #1 will be held Thursday February 18 at the start of class (one period long) Format:
Introduction to UNIX donna Bair-Mundy. What is UNIX? Applications OperatingSystem Hardware.
File Systems Sources and Resources: 1. A Students Guide to UNIX, by Hahn 2. Paula Davidson’s Handout on UNIXHandout on UNIX.
1 THE UNIX FILE SYSTEM By Chokechai Chuensukanant ID COSC 513 Operating System.
The file structure and related utilities CS240 Computer Science II.
Unix Primer. Unix Shell The shell is a command programming language that provides an interface to the UNIX operating system. The shell is a “regular”
© Crown copyright Met Office An Introduction to Linux PRECIS Workshop, University of Reading, 23rd – 27th April 2012.
Lesson 7-Creating and Changing Directories. Overview Using directories to create order. Managing files in directories. Using pathnames to manage files.
Linux Directory Navigation. File & Directory Commands This is a minimal list of Unix commands that you must know for file management: ls (list) mkdir.
Working with Files Chapter 5. Display a Calendar Display a calendar for a specific month – cal Display a calendar for a specific year – cal 2000.
1 Lecture 2 Working with Files and Directories COP 3344 Introduction to UNIX.
Basic unix commands that everyone should know (Even if you have a mac) Slightly more advanced:
Linux+ Guide to Linux Certification, Second Edition
The UNIX development environment CS 400/600 – Data Structures.
Chapter Two Exploring the UNIX File System and File Security.
BIF713 Basic Unix/Linux Commands Getting Help with Commands.
Chapter Two Exploring the UNIX File System and File Security.
File Security and Permissions. File Permissions (1) u With respect to a particular file, Unix divides the set of all users on a system into three categories:
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.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: whereis, which, whoami, finger, passwd, cal, date Working with Files: cat, more, less.
1May 16, 2005 Week 2 Lab Agenda Command Line FTP Commands Review More UNIX commands to learn File name expansion - * Introduction of vi.
E X C E E D I N G E X P E C T A T I O N S Basic LINUX Linux System Administration Dr. Hoganson Kennesaw State University Operating Systems Directory structure:
Linux+ Guide to Linux Certification, Third Edition
Linux+ Guide to Linux Certification, Third Edition
Λειτουργικά Συστήματα – Lab2 Γιάννης Πετράκης. Directory Navigation and Control  The Unix file system is set up like a tree branching out from the root.
File Systems, telnet and ftp Sources and Resources: 1. A Students Guide to UNIX, by Hahn 2. Paula Davidson’s Handout on UNIXHandout on UNIX.
1 Lecture 2 Working with Files and Directories COP 3353 Introduction to UNIX.
Makefiles1 MAKEFILES Purpose: contain UNIX commands and will run them in a specified sequence. Syntax Definition : { Section-name: {unix command #1} …
Basic Unix Commands & GCC Saurav Karmakar Spring 2007.
UNIX filesystem CS 2204 Class meeting 2 *Notes by Doug Bowman and other members of the CS faculty at Virginia Tech. Copyright
Linux Stuff Last Update Copyright 2014 Kenneth M. Chipps Ph.D. 1.
1 Introduction to Unix. 2 What is UNIX?  UNIX is an Operating System (OS).  An operating system is a control program that helps the user communicate.
 Last lesson, the Windows Operating System was discussed along with the Windows command shell  Unix is a computer operating system, that similarly manages.
The Unix File sytem. Introduction Tree structure …
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.
Introduction to UNIX and Linux.  Written by Dennis Ritchie and Ken Thomsom at Bell Labs in 1969  Initially written in assembly language and a high-level.
File Management commands cat Cat command cat cal.txt cat command displays the contents of a file here cal.txt on screen (or standard out).
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.
Learning Unix/Linux Based on slides from: Eric Bishop.
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.
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.
Some Linux Commands.
The Command Prompt Commands are the way to “do things” in Unix
Eric Shook Department of Geography Kent State University
Exploring the UNIX File System and File Security
The Unix File System.
Introduction Paul Flynn
Module 6 Working with Files and Directories
January 26th, 2004 Class Meeting 2
Presentation transcript:

Learning basic Unix command IT 325 operating system

1. Listing files and directories ls (list) When you first log in, your current working directory is your home directory. This is where your personal files and subdirectories are saved. To find out what is in your home directory, type: % ls (short for list)

2, Making Directories mkdir (make directory) We will now make a subdirectory in your home directory to hold the files you will be creating. To make a subdirectory called unixstuff in your current working directory type % mkdir unixstuff To see the directory you have just created, type: % ls

3. Changing to a different directory cd (change directory) The command cd directory means change the current working directory to 'directory'. The current working directory may be thought of as the directory you are in, i.e. your current position in the file-system tree. To change to the directory you have just made, type % cd unixstuff Type ls to see the contents (which should be empty) Exercise 1 Make another directory inside the unixstuff directory called backups

3. Changing to a different directory (..) means the parent of the current directory, so typing % cd.. will take you one directory up the hierarchy (back to your home directory). Try it now. Note: typing cd with no argument always returns you to your home directory. This is very useful if you are lost in the file system.

4. print working directory pwd (print working directory) % pwd

5. Displaying the contents of a file on the screen cat (concatenate) The command cat can be used to display the contents of a file on the screen. Type: % cat services

6. Copying Files cp (copy) cp file1 file2 is the command which makes a copy of file1 in the current working directory and calls it file2

7. Moving files mv (move) mv file1 file2 moves (or renames) file1 to file2

8. Removing files and directories rm (remove), rmdir (remove directory) To delete (remove) a file, use the rm command. You can use the rmdir command to remove a directory (make sure it is empty first).

Example Example: % cp services tempfile.txt % ls (to check if it has created the file) % rm tempfile.txt % ls (to check if it has deleted the file)

9. Change Access Permissions chmode (change mode) Example : chmod 444 file - Allow read permission to owner and group and world chmod 777 file - Allow everyone to read, write, and execute file

Summary commandmeaning lslist files and directories mkdirmake a directory cd directorychange to named directory cdchange to home directory cd..change to parent directory pwd display the path of the current directory catdisplay a file cp file1 file2copy file1 and call it file2 mv file1 file2move or rename file1 to file2 rm fileremove a file