Aikataulu – Linux palvelimena ict4tn003-3 ja ict4tn003-5 keväällä 2012

Kiitos suosiosta, 39 ilmoittautunutta päivätoteutukseen ja 29 iltaan! Edellisen toteutuksen palautteiden perusteella otamme osallistujia vain 25 istumapaikalle, joten vahvistathan paikkasi ensimmäisellä tunnilla.

Moodle sivu ict4tn003-3 päivä sekä ict4tn003-5 ilta (vaativat kirjautumisen).

Aikataulu

w3 Järjestäytyminen, nykytilan arviointi. SSH.

w4 Järjestelmän tilan seuraaminen ja prosessinhallinta

w5 Rosvoja ja kunnon kansalaisia – ja dd

w6 Paketinhallintaa; metapaketteja

w7 Apache; kertaus ja edistynyttä asiaa

Talviloma w8, leiki Linuxilla kotona

w9 Sisällönhallintajärjestelmät

w10 Pakettivarasto

w11 Koe

Kyseessä on edistynyt kurssi, ja ohjelmaan voi tulla muutoksia vielä kurssin aikanakin.

Posted in Uncategorized | Tagged , , , , | 3 Comments

Agenda for Linux Basics dat8tf063-18 Spring 2012

Learn the basics of Linux in just 8 weeks! Tero teaches all the classes in h5001, Fridays 08:15-11:45.

Linux Basics on Moodle (login required).

Feel free to check comments from previous course.

Agenda

Installation w3

2 Desktop Linux, Licenses w4

3 Command Prompt w5

4 Package Management and Administration w6

5 Apache Web Server w7

w8 winter holiday, play with Linux

6 OpenSSH Server and Client w9

7 Automation w10

8 Exam w11

Course ends at the exam in the end of the 1st period.

Homework

Do on a computer & publish a report.

DL w5: Install & Desktop:

  • Burn a Linux CD (ubuntu or xubuntu)
  • Try the Live CD outside lab (install not required)
  • Desktop software: list software you are currently using (eg. Microsoft Word); name it’s purpose (WYSIWYG word processor); find a Free Linux alternative, if you can.
  • Test three of these Free software applications. (Try to pick software that’s new to you. Use the software for its intended purpose – do more than just starting it)

Publish & return the link to Moodle. (Publishing recommended, but it’s possible to just return the text to Moodle, too).

Posted in Uncategorized | Tagged , , , | Leave a comment

Aikataulu – Työasemat ja tietoverkot ict1tn002-25 keväällä 2012

Teron pitämässä Linux-osuudessa pääset Linuxin maailmaan alle kuudessa viikossa. Tunnit labrassa h5001 maanantaisin 10:00 ja keskiviikkoisin 12:00.

Kurssin Moodle-sivu (vaatii kirjautumisen).

Kurssikuvaus.

Aikataulu

1. Asennus (w3)

2. Työpöytä ja lisenssit (w3)

3. Komentokehote (w4)

4. Ylläpito (w4)

5. Apache-weppipalvelin (w5)

6. LAMP kehitysalustana (w5)

7. OpenSSH-etähallinta (w6)

8. OpenSSH useiden koneiden hallinnassa (w6)

9. Automaatio ja ohjelmointiympäristöt (w7)

10. IpTables-tulimuuri (w7)

(w8 on talvivapaa, leiki Linuxilla)

11. Linux-koe (w9)

Olavi Korhonen jatkaa Windowsilla w9 keskiviikosta kevään loppuun asti.

Läksyt

Tehtävät käydään yhdessä läpi seuraavan tunnin alussa ja niistä annetaan palaute samalla. Arviointi tapahtuu kurssin lopuksi yhtenä arvosanana koko tehtäväpaketista. Kukin tehtävä tulee palauttaa ajoissa.

Tehtäväraportit kannattaa julkaista wepissä, lopuksi voi palauttaa linkin. (Jos et jostain syystä halua julkaista, voimme sopia erityisjärjestelyistä)

Lue raportin kirjoittaminen.

DL w4

  • Julkaise raportti Ubuntu Linux -liverompun poltosta ja kokeilusta
  • Listaa sovellukset, joita käytät nykysessä järjestelmässäsi. Nimeä kunkin sovelluksen käyttötarkoitus. Etsi vastaava vapaa softa, jos sellainen löytyy. (Esim: MS Word – tekstinkäsittely – LibreOffice Writer).
  • Asenna kolme vapaata ohjelmaa listaltasi. Kokeile näitä ohjelmia perusteellisesti. Ota ruutukaappauksia. Raportoi. Kerro myös sovelluksen lisenssi, jos se selviää.
Posted in Uncategorized | Tagged , , , | 3 Comments

