lab 1...

25
ศศศศศศศศ ศศศศศ ศศศศ 50523206025-9 ศศศ.ศศ 3 Lab 1 ตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตตต ตตตตตตต ตตตตตตตตตต 1. ศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศ 2. ศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศศ ตตตตตตตตตตตตตตต 1. ศศศศศศศศศศศศศศศศศศศศศศศศศศศ Linux ศศศศศ ศศศศศศศศศศศศศศศศศศศศศศ 2. ศศศศศศศศศศศศศศศศศศศศศศศศศศศศ ศศศศ ls , man , cd , pwd , less , cp , rm , tail , mv , cat , grep ศศศศศศศศศศศศศศศศศศศศศศศศศ ศศศศ 3. ศศศศศศศศศศศศศ VI Text Editor ศศศศศศศศ Text File ศศศศศศศศศศศศศศศศศศศศศศศศศศ ศศศศศศศศศศศศศศศศศศศศศ ศศศศศศศศศศศศศศศศศศศ ศศศศศศศศศศศศศศ ศศศ ศศศศศศศศศศศศศศศศศศศศศศศศศศศศ ศศศศศศศศศศ ศศศศศศศศศศศ

Upload: know2pro

Post on 27-Sep-2015

17 views

Category:

Documents


4 download

DESCRIPTION

Lab 1 ติดตั้งระบบปฏิบัติการลินุกซ์และคำสั่งพื้นฐาน (Ubuntu)

TRANSCRIPT

50523206025-9

50523206025-9 . 3

Lab 1 1. 2. 1. Linux 2. ls , man , cd , pwd , less , cp , rm , tail , mv , cat , grep 3. VI Text Editor Text File 1. Ubuntu Linux 9.07 - Virtual Box Ubuntu Linux

- Power on boot Ubuntu

Try Ubuntu without any change to your computer Ubuntu CD Install Ubuntu UbuntuCheck CD for Defects CD Test memory (RAM)

Boot from first harddisk Install Ubuntu

- CD

- ()

- ListBox

- Thailand

- ()

- Harddisk 10G Partition 1 9000 MB / (root directory) ext3 Partition 2 1735 MB swap

Partiton 1 Partition 2

- ? Password

-

- Ubuntu 30

- Restart CD (Unmount ISO ) Power on Ubuntu Login Password Ubuntu

2. ls (list) Directory File Directory

ls l file directory permission

ls a file directory ls la file directory permission

man (Manual) man ls ls q

cd (change directory)

Directory cd root directory rootcd Desktop directory Desktop

pwd (Print Working Directory)

less

space bar - less q less /etc/passwd passwd 1 spacebar

cp (Copy)

File Directory cp file1 file2 1 2 cp tim test tim test ( tim test Desktop)

rm (Remove)

rm file1 file1 rm r dir1 dir1 r Recursiverm testvi testvi

rm r test test

tail

10 tail -n filename tail /etc/passwd passwd 10

head

10 head -n filename head /etc/passwd passwd 10

head n 5 /etc/passwd passwd 5

mv (Move) mv file1 file2 1 2 mv tim test2 tim test2

cat (concatenate) cat /etc/passwd passwd

grep

grep root /etc/passwd root passwd

nl

nl

df

Harddisk

3. VI Text Editor

025-9 vi 025-9

vi Vi Text Editor I

enter , spacebar

esc x , DD ,zz Shift + : q! vi , w ( vi) cat 025-9

1. Directory Directory / (root) /bin Binary Linux /boot kernel Linux boot GRUB (GRand Undified Boot loader) LILO /dev Device tty(Terminal) hda(harddisk) /etc et cetera Configuration file (System administrator) Service /etc/init.d /home root /root /lib Library /lost+found (boot) fsck /media mount cdrom, thumb drive /mnt /opt third party software install /usr/local /proc /root home directory root /sbin root sudo /tmp boot /usr /var log E-mail 2. 2 file1 file2 file1 file2 file3 cat file1 file2$ cat file1

$ cat file2

cat > $ cat file1 > file3

file1 file3$ cat file2 >> file3

file 2 file3 >>

$ cat file3

file3

file3 file1 file2 ABCD file1 efgh file2 file3

$cut c 1-4 file1 > tmp1

cut 1-4 file1 tmp1

$cat tmp1

tmp1

$cut c 5-8 file2 > tmp2 cut 5-8 file2 tmp2

$cat tmp2 tmp2

$paste tmp1 tmp2 > file3 paste tmp1 tmp2 file3

$cat file3

cat file3