Sugar on a Stick (子ども向け・教育用デスクトップOS)

小学4年生の息子のために、子ども向け・教育用デスクトップOSを試してみます。

Sugarは、子供たちがインタラクティブに学習できるように設計された、フリーでオープンソースのデスクトップ環境です。
特に開発途上国の子供たち向けのOne Laptop Per Child(OLPC)プロジェクトの一環として開発されました。

ここではUSBメモリでライブ起動するための手順を紹介します。では早速、最新のFedora 28ベースを使ってみます。

1. 2GB以上の容量のUSBスティックをコンピュータに挿入します。

2. 端末またはコンソールのコマンド行でrootユーザー権限を使用する場合は、df -Thまたはblkidコマンドを使用してUSBデバイスのノード名を取得します。

3. USBデバイスファイルシステムをアンマウントします:

# umount /run/media/shinji/DISK_IMG

4. rootユーザーとして以下のインストールコマンドを実行します。

# livecd-iso-to-disk --reset-mbr --overlay-size-mb 500 --home-size-mb 800 --unencrypted-home Fedora-SoaS-Live-x86_64-28-1.1.iso /dev/sdb1
Verifying image...
/home/shinji/ダウンロード/Fedora-SoaS-Live-x86_64-28-1.1.iso: b5bb60db0ce3c1d2586f357a480d7cf6
Fragment sums: 473485664cbca657b736b38b42f7ce83d5425e8d64da76d192fde9d6256c
Fragment count: 20
Supported ISO: no
Press [Esc] to abort check.
Checking: 100.0%

The media check is complete, the result is: PASS.

It is OK to use this media.