Published Today: Mind Controlled Robot Book!

Want to make your own mind controlled robot?

I published the book today. It’s available on Amazon and O’Reilly. You can have it on dead tree or DRM-free ebook. Source code is a free download on MindControl.BotBook.com.

I authored the book with Kimmo Karvinen. Ville Valtokari gave technical advice. And Brian Jepson did great job editing it.

The book has a lot of photos, as seen on previous posting. Get yours before the ink dries!

Edit: Wordings

Posted in Uncategorized | Tagged , , | Leave a comment

Valmiiden projektien esittely – Järjestelmäprojekti ict4tn007-2

Projektien esittely w49 perjantaina, labra h5001. Aloitamme musiikilla kello 08:15. Tervetuloa!

w49

Markus Laaninen: Kotistudio Ubuntulla

“Salminensa”: OpenVPN

Joel Särkkä, Samu Saarniluoto, Tatu Seppälä: Ubuntu 11.10 Enterprise Cloud

NeverMod tiimi: NeverEdit

Henri Sukki, Antti Tirronen, Sampo Tyllilä: Reititin palvelimena

w50

Patrick Ahlstrand: Run! paikannuspeli

Toni ja Artem: Pelkällä näppäimistöllä käyttö

Keijo Nykänen: Levyn salakirjoituksen vaikutus Ubuntu 10.10 suorituskykyyn

Diaspora-ryhmä: Diaspora

Juhani Atula & Teemu Lehto & Juha-Matti Laaksonen: Django

Edit: Viikkojako, diaspora, poiminnat, Run! linkki.

Posted in Uncategorized | Tagged , , | 4 Comments

Tutkimussuunnitelma – esimerkkityö kurssilta Tietotekninen selvitys ja kouluttaminen ict2tn011-5

Esimerkkityö Haaga-Helian tieteellisen kirjoittamisen kurssilta.

Tietotekninen selvitys ja kouluttaminen on opiskelijalle ensimmäinen kurssi tieteellisestä kirjoittamisesta. Kurssilla harjoitellaan aihe-ehdotuksen ja tutkimussuunnitelman kirjoittamista. Tutkimussuunnitelmassa kuvattua tutkimusta ei toteuteta kurssilla, mutta osa opiskelijoista saattaa tehdä opinnäytteensä samasta aiheesta.

Laaka 2011: (tutkimussuunnitelma) Kahdeksasluokkalaisten tietoisuus tietoturvauhkista sosiaalisessa mediassa ja sen vaikutus heidän käytökseensä (pdf, 260 kB)

Posted in Uncategorized | Tagged , , , | Leave a comment

Static Advantage – Could WordPress Be 400 Times Faster?

Apache served static pages 400 times faster than dynamic WordPress pages. Could caching bring this speed advantage to WordPress?

I measured pages with Apache benchmark tool “ab”, using 10 simultaneous connections. I used a powerful desktop as a server on localhost. I only considered the count of pages served per second.

Static pages were the fastest, with 2600 – 3700 pages served per second. All static pages got similar scores, with longer pages being slightly slower.

PHP “Hello world” was only slightly slower, 2500 pages per second.

Reading a couple of records from database was about 50% slower, 1500 pages per second.

WordPress was the slowest one, with major difference in speed. It only served 6 – 9 pages per second. WordPress was tested with default setup, without installing any caching plugins.

Apache can serve 400 times more static pages (per second) compared to WordPress. This is 40 000 % (forty thousand percent).

Could WordPress be 400 Times Faster?

Many users just read the same frontpage. If it would be static, would that mean 400 times more pages served per second?

If so, would caching achieve this? There are modules for WordPress that cache pages as static HTML.

I used a home made static caching system in the previous incarnation of my homepage, and it seemed to work well.

Sources of Errors

Test was done on a powerful desktop machine with multicore CPU and lots of RAM. Servers are often low-end virtual machines with limited RAM.

I used a machine that had been a test machine for a while. It could have misconfigurations in MySQL, Apache or PHP.

Test was done with localhost address. In practical use, network might become a bottleneck, negating some of the advantage of serving static pages.

Only number of pages served per second was considered. There are many other ways to measure speed, such as time to load HTML, time to onLoad(), latency etc.

Obviously, the measurements don’t mean that static pages are better – they are just faster to serve. WordPress was used as an example of complex dynamic application, and it was not compared to any other CMS.

Posted in Uncategorized | Tagged , , , , , , , , , , , , , | Leave a comment

Demo Coming: 30 Ubuntus Installed & Managed

Update: Just came from lab and saw it working. The whole lab of 24 computers was installed. Only a couple of computers needed manual reboot (EFI BIOS settings, DHCP timeout). Configuring computers worked, too.

