Intro. To Unix commands For those who’ve never used Unix before Quick tutorial to let you move around your Unix Accounts No discussion of inner workings.

Slides:



Advertisements
Similar presentations
LIS651 lecture 5 direct use of wotan Thomas Krichel
Advertisements

Linux, it's not Windows A short introduction to the sub-department's computer systems Gareth Thomas.
A Guide to Unix Using Linux Fourth Edition
Learning Unix/Linux Bioinformatics Orientation 2008 Eric Bishop.
Cosc 4750 Getting Started in UNIX Don’t be afraid of the prompt, in linux it can be your best friend. In some cases, the only way to do certain things.
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.
ECT 250: Survey of e-commerce technology Publishing pages on a Unix system.
1 Computer Files Stored on disks, CDs, tapes, in memory. Types of files: plain text, formatted (.doc.xls etc…), binary (executable). A disk has a directory.
George Blank University Lecturer. Creating A Web Site at NJIT Professor Blank.
Working Environment - - Linux - -.
File Security. Viewing Permissions ls –l Permission Values.
What is Unix? A multi-user networked operating system –“Operating System” Handles files, running other programs, input/output Looks like DOS…but more powerful.
Using Macs and Unix Nancy Griffeth January 6, 2014 Funding for this workshop was provided by the program “Computational Modeling and Analysis of Complex.
The Unix Environment and Compiling. Getting Set Up Your programs will be compiled and tested on the Departmental server ‘linprog’ The linprog servers.
MCB Lecture #3 Sept 2/14 Intro to UNIX terminal.
Help session: Unix basics Keith 9/9/2011. Login in Unix lab  User name: ug0xx Password: ece321 (initial)  The password will not be displayed on the.
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”
Computing II - Problem Session - 1. Some Notes on Input/Output. In C++ you used two primary functions to manage console-directed Input and Output.
CHAPTER 1 UNIX FOR NONPROGRAMMERS By U ğ ur Halıcı.
1 Unix Text Editors Creating files on the Unix system.
Linux Directory Navigation. File & Directory Commands This is a minimal list of Unix commands that you must know for file management: ls (list) mkdir.
Unix Command Project Justin Rogers for LS 560 Spring 2015.
Linux environment ● Graphical interface – X-window + window manager ● Text interface – terminal + shell.
Chapter 3 Mastering Editors
Essential Unix at ACEnet Joey Bernard, Computational Research Consultant.
File Permissions. What are the three categories of users that apply to file permissions? Owner (or user) Group All others (public, world, others)
AN INTRO TO UNIX/LINUX COMMANDS BY: JIAYANG WANG.
The UNIX development environment CS 400/600 – Data Structures.
Carnegie Mellon Linux Boot Camp Jenna MacCarley, Peter Pearson, Shashank Goyal 9/19/2015.
PROGRAMMING PROJECT POLICIES AND UNIX INTRO Sal LaMarca CSCI 1302, Fall 2009.
Intro. To Unix commands For those who’ve never used Unix before Quick tutorial to let you move around your Unix Accounts No discussion of inner workings.
Session 2 Wharton Summer Tech Camp Basic Unix. Agenda Cover basic UNIX commands and useful functions.
CS 590 Programming Environments with UNIX. Computer Lab Account Course Homepage
COP3502: Introduction to Computer Science Yashas Shankar.
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.
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.
CGS 3460 Why we choose UNIX n Powerful lMulti-user operating system lGood programming tools Most heavy-duty database management systems started out on.
Unix Editors. u Editors in Unix come in two general flavours: –modal editors have "modes" v generally input mode and command mode –input mode allows entry.
Basic Unix Commands CGS 3460, Lecture 6 Jan 23, 2006 Zhen Yang.
1 Remote Access Telnet Telnet FTP FTP. 2 Applications and Communications Telnet Telnet  Program for accessing systems remotely.  Available on Windows.
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.
Intro. To Unix commands For those who’ve never used Unix before Quick tutorial to let you move around your Unix Accounts No discussion of inner workings.
Unix Servers Used in This Class  Two Unix servers set up in CS department will be used for some programming projects  Machine name: eustis.eecs.ucf.edu.
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.
ICE UNIX TUTORIAL. File System Commands cd – change directory cd – change directory ls – list contents ls – list contents rm – remove/delete rm – remove/delete.
General Computer Science for Engineers CISC 106 Lecture 03 James Atlas Computer and Information Sciences 6/15/2009.
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).
CS 120 Extra: The CS1 Server Tarik Booker CS 120.
Learning Unix/Linux Based on slides from: Eric Bishop.
General Computer Science for Engineers CISC 106 Lecture 03 James Atlas Computer and Information Sciences 9/9/2009.
By Justin Higgins. What is a text editor? If you’ve ever used Microsoft word you know what a text editor is (albeit a bloated one). When you write a program.
Day11a FTP. File Transfer Protocol. –Used to move files from one machine to another. Windows -> Unix Unix -> Windows Unix -> Unix Windows -> Windows etc.
UNIX Basics Matt Hayward October 18, 2016 LS560 – Information Technology for information professionals.
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.
Tutorial of Unix Command & shell scriptS 5027
Development Environment Basics
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.
Web Programming Essentials:
Andy Wang Object Oriented Programming in C++ COP 3330
Tutorial of Unix Command & shell scriptS 5027
Tutorial of Unix Command & shell scriptS 5027
WELCOME FREESURFER COURSE ATTENDEES!
Web Programming Essentials:
Tutorial of Unix Command & shell scriptS 5027
A Brief Overview of Unix
Andy Wang Object Oriented Programming in C++ COP 3330
Using emacs and G++ at U. W.
Presentation transcript:

