1 / 26

Introduction to Linux/Unix

Introduction to Linux/Unix. Working in the CS Environment. Using the CS Labs. DO NOT REBOOT MACHINES one tiny little exception (Morphs in S311) Linux machines Commons Stealths S311 Morphs, S320 Penguins, S315 Stealths, S360 Stealths Windows machines Commons Spinks

winola
Download Presentation

Introduction to Linux/Unix

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Introduction to Linux/Unix Working in the CS Environment

  2. Using the CS Labs • DO NOT REBOOT MACHINES • one tiny little exception (Morphs in S311) • Linux machines • Commons Stealths • S311 Morphs, S320 Penguins, S315 Stealths, S360 Stealths • Windows machines • Commons Spinks • S311 Morphs (These are dual boot) • Macs • S360 (Not yet installed… look for them!)

  3. Lab Access • Available 24-7 • Access always through NE stairwell or the main door on the ground floor • Elevator is restricted to G and 3 between 11 PM and 7 AM

  4. Lab Help • Help Desk -- course-related problems • Merlin/Seth (S307) -- hardware or software issues • iHelp -- for everything, 24-7

  5. Policies • Strict -- no food or drink • Nice -- lidded bottles/cups are unofficially permitted • Use the lounge for eating/drinking and other social activities • Be nice and relatively quiet -- especially in labs

  6. More Polices • No kettles, microwaves, or hotplates • Laptop Polices • If you *must* use power at a non-laptop station, unplug the monitor for the duration of your use. Replace when done! • Wireless is everywhere, but contact ITS for set-up • NEVER unplug a network cable from a computer or the wall • NEVER turn off or unplug a computer

  7. What is Linux • OS • Open source • Multiple implementations • Based on Unix

  8. Using Linux • Just like Windows (kinda) • GUI elements • Multiple desktops • Command line

  9. Philosophy of Linux • Many small programs, not one big program • Matches and exceeds functionality of other OS’s • If it’s not there, add it

  10. Creating Files • Kate

  11. The Command Line • Lots and lots of tools that allow you to… • move around • create and remove • edit • pretty well anything else

  12. ls: List files Usage: ls [options] Common options -l (long format) -R (recursive) -t (sort by time) eg: ls -lt cd: Change Directory Usage: cd [pathname] Common options None eg: cd ~/homework/111 Where am I?

  13. mkdir: Make Directory usage: mkdir [directory name] e.g.: mkdir cmpt111 Note: Naming conventions are important to follow Directories

  14. What’s in a Name? • Case sEnsItive • Reserved characters: *.|>< and more • Spaces are a pain • Numbers are allowed, even at the beginning

  15. mv: Move usage: mv [source] [destination] e.g.: mv myfile.txt cmpt111 mv myfile.txt cmpt111/ mv myfile.txt cmpt111/myfile.txt mv myfile.txt cmpt111/myfiletoo.txt Whoops…. we just changed the name. Moving and Renaming

  16. Copying cp: Copy usage: cp [source] [destination] e.g.: cp myfile.txt cmpt111/ cp myfile.txt cmpt111/myfiletoo.txt cp myfile.txt cmpt111 cp myfile.txt cmpt111/myfile.txt

  17. Removing (Deleting) rm: Remove usage: rm [options] [filename] common options: • -r or -R (recursively) • -f (force) • -d (remove directories) e.g.: rm -r cmpt111 rm -rf cmpt111 rm -d * rm myfile.txt

  18. Wildcards and other cool stuff * Any number of any characters ? A single unknown character e.g.: rm m?file.* Also… • Command completion • Command history • Paste buffer -- highlight and middle click(clipboard)

  19. More Cool Stuff ~/ == home ../ == up a level ./ == current level ^C (Control-C) == Emergency Quit exit == quit current shell session

  20. Remote Log-in ssh -- Secure Shell usage: ssh [options] [username]@[hostname] common options: -l [username] login name -D [port] port e.g.: ssh -l amg918 stealth16.usask.ca ssh amg918@stealth16.usask.ca

  21. Where should I ssh? In order…. • stealth37 to stealth50 • stealth20 to stealth36 • stealth1 to stealth19 • penguin Names of machines are “stealth”, “morph”, and “penguin”

  22. How Do I Remember This? • man • apropos

  23. One more useful thing… You have disk space! How much…? • quota [username] • df -h • du -hs

  24. General Comments • Printing: • Get your pages through PAWS • Three printers: • Spinks360bw1 • Spinks315bw1 • Spinks311bw1 • Don’t print to any printers not labelled bw1, it won’t work • Help is available from Seth/Merlin for printing problems

  25. ACM Programming Contest • Every year we field a few teams • Several practice runs • Faculty coach • Even 1st-years can win!

  26. Assignment • Navigate to /www/docs/bootcamp • Copy beginner.txt to your own folder space • Open the assignment in a text editor • Start doing it…. in the commons.

More Related