AwaseConfigurations is almost ready. They can now do the whole thing to 30 computers: boot them, install Linux and manage them trough the network. Configuration management is centralized with Fabric.

They have Cobbler (install), Squid (proxy), Reprepro (apt), configuration packages (apt) and of course SSH. You can get configuration files, scripts, packages and project plans from git.

$ git clone https://github.com/AwaseConfigurations/main

I’ll get to see a demonstration this (w47) Friday.

AwaseConfigurations is a project by my students Henri Siponen, Armens Movsesjans and Panu Salmi. Read more in AwaseConfigurations blog.

Posted in Uncategorized | Tagged , , , , , | Leave a comment

Drawing to Canvas on Android – Code Example

Draw full screen on your Android phone

This is just example code. For a throughout explanation, see Make Arduino Bots and Gadgets: Boxing Clock.

package com.botbook.drawingoncanvas;

import android.app.Activity;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Color;
import android.graphics.Paint;
import android.graphics.Paint.Align;
import android.os.Bundle;
import android.view.View;
import android.view.Window;
import android.view.WindowManager;

//Copyright 2011 Tero Karvinen http://botbook.com

public class DrawingOnCanvasActivity extends Activity {
 @Override
 public void onCreate(Bundle savedInstanceState) {
 super.onCreate(savedInstanceState);
 fullscreen(); // without this, bottom of canvas goes out of screen
 TCanvas tCanvas = new TCanvas(this);
 setContentView(tCanvas);
 }

 public void fullscreen()
 {
 requestWindowFeature(Window.FEATURE_NO_TITLE);
 getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
 WindowManager.LayoutParams.FLAG_FULLSCREEN);
 }

 public class TCanvas extends View {
 public TCanvas(Context context) {
 super(context);
 }

 public void onDraw(Canvas c) {
 c.drawColor(Color.BLUE);

 Paint paint = new Paint();
 paint.setStyle(Paint.Style.FILL);
 paint.setAntiAlias(true);

 paint.setColor(Color.RED);
 c.drawCircle(0, 0, 50, paint);
 paint.setColor(Color.WHITE);
 paint.setTextSize(20);
 c.drawText("0,0 is top left", 0, 0+20, paint);

 float w=c.getWidth();
 paint.setColor(Color.GREEN);
 c.drawCircle(w, 0, 50, paint);
 paint.setColor(Color.WHITE);
 paint.setTextAlign(Align.RIGHT);
 c.drawText("right: x is width", w, 0+20, paint);

 float h=c.getHeight();
 paint.setColor(Color.YELLOW);
 c.drawCircle(w/2, h, 200, paint);
 paint.setColor(Color.BLACK);
 paint.setTextAlign(Align.CENTER);
 c.drawText("bottom: y is height, center: half of width", w/2, h-20, paint);
 }
 }
}

More Draw Commands for Canvas

You can see all available draw-commands with ctrl-space: Type the name of your canvas object in Eclipse. Just type “.draw” and press control space.

See Also

Make Arduino Bots and Gadgets: Boxing Clock. (Book on Amazon)

Boxing Clock for Android (Code examples)

Posted in Uncategorized | Tagged , , , , | Leave a comment

Tee yksinkertainen peli Androidille

Tee yksinkertainen peli Androidille. Paljonko on 2*14? Mikä luvuista ei ole jaollinen kolmella? Haluatko ostaa vokaalin? Monennellako yrityksellä arvaat numeron? Paljonko 2 jalkaa 3 tuumaa on nykyaikaisissa yksiköissä? Mikä sana on kontiksi konoxlintti?

Hymynaama

Vapaaehtoinen lisätehtävä: Piirrä Androidilla hymynaama.

Edistynyt Boing!

Oliko laskurin teko helppoa? Saitko tuntikuulustelusta 10/10? Tässä pientä haastetta: vapaaehtoinen lisätehtävä: Tee Androidille pomppiva pallo.

Vinkkejä: Custom View, Boxing Clock (koodit), Make Arduino Bots and Gadgets: Boxing Clock.

Boing propellihatuille

Oliko pomppivan pallon teko helppoa? Näetkö unet dalvik-yhteensopivana Javana?

Vapaaehtoinen lisä-lisätehtävä: Laita pomppiva pallo reagoimaan kännykän kallistamiseen.

Vinkkejä: Cell phone controlled soccer robot, Make Arduino Bots and Gadgets: Soccer Robot, Google

Edit: Hymynaama.

http://botbook.com/ch08.htmlCell
Posted in Uncategorized | Tagged , , , , , , | Leave a comment
Boxing Clock for Android Octon8 Diving T-Shirts Shaking Tower Panda Android Game Learn Chinese with Android