diff options
Diffstat (limited to 'kpov_judge/tasks/set_motd')
-rw-r--r-- | kpov_judge/tasks/set_motd/howtos/en/index.html | 33 | ||||
-rw-r--r-- | kpov_judge/tasks/set_motd/howtos/si/index.html | 46 |
2 files changed, 33 insertions, 46 deletions
diff --git a/kpov_judge/tasks/set_motd/howtos/en/index.html b/kpov_judge/tasks/set_motd/howtos/en/index.html index 716c2dd..10bf4c9 100644 --- a/kpov_judge/tasks/set_motd/howtos/en/index.html +++ b/kpov_judge/tasks/set_motd/howtos/en/index.html @@ -5,18 +5,11 @@ <meta charset="utf-8">
</head>
<body>
-
-<h2>Usage of nano text editor </h2>
-<p>
- 1.) Open the nano editor with the command nano which is followed by the path and name of the file. Example: <strong>nano /etc/myfile</strong>. If the file doesn't exist, the file will be created by the editor.<br />
- 2.) To move in the editor, we use the arrow keys, <strong>backspace</strong> is used for deleting. <br />
- 3.) To save a file press the combination of keys <strong>ctrl</strong> + <strong>O</strong>. <br />
- 4.) To exit the editor press the combination of keys <strong>ctrl</strong> + <strong>X</strong>. The editor will ask you, if you really want to exit, you can answer with <strong>y</strong> (yes ) or with <strong>n</strong> ( no ). <br />
- 5.) To cut a line press the combination of keys <strong>ctrl</strong> + <strong>K</strong>. <br />
- 6.) To paste a line press the combination of keys <strong>ctrl</strong> + <strong>U</strong>. <br />
- 7.) To search over a document press the combination of keys <strong>ctrl</strong> + <strong>W</strong> and then enter the search string.
-</p>
-
+<h1>set_motd</h1>
+<h2>Purpose of the exercise</h2>
+<p>How to create user? How to edit a file? How to connect to anoter computer using ssh? How to find out the computer IP address?</p>
+<h2>Brief description</h2>
+<p>Set up two virtual machines, set MOTD. Connect using ssh.</p>
<h2>How To</h2>
@@ -26,7 +19,17 @@ Student: Adapter1 set it to "internal-network" so it is in the same domestic network as SimpleArbiterDhcpGw. <br> <img src="../images/img1.png" alt="no img"> <br> <img src="../images/img2.png" alt="no img"> <br> <img src="../images/img3.png" alt="no img"></li>
<li>Login into <b>Student</b> <br> <img src="../images/img5.png" alt="no img"></li>
<li>In Student(student-console) create a new user (with "adduser username",as the task demands of you ( eg. marjankoral19 ), with a custom password. <br> <img src="../images/img6.png" alt="no img"></li>
- <li>In Student(student-console) open interfaces file ( nano /etc/network/interfaces ) and set the IP <br> <img src="../images/img7.png" alt="no img" ></li>
+ <li>In Student(student-console) open interfaces file ( nano /etc/network/interfaces ) and set the IP <br>
+ <h2>How to use the <strong>nano</strong> text editor </h2>
+ <p>
+ 1.) Open the nano editor with the command nano which is followed by the path and name of the file. Example: <strong>nano /etc/myfile</strong>. If the file doesn't exist, the file will be created by the editor.<br />
+ 2.) To move in the editor, we use the arrow keys, <strong>backspace</strong> is used for deleting. <br />
+ 3.) To save a file press the combination of keys <strong>ctrl</strong> + <strong>O</strong>. <br />
+ 4.) To exit the editor press the combination of keys <strong>ctrl</strong> + <strong>X</strong>. The editor will ask you, if you really want to exit, you can answer with <strong>y</strong> (yes ) or with <strong>n</strong> ( no ). <br />
+ 5.) To cut a line press the combination of keys <strong>ctrl</strong> + <strong>K</strong>. <br />
+ 6.) To paste a line press the combination of keys <strong>ctrl</strong> + <strong>U</strong>. <br />
+ 7.) To search over a document press the combination of keys <strong>ctrl</strong> + <strong>W</strong> and then enter the search string.
+ </p> <img src="../images/img7.png" alt="no img" ></li>
<li>We can check which interface belongs to which adapter in Virtual-box with MAC address. Run ifconfig command and compare the HWaddr value with the value in the Virtual-box ( settings => network => adapter => Mac address ) <br /><img src="../images/slika4.png" alt="no img" /><img src="../images/slika3.png" alt="no img"/></li>
<li>Then edit the /etc/motd (eg. with nano editor like this: "nano /etc/motd"), file with the specified string. (eg. "Not for Human consumption" ) <br> <img src="../images/img8.png" alt="no img"> </li>
<li>For testing login with the test user into Test(SimpleArbiterDhcpGw) <br> <img src="../images/img9.png" alt="no img"></li>
@@ -36,10 +39,6 @@ <li>A window appears as we can see on the image above, then press Enter, enter your username ( eg. dr6784@student.uni-lj.si ), password, task name (eg. 01-preparation-set_motd), enter the string we should get in motd, enter the username and password of a user on Student(student-console)(eg. marjankoral19), the IP of Student(student-console), and after a brief moment we should get the result. <img src="../images/img12.png" alt="no img"> </li>
</ol>
-<h2>Purpose of the exercise</h2>
-<p>How to create user? How to edit a file? How to connect to anoter computer using ssh? How to find out the computer IP address?</p>
-<h2>Brief description</h2>
-<p>Set up two virtual machines, set MOTD. Connect using ssh.</p>
</body>
</html>
\ No newline at end of file diff --git a/kpov_judge/tasks/set_motd/howtos/si/index.html b/kpov_judge/tasks/set_motd/howtos/si/index.html index ab59c8b..1a43adb 100644 --- a/kpov_judge/tasks/set_motd/howtos/si/index.html +++ b/kpov_judge/tasks/set_motd/howtos/si/index.html @@ -5,21 +5,15 @@ <meta charset="utf-8">
</head>
<body>
-
-<h2>Uporaba nano urejavalnika besedila </h2>
-<p>
- 1.) Urejvalnik nano odpremo z ukazom nano, kateremu sledi ime datoteke. Primer: <strong>nano /etc/mojadatoteka</strong>. Če datoteka ne obstaja jo bo ustvaril urejevalnik. <br />
- 2.) Po urejevalniku se premikamo s smernimi puščicami, brišemo z tipko <strong>backspace</strong>. <br />
- 3.) Za shranjevanje dokumenta pritisnemo kombinacijo tipk <strong>ctrl</strong> + <strong>O</strong> <br />
- 4.) Za izhod iz urejevalnika pritisnemo kombinacijo tipk <strong>ctrl</strong> + <strong>X</strong>. Pri tem nas urejevalnik upraša če želimo shraniti spremembe. Odgovorimo z <strong>y</strong> (yes, ja ) ali z <strong>n</strong> ( no, ne ). <br />
- 5.) Za izrez vrsticne uporabimo kombinacijo tipk <strong>ctrl</strong> + <strong>K</strong>. <br />
- 6.) Za lepljenje vrstice se uporablja kombinacija tipk <strong>ctrl</strong> + <strong>U</strong>. <br />
- 7.) Za iskanje po besedilu uporabimo kombinacijo tipk <strong>ctrl</strong> + <strong>W</strong>, nakar vnesemo iskani niz in pritisnemo tipko enter.
-</p>
+<h1>set_motd</h1>
+<h2>Namen vaje</h2>
+<p>Kako se ustvari uporabnik? Kako se popravi datoteka? Kako se s pomočjo ssh
+povežemo na drug racunalnik? Kako ugotovimo IP naslov računalnika? </p>
<h2>Naloga na hitro</h2>
+<p>Postavi 2 navidezna računalnika, nastavi MOTD. Poveži se preko ssh.</p>
-<h2>Navodila</h2>
+<h2>Podrobna navodila</h2>
<ol>
<li>Ustvari dva navidezna računalnika Student(student-console) in Test(SimpleArbiterDhcpGw) <br> <img src="../images/img4.png" alt="ni slike"></li>
@@ -29,29 +23,23 @@ <li>Na računalniku Student(student-console) ustvari novega uporabnika (z ukazom "adduser imeuporabnika") kot od tebe zahteva naloga (npr. marjankoral19), geslo določi sam. <br> <img src="../images/img6.png" alt="ni slike"></li>
<li>Računalnik Student, odpri datoteko interfaces ( nano /etc/network/interfaces ) ter nastavi IP <br> <img src="../images/img7.png" alt="ni slike"></li>
<li>Kateri vmesnik (npr. eth0) spada pod kateri adapter (npr. Adapter1 ) lahko preverimo s strojnimi naslovi. Na računalniku zaženemo ukaz ifconfig, pogledamo HWaddr vrednost ter jo primerjamo z vrednostjo v Virtual-boxu (nastavitve => omrežja => adapter => MAC address <br /><img src="../images/slika4.png" alt="ni slike"/><img src="../images/slika3.png" alt="ni slike"/></li>
- <li>Nato spremeni datoteko /etc/motd (z urejevalnikom nano, primer uporabe: "nano /etc/motd"), zamenjaj z ustreznim nizom kot od tebe zahteva naloga ( npr. "Not for Human consumption" ) <br> <img src="../images/img8.png" alt="ni slike"> </li>
+ <li>Nato spremeni datoteko /etc/motd (z urejevalnikom nano, primer uporabe: "nano /etc/motd"), zamenjaj z ustreznim nizom kot od tebe zahteva naloga ( npr. "Not for Human consumption" ) <br>
+ <h2>Kako se uporablja <strong>nano</strong> urejavalnika besedila </h2>
+ <p>
+ 1.) Urejvalnik nano odpremo z ukazom nano, kateremu sledi ime datoteke. Primer: <strong>nano /etc/mojadatoteka</strong>. Če datoteka ne obstaja jo bo ustvaril urejevalnik. <br />
+ 2.) Po urejevalniku se premikamo s smernimi puščicami, brišemo z tipko <strong>backspace</strong>. <br />
+ 3.) Za shranjevanje dokumenta pritisnemo kombinacijo tipk <strong>ctrl</strong> + <strong>O</strong> <br />
+ 4.) Za izhod iz urejevalnika pritisnemo kombinacijo tipk <strong>ctrl</strong> + <strong>X</strong>. Pri tem nas urejevalnik upraša če želimo shraniti spremembe. Odgovorimo z <strong>y</strong> (yes, ja ) ali z <strong>n</strong> ( no, ne ). <br />
+ 5.) Za izrez vrsticne uporabimo kombinacijo tipk <strong>ctrl</strong> + <strong>K</strong>. <br />
+ 6.) Za lepljenje vrstice se uporablja kombinacija tipk <strong>ctrl</strong> + <strong>U</strong>. <br />
+ 7.) Za iskanje po besedilu uporabimo kombinacijo tipk <strong>ctrl</strong> + <strong>W</strong>, nakar vnesemo iskani niz in pritisnemo tipko enter.
+ </p><br /> <img src="../images/img8.png" alt="ni slike"> </li>
<li>Za testiranje se s testnim uporabniškim imenom prijavi na prvem računalniku. (SimpleArbiterDhcpGw) <br> <img src="../images/img9.png" alt="ni slike"></li>
<li>Nato se preko ssh poveži na Student z uporabniškim imenom marjankoral19 - ssh marjankoral19@ip. <br> <img src="../images/img10.png" alt="ni slike" ></li>
<li>Po uspešni prijavi se bo moralo izpisati motd sporočilo.</li>
<li>Kpov_judge poženemo tako da se prijavimo na računalniku SimpleArbiterDhcpGw, najdemo datoteko test_task.py ter jo poženemo ( z ./test_task.py kot se poganjajo vse skripte )<br /> <img src="../images/img11.png" alt="ni slike"></li>
<li>Pojavi se nam okno kot ga vidimo zgoraj, nato pa pritisnemo Enter, vnesemo svoje uporabnisko ime ( npr. dr6784@student.uni-lj.si ), geslo, ime naloge (npr. 01-preparation-set_motd), vnesemo niz ki bi se nam moral prikazati, vnesemo ime uporabnika na racunalniku student (npr. marjankoral19) ter njegovo geslo, ip računalnika študent, nato pa po kratkem premoru dobimo rezultat. <img src="../images/img12.png" alt="ni slike"> </li>
</ol>
-=======
-
-<h2>Namen vaje</h2>
-<p>Kako se ustvari uporabnik? Kako se popravi datoteka? Kako se s pomočjo ssh
-povežemo na drug racunalnik? Kako ugotovimo IP naslov računalnika? </p>
-<h2>Naloga na hitro</h2>
-<p>Postavi 2 navidezna računalnika, nastavi MOTD. Poveži se preko ssh.</p>
-
-<h2>Navodila</h2>
-<ul>
- <li>Ustvari dva navidezna računalnika - imenujmo ju Test in Student. Za računalnik Test uporabite sliko diska, poimenovano Test. Na računalniku Test dobite kratek niz. Poskrbite, da se bo ta kratki niz pojavil v sporočilu, ki se ob prijavi izpiše na računalniku Student. Temu sporočilu v angleščini rečemo "message of the day" - MOTD.</li>
- <li>Poskrbite, da se bo ob prijavi uporabnika (v Message Of The Day, MOTD) prek ssh izpisal nek niz. Računalnik nastavite tako, da bo dostopen s testnega računalnika (Test).</li>
- <li>Uporabnišško ime in niz dobite kot parametre ob zagonu run_test.py. Pri nizu pazite, saj utegne biti dovolj dolg, da brez premikanja kurzorja ne bo takoj viden.</li>
- <li>IP navideznega računalnika ter geslo nastavite sami.</li>
- <li>Ocenjevalni program pričakuje, da se bo ob koncu prijave pojavila ukazna vrstica oblike uporabnisko_ime@ime_racunalnika:~$ . Pazite, da se bo takšna vrstica pojavila šele po nizu, ki ste ga dobili v navodilih.</li>
-</ul>
</body>
</html>
\ No newline at end of file |