170 likes | 345 Views
計算機概論實習 Linux workstation. Week 3. Linux. Unix : AT&T Laboratories, 1969 Ken Thompson and Dennis Ritchie GNU : the GNU OS, “ Hurd ” GNU General Public License BSD : Berkeley Software Distribution, 1977 USL(AT&T) v. BSDi MINIX : Andrew S. Tanenbaum , 1987 16-bit, microkernel
E N D
計算機概論實習Linux workstation Week 3
Linux • Unix: AT&T Laboratories, 1969 • Ken Thompson and Dennis Ritchie • GNU: the GNU OS, “Hurd” • GNU General Public License • BSD: Berkeley Software Distribution, 1977 • USL(AT&T) v. BSDi • MINIX:Andrew S. Tanenbaum, 1987 • 16-bit, microkernel • Birth of Intel 386 (32-bit)
Freax! • Linux: Linus Torvalds • Monolithic kernel • 32-bit (Intel 386 \:D/) • GNU/Linux • (FYI) • Monolithic • Microkernel • Hybrid
Linux Distros • Fedora (Red Hat) • openSUSE (Novell) • Ubuntu (Canonical Ltd.) • Mandriva Linux (Madriva) • Debian • Mageia
NTUIM GNU/Linux Workstations • 140.112.106.6 (mercury) • 140.112.106.9 (mars)
SSH vs. Telnet • Both connect to remote servers • Telnet by default • Plain text • No encryption • No authentication • SSH • More secure • More overhead
PuTTY/PieTTY • A small and safe Telnet/SSH remote client • PuTTY • http://the.earth.li/~sgtatham/putty/latest/x86/putty.exe • PieTTY • http://ntu.csie.org/~piaip/pietty/ • Unicode 補完 • 多國語系 • Just input server’s address, tick SSH, and you’re on!
Uses • Compile your C/C++ code • OS (thread) • Network (socket) • Manage your files
UNIX File and Directory • File • A sequence of bytes • Directory • A file that includes info on how to find other files / vmunix dev bin lib usr etc console lp0 … csh … libc.a … include … passwd …
File Permission (1/2) Output of ls-l total 4 lrwxr-xr-x 1 test user 18 Aug 28 13:41 home -> /usr/people/maria/ -rw-r--r-- 1 test user 94 Aug 28 13:42 nothing.txt drwxr-xr-x 2 test user 9 Aug 28 13:40 test_dir/ Permissions File name Group Modify date File type Owner
File Permission (2/2) • File permissions • Permissions used to allow/disallow access to file/directory contents • Owner/Group/Other • Read (r) 4, write (w) 2, and execute (x) 1 • For owner, group, and world (everyone) • chmod <mode> <file(s)> • chmod 700 file.txt • chmodg+rw file.txt
Homework Linuxcommand
簡單的微練習 • DueDay:2012/10/3 計概課前 • 請到/home/r101042/labtemp • 複製execute_me 這隻程式到自己的資料夾(在labtemp裡面喔)下,然後執行這隻程式,並把結果輸出成 answer.txt • 在自己的資料夾底下 • 以vim編輯一個以自己學號為名的檔案,裡面打著自己的學號並存檔 • 用清單列出資料夾下的所有檔案或資料夾,把結果輸出成 result.txt • 用清單列出labtemp資料夾底下任何包含有 ”3” 的檔案或資料夾,把結果輸出成 special.txt
Q&A Thanks for attention!