LINUX

UAS LINUX
Nama  : AGUSMAN MUBARAK
Nim     : 1802031
Kelas   : TI 3 A

A. Soal 1

1. Buat folder “NIM_UAS”.
mkdir 1802031_uas

2. Didalamnya buat folder Epithet , Malevolent, Tyrotoxism.
Cd 1802031_UAS
1802031_UAS mkdir Epithet
1802031_UAS mkdir Malevolent
1802031_UAS mkdir Tyrotoxism

3. Copy Folder Malevolent Ke Folder Epithet.
1802031_UAS cp –r Malevolent ~/1802031_UAS/Epithet

4. Rename Folder Tryrotoxism menjadi Quiescent.
Cd ~
mv 1802031_UAS/Tyrotoxism 1802031_UAS/Quiscent

5. Copy folder Epithet kedalam folder Malefolent..
Cd 1802031_UAS
1802031_UAS cp –r Epithet ~/1802031_UAS/Malevolent

6. Rename nama folder NIM_UAS/Malevolent/Epithet/Malevolent menjadi Tyrotoxism.
Cd ~
mv 1802031_UAS/Malevolent/Epithet/Malevolent 1802031_UAS/Malevolent/Epithet/Tyrotoxism

7. Dan pindah folder Tyrotoxism ke folder Quiescent.
mv 1802031_UAS/Malevolent/Epithet/Malevolent 1802031_UAS/Malevolent/Epithet/Tyrotoxism

8. Kemudian buat folder Quiescent didalam folder NIM_UAS/Epithet/Malevolent.
Cd 1802031_UAS/Epithet/Malevolent
1802031_UAS/Epithet/Malevolent mkdir Quiescent

9. Buat folder Epithet dalam folder NIM_UAS/Quiescent/Tyrotoxism.
Cd ~
Cd 1802031_UAS/Quiescent/Tyrotoxism
1802031_UAS/Quiescent/Tyrotoxism mkdir Epithet

10. Setelah itu hapus folder NIM_UAS/Quiescent/Tyrotoxism/Epithet.
1802031_UAS/Quiescent/Tyrotoxism rmdir Epithet

11. Copy folder NIM_UAS/Epithet/Malevolent/Quiescent kedalam folder NIM_UAS/Epithet.
Cd ~
Cd 1802031_UAS/Epithet/Malevolent
1802031_UAS/Epithet/Malevolent cp –r Quiescent ~/1802031_UAS/Epithet

12. Pindahkan folder NIM_UAS/Epithet/Malevolent/Quiescent kedalam folder Tyrotoxism.
Cd ~
mv 1802031_UAS/Epithet/Malevolent/Quiescent 1802031_UAS/Quiescent/Tyrotoxism/Quiescent.

13. Buat sebuah file dengan nama file1.txt dalam folder NIM_UAS/Epithet/Quiescent.
Cd 1802031_UAS/Epithet/Quiescent
1802031_UAS/Epithet/Quiescent touch file1.txt

14. Dan kemudian ubah hak akses folder NIM_UAS/Malevolent/Epithet menjadi drw—wxr-x (Menggunakan Letter Coding System).
Cd 1802031_UAS/Malevolent
1802031_UAS/Malevolent ls –l
1802031_UAS/Malevolent sudo chmod u+r Epithet
1802031_UAS/Malevolent sudo chmod g-r Epithet
1802031_UAS/Malevolent sudo chmod g+r Epithet
1802031_UAS/Malevolent sudo chmod g+w Epithet
1802031_UAS/Malevolent sudo chmod u-x Epithet
1802031_UAS/Malevolent sudo chmod u-r Epithet
1802031_UAS/Malevolent sudo chmod u+r Epithet
1802031_UAS/Malevolent sudo chmod g-r Epithet

15. Kemudian kompres folder NIM_UAS/Epithet dengan nama arsip.zip .
Zip arsip.zip Epithet

16. Ekstrak file arsip.zip ke dalam folder NIM_UAS/Quiescent.
Unzip arsip.zip –d  Quiescent

B. Soal 2
1. Buat Program Perulangan Dengan Nama Ujian.sh Didalam Folder 1802031_UAS/Malevolent
Dan Jalankan Dengan Hasil OutPut Seperti Berikut :
Perulangan Ke-1
Perulangan Ke-3
Perulangan Ke-5
Perulangan Ke-7

Nano ujian.sh

#!/bin/bash
Clear

For perulangan in {1..7}
Do
 echo “perulangan ke-$perulangan”
done

Komentar