Intro. To Unix commands For those who’ve never used Unix before Quick tutorial to let you move around your Unix Accounts No discussion of inner workings of Unix –Take Operating Systems – CSCI-4210 Comparisons to Windows/DOS commands

What are the machines? rcs.rpi.edu – takes you to a random OS rcs-sun1.rpi.edu – takes you to a Sun machine rcs-ibm1.rpi.edu – takes you to an IBM machine There are others, but these should be more than enough for this course. If you’re on campus, you must use SSH (instead of Telnet) to connect to these machines. Download TeraTerm SSH or SecureCRT

Very basics ‘ls’ - get directory listing –DOS: ‘dir’ ‘ls –l’ – get long file listing ‘cd’ – change directory ‘mkdir’ – make directory –DOS: md ‘rm’ – remove a file –DOS: ‘del’ ‘rmdir’ – remove directory

More basics ‘more’ – contents of a file –DOS: ‘type’ ‘cp’ – copy a file –DOS: ‘copy’ ‘mv’ – move a file –DOS: ‘move’

chmod Change mode (permissions) of file/directory using ‘ls –l’, 10 fields of information are shown ex: drwxrw-r— first position: ‘d’ (directory) or ‘-’ (file) next three: user permissions: –‘r’ – read permissions –‘w’ – write permissions –‘x’ – Execute permissions next three: group permissions last three: world permissions

chmod continued permissions are represented as octal numbers rwxrwxrwx = = 777 rwxrw-r-- = = 764 rw = = 600 etc. chmod mode file ex: chomd 755 script.plx –Give yourself all permissions, group and world read and execute permissions

User Friendly chmod Can specify modes without using octal representations. Still a 3 character code. –First char: u (user), g (group), o (other) –Second: + (add permissions) or - (remove permissions) –Third: r (read), w (write), x (execute) chmod u+x file.pl –give yourself execute permissions on file.pl chmod o+r file.pl –give others (ie, world) read permissions on file.pl

Windows vs Unix They don’t like each other. Many problems can (and will) arise due to difference in end-of-line character. –Unix: \n –Windows: \r\n –In Unix, a Windows \r can show up as ^M –In Windows, a Unix \n (missing the \r) can show up as a □ and no newline (at least in Notepad – Wordpad is mildly smarter) To change a file from Windows to Unix, use the command: –dos2unix –Ex: dos2unix oldfile newfile –unix2dos also exists If you *ever* save a file in Windows and then transfer it to Unix, you should run dos2unix

Transferring files To get a file from your Windows PC to your Unix RCS account: Use an ftp client (ex: CuteFTP) or the default Windows ftp program –Ask Paul for help with this if you don’t know ftp –ftp address of RCS is ftp.rpi.edu Or use an SCP client (ex: WinSCP) –Download from –Connect to rcs.rpi.edu

Creating a file on RCS Many options. Two most common: emacs and vi (“vee-eye”, not “vye” or “six”) –Which is ‘better’ is a cause of online holy wars Many many tutorials online to help you with either program Paul can assist you if you’re using emacs (he’s on the anti-vi side of the holy wars)

Beginning emacs shortcuts CTRL-X CTRL-F – open new or existing file CTRL-X S – prompt to save file CTRL-X CTRL-S – save file without prompt CTRL-A – beginning of line CTRL-E – end of line CTRL-X CTRL-J – jump to line #.... CTRL-K – Cut to end of line CTRL-Y – Paste most recent cut ESC-X – many mini-buffer commands (replace, undo, search, etc (tab-complete for list) ) CTRL-G – quit mini-buffer (if you typo when making a comand) CTRL-X CTRL-C – Exit emacs

For more help… If you find yourself unable to do something in this class because of a lack of familiarity with Unix, ask Paul. He’ll be happy to help.