Copying LiveOS image to target device...
squashfs.img
863,703,040 100% 431.24MB/s 0:00:01 (xfr#1, to-chk=0/1)

Syncing filesystem writes to disc.
Please wait, this may take a while...
Setting up /EFI/BOOT
Validation Entry:
Header Indicator: 0x01 (Validation Entry)
PlatformId: 0x00 (80x86)
ID: ""
Checksum: 0x55aa
Key bytes: 0x55aa
Boot Catalog Default Entry:
Entry is bootable
Boot Media emulation type: no emulation
Media load segment: 0x0 (0000:7c00)
System type: 0 (0x00)
Load Sectors: 4 (0x0004)
Load LBA: 24878 (0x0000612e)
Dumping boot image to "/home/shinji/ダウンロード/Fedora-SoaS-Live-x86_64-28-1.1.iso.0"
Section Header Entry:
Header Indicator: 0x90 (Section Header Entry)
PlatformId: 0xef (EFI)
Section Entries: 1
ID: ""
Boot Catalog Section Entry:
Entry is bootable
Boot Media emulation type: no emulation
Media load address: 0 (0x0000)
System type: 0 (0x00)
Load Sectors: 18656 (0x48e0)
Load LBA: 29211 (0x0000721b)
Dumping boot image to "/home/shinji/ダウンロード/Fedora-SoaS-Live-x86_64-28-1.1.iso.1"
Section Header Entry:
Header Indicator: 0x91 (Final Section Header Entry)
PlatformId: 0xef (EFI)
Section Entries: 1
ID: ""
Boot Catalog Section Entry:
Entry is bootable
Boot Media emulation type: no emulation
Media load address: 0 (0x0000)
System type: 0 (0x00)
Load Sectors: 39408 (0x99f0)
Load LBA: 33875 (0x00008453)
Dumping boot image to "/home/shinji/ダウンロード/Fedora-SoaS-Live-x86_64-28-1.1.iso.2"
Updating boot config files.
Initializing persistent overlay...
500+0 レコード入力
500+0 レコード出力
524288000 bytes (524 MB, 500 MiB) copied, 0.397807 s, 1.3 GB/s
Initializing persistent /home
800+0 レコード入力
800+0 レコード出力
838860800 bytes (839 MB, 800 MiB) copied, 0.53546 s, 1.6 GB/s
Formatting unencrypted home.img
mke2fs 1.43.5 (04-Aug-2017)
Creating filesystem with 204800 4k blocks and 51296 inodes
Filesystem UUID: d6ba7bab-c101-4f35-a90d-94b87ff63750
Superblock backups stored on blocks:
32768, 98304, 163840

Allocating group tables: done
Writing inode tables: done
Creating journal (4096 blocks): done
Writing superblocks and filesystem accounting information: done

tune2fs 1.43.5 (04-Aug-2017)
Setting maximal mount count to -1
Setting interval between checks to 0 seconds
Installing boot loader...
Target device is now set up with a Live image!

5. 4で作成したUSBメモリを使わなくなった古いラップトップに挿してブートします。

すると以下の画面が表示され、学年を選んだりでき、ホーム画面が表示されます。

f:id:shinji629:20180605010416j:plain

f:id:shinji629:20180605010508j:plain

f:id:shinji629:20180605010556j:plain




参考までに以下のような状況に遭遇するかもしれないので、その対処法も紹介します。

パーティションがブート可能とマークされていない場合:

# livecd-iso-to-disk --reset-mbr --overlay-size-mb 500 --home-size-mb 800 --unencrypted-home Fedora-SoaS-Live-x86_64-28-1.1.iso /dev/sdb1
Verifying image...
/home/shinji/ダウンロード/Fedora-SoaS-Live-x86_64-28-1.1.iso: b5bb60db0ce3c1d2586f357a480d7cf6
Fragment sums: 473485664cbca657b736b38b42f7ce83d5425e8d64da76d192fde9d6256c
Fragment count: 20
Supported ISO: no
Press [Esc] to abort check.
Checking: 100.0%

The media check is complete, the result is: PASS.

It is OK to use this media.

ATTENTION:
The partition isn't marked bootable!

You can mark the partition as bootable with the following commands:

# parted /dev/sdb
(parted) toggle boot
(parted) quit

# parted /dev/sdb
GNU Parted 3.2
/dev/sdb を使用
GNU Parted へようこそ! コマンド一覧を見るには 'help' と入力してください。
(parted) help toggle
toggle [NUMBER [FLAG]] パーティションのフラグの状態を反転する

NUMBER は Linux カーネルによってパーティション番号として使われます。MS-DOS ディスクラベルでは、基本パーティション番号は 1 から 4 までで、論理パーティションは 5 以降となります。
フラグは次のうちから選びます: boot, root, swap, hidden, raid, lvm, lba, hp-service, palo, prep, msftres, bios_grub, atvrecv,
diag, legacy_boot, msftdata, irst, esp
(parted) toggle 1 boot
(parted) quit
通知: 必要であれば /etc/fstab を更新するのを忘れないようにしてください。

ディスクスペースが足りない場合:

# livecd-iso-to-disk --reset-mbr --overlay-size-mb 500 --home-size-mb 800 --unencrypted-home Fedora-SoaS-Live-x86_64-28-1.1.iso /dev/sdb1
Verifying image...
/home/shinji/ダウンロード/Fedora-SoaS-Live-x86_64-28-1.1.iso: b5bb60db0ce3c1d2586f357a480d7cf6
Fragment sums: 473485664cbca657b736b38b42f7ce83d5425e8d64da76d192fde9d6256c
Fragment count: 20
Supported ISO: no
Press [Esc] to abort check.
Checking: 100.0%

The media check is complete, the result is: PASS.

It is OK to use this media.

The live image + overlay, home, & swap space, if requested,
will NOT fit in the space available on the target device.

+ Size of live image: 891 MiB
+ Home directory size: 800
= Total requested space: 2191 MiB
- Space available: 2007
==============================
Space needed: 184 MiB

To fit the installation on this device,
free space on the target, or decrease the
requested size total by: 184 MiB

より大きなUSBメモリを準備しましょう。