組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール...

28
Copyright Cybertrust Japan Co., Ltd. 公開 1 組込みOS最前線#3:IoTデバイス編 組込みLinuxの長期運用に向けたコミュニティでの取り組み 2019/6/21 サイバートラスト株式会社 工藤 雅司

Transcript of 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール...

Page 1: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

1

組込みOS最前線#3:IoTデバイス編

組込みLinuxの長期運用に向けたコミュニティでの取り組み

2019/6/21

サイバートラスト株式会社

工藤 雅司

Page 2: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

2

組込み領域で長期保守が求められる背景・課題

長期保守に向けたコミュニティ活動

CIP(Civil Infrastructure Platform)

まとめ

アジェンダ

Page 3: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

3

組込み領域で長期保守が求められる背景・課題

Page 4: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

4

組込み機器の製品寿命の長さ

Factory Automation

Communication

Transportation

Automotive

PLC: 20 YearsPLC: 15 Years

PLC: 20 Years PLC: 15 Years

PLC: 15 Years

PLC: Product Life Cycle

Page 5: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

オープンソースカンファレンス2018 Tokyo/Fall

バックエンドでのエコシステム

異なるレベルで異なる役割を担う複数のユーザ

IoT: Internet of Things IIoT: Industrial IoT SCADA: Supervisory Control And Data Acquisition

ネットワークゾーン制御プラント解析

SCADAプラント(デバイス)管理

ローカル / リアルタイム解析IoTゲートウェイ

エッジ

デバイス

データ収集 / プリプロセッシングセンサー / アクター接続

IIoTインフラでのアプリ例

• ネットワーク接続された産業グレードデバイスの増加

• セキュリティ管理のために必要な調和のとれたソフトウェア環境

機能がクラウドから”エッジ”に移動

インダストリアルIoT: エッジ・Fogコンピューティング

5

スマート

デバイス

Page 6: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

6

長期保守に向けた課題

長期保守の課題

長期保守の課題

年々増える脆弱性問題

コンプライアンスの維持

大量のパッチ

Page 7: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

7

■ 発見される脆弱性は年々増加傾向● JVN iPedia

■ 2014 年の年間登録件数:8,128 件

■ 2018 年の年間登録件数:14,264 件

年々増える脆弱性問題 https://www.ipa.go.jp/files/000071660.pdf

4年間で1.75倍に増加

Page 8: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

8

大量のパッチ

■ 各LTSの総コミット数は1万件前後● 直近の4.19にも3か月で3000件近くのコミット

2019.3 AGL AMMでの柴田次一氏発表資料「 Finding the best way to use Linux kernel : LTSI Project status update 」から抜粋

Version Maintainer ReleasedYears

maintainedTotal

CommitsFixes/year

4.19 Grrg Kroah-Hartman 2018-10-22 0.4 2849 -

4.14 Greg Kroah-Hartman 2017-11-12 1.3 9581 7370

4.9 Greg Kroah-Hartman 2016-12-11 2.2 11537 5244

4.4 Greg Kroah-Hartman 2016-01-10 3.2 10960 3425

3.16 Ben Hutchings 2014-08-03 4.6 10410 2263

As of 2019/3/1

Page 9: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

9

■ ライセンスがリリース後に変更● Redis拡張モジュールに関するライセンス変更(2018年8月)

■ 「Redis」の開発元「Redis Labs」が発表

■ Redis本体のライセンスはBSDライセンスのまま

● MongoDBのライセンス変更(2018年10月)■ 商用サービスでの利用に制限

● 「KSQL」「Confluent Connectors」「REST Proxy」「Schema Registry」などのライセンス変更(2018年12月)■ 「Kafka」の開発元であるConfluentが変更

■ 商用サービスでの利用を制限

コンプライアンスの維持https://www.itmedia.co.jp/news/articles/1901/23/news041.html

クラウドベンダーへの不満を背景とする特殊事情であるが、実際にOSSライセンスがリリース後に変更される可能性があることが認知

Page 10: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

10

長期保守に向けたコミュニティ活動

Page 11: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

11

■ LTS● メインライン(Linusツリー)でのStableリリースから毎年最後のものを選択し、原則2年(or6年)サポート

■ CIP● 産業グレードでの使用が可能なベースレイヤー(SLTS Kernel、数十のcoreパッケージ)をオープンソース

で提供することを目的に活動するLinux Foundation傘下のプロジェクト

● 10年間のサポートを目指す

■ Debian LTS● 総てのDebian stableリリースに最低5年の寿命を与えるもの

● 最初の3年(stableリリース)はDebianセキュリティチーム、それ以降はボランティアとベンダーで対応

長期保守に向けたコミュニティ活動

Page 12: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

12

現在有効なLTSバージョン

Version Maintainer Released Projected EOL Years

4.19 Greg Kroah-Hartman 2018-10-22 Dec, 2020 2

4.14 Greg Kroah-Hartman 2017-11-12 Jan, 2020 2

4.9 Greg Kroah-Hartman 2016-12-11 Jan, 2023 6

4.4 Greg Kroah-Hartman 2016-01-10 Feb, 2022 6

4.1 Sasha Levin 2015-06-21 May, 2018 3

3.16 Ben Hutchings 2014-08-03 Apr, 2020 6

3.2 Ben Hutchings 2012-01-04 May, 2018 6https://www.kernel.org/category/releases.html

2019.3 AGL AMMでの柴田次一氏発表資料「 Finding the best way to use Linux kernel : LTSI Project status update 」から抜粋

Page 13: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

13

■ LTS● メインライン(Linusツリー)から各年の最後のstable releaseを選択、原則2年間サポート

■ 4.4 / 4.9 は6年に延長

■ CIP SLTS● 2~3年ごとに最新のLTSを選択

● 基本ポリシーは“Upstream First”、LTSとの差分はSoC依存コード程度

Linuxカーネルサポート期間の比較

サポート期間の比較

Stable Release

通常

4.4/4.9

CIP SLTS

3 months

2 Years

6 Years

10 Years

Gap to be filledLTS

Page 14: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

14

■ Debianリリース● Debianは2年に一度リリースを行い、最初の三年はstable、その後LTSと呼ばれる

■ Debian LTS

Debian LTS

Version support architecture schedule

Debian 6 “Squeeze” i386 and amd64 until 29th of February 2016

Debian 7 “Wheezy” i386, amd64, armel and armhf from 26th April 2016 to 31st May 2018

Debian 8 “Jessie” i386, amd64, armel and armhf from 17th June 2018 to June 30, 2020

Debian 9 “Stretch”i386, amd64, armel, armhf and arm64 (to review before start)

2020 to June 2022

Legend: End of life Supported by LTS Debian Stable

https://wiki.debian.org/LTS/

unstable testing stable LTS

Release

3年 2年+

Page 15: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

オープンソースカンファレンス2018 Tokyo/Fall

DebianとCIPの連携

15

Debian

Support

▪ 期間:3 + 2年(Debian-LTS)

▪ ソースpkg数:25000超(67776 バイナリpkg)

Build

▪ ネイティブbuild提供必須

▪ クロスbuildパッケージ作業中(Debian-cross)

▪ Reproducible build

OSS license compliance

▪ DEP-5適用作業中

Testing

▪ パッケージテスト必須

▪ autopkgtest

▪ 限定されたパッケージに対する更なる長期メンテナンス(CIPはDebian-LTSに参画)

▪ Debian-crossへの貢献(Debian-crossへのRFC提出)

▪ ライセンスレビュー結果の交換・共有

▪ アップストリームへのテストケースの貢献

Debianとの連携可能性

Support

▪ 期間:10+ 年

▪ pkg数:10+ (最小)

Build

▪ ネイティブbuild、クロスbuild両方必要

▪ バイナリ/ソースコード管理、reproducible要件

OSS license compliance

▪ レポートの自動生成

▪ 容易な再配布

Testing

▪ 全パッケージのタイムリーなテスト

CIP要件

Page 16: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

16

サポート期間

CIPコアパッケージ(数十)

CIP kernel(CIP参照SoCドライバ含)

追加のパッケージ(数百)

CIP

スコ

ープ

顧客固有のミドルウェア/

アプリケーション

CIP外SoCドライバ

サポート期間10年5年

CIPでのサポート

Debian LTS

SoC依存

Page 17: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

17

CIP(Civil Infrastructure Platform)

Page 18: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

CIP is the Solution

社会インフラ構築のための

ソフトブロックとして超長期

で使用・実装可能な産業

グレードのオープンソース

ベースレイヤを提供

The Smart City Event, FL, 2019 18

Page 19: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

オープンソースベースレイヤ (OSBL)とは?

The Smart City Event, FL, 2019 19

CIPコアパッケージ(数十)

CIP kernel(LTSカーネルベースで10年以上のメンテナンス)

追加のパッケージ(数百)

CIP Civil Infrastructue Platform Project (https://www.cip-project.org/) LTS Long Term Support

ベース

レイヤー

顧客固有のミドルウェア/アプリケーション

典型的な

Linuxディストロの

スコープ

Page 20: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

会員会社が支えるCIP活動

The Smart City Event, FL, 2019 20

開発者/メンテナー

€¥

活動費用

オープンソースプロジェクト(アップストリーム)

貢献 & 使用 & 統合オプション:特定の

プロジェクトにファンド

ルネサス エレクトロニクス Siemens 東芝

Codethink サイバートラスト 日立製作所 ぷらっとホームMoxa

会員会社

Page 21: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

オープンソースカンファレンス2018 Tokyo/Fall

CIPの開発モデル

アップストリームプロジェクト

KernelCILTS

mainline

Jailhouse

CIPがすでに連携(貢献、使用、ファンド等)しているプロジェクト 将来の連携候補

CIPオープンソースベースレイヤ (OSBL)

1 “Upstream first”

1 “Upstream first”

2 使用

3 統合

SWUpdate

Page 22: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

オープンソースカンファレンス2018 Tokyo/Fall

IoT対応の課題

22

産業グレード

• 信頼性• 機能安全• リアルタイム性

サステナビリティ• 長期に亘る製品寿命• 互換性• 標準対応

セキュリティ• セキュリティ・脆弱性管理• ファームウェア更新• デグレードリスクの最小化

つながる数百万のシステムをセキュアに維持

産業システムへのIoTコンセプト適用

製品品質、製品寿命の確保

Page 23: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

オープンソースカンファレンス2018 Tokyo/Fall

CIP活動スコープ

23

ユー

ザス

ペー

スカ

ーネ

ルス

ペー

Linuxカーネル

アプリケーションコンテナー基盤 (中期目標)アプリケーションフレームワーク

(オプション:中期目標)

ミドルウェア/ライブラリ

Safe & SecureUpdate

Monitoring

Domain Specific communication(e.g. OPC UA)

Shared config. & logging

Real-time supportReal-time /

safe virtualization

ツール コンセプト

Build environment(e.g. bitbake, dpkg)

Test automation

Tracing & reporting tools

Configurationmanagement

Device management(update, download)

Functional safetyarchitecture/strategy, including compliancew/ standards (e.g., NERC CIP, IEC61508)

Long-term supportStrategy: security patchmanagement

Standardizationcollaborative effort with others

License clearing

Export Control Classification

デバイス上のソフトウェアスタック 製品開発・メンテナンス

Application life-cycle management

Security

Multimedia

Super Long Term Supported Kernel (STLS)1

3

2

CIP Core Packages4 41

4

56

Page 24: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

CIP運営体制と活動プロジェクト

The Smart City Event, FL, 2019 24

技術運営委員会 (TSC)

SLTS kernel Real-time Testing CIP Core Security WG(*) Software update WG (*)

1 32 4 5 6(*): Workgroup

理事会 (GB)

✔ ✔ ✔ ✔ ✔ ✔ 産業グレード

✔ ✔ ✔ ✔ サステナビリティ

✔ ✔ ✔ ✔ ✔ セキュリティ

CIP WG対応課題

Page 25: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

25

まとめ

Page 26: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

26

■ 組込み領域での長期サポートの取り組みがIIoTの流れもあり、広く求められてきていますが、そこには課題があります

■ その実現に向けて、コミュニティが活動を行っており、その一つの例がCIPです

■ CIPは共通で使われるベースレイヤを対象に、産業グレードでの10年+の使用に資するよう活動を行っています

まとめ

Page 27: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

27

ご清聴いただき、ありがとうございました。

Page 28: 組込みLinuxの長期運用に向けたコミュニティでの取り組み · ツール コンセプト Build environment (e.g. bitbake, dpkg) Test automation Tracing & reporting

Copyright Cybertrust Japan Co., Ltd.公開

28

信頼とともに

留意事項

本資料に記載されている会社名、製品名、サービス名は、当社または各社、各団体の商標もしくは登録商標です。その他本資料に記載されているイラスト・ロゴ・写真・動画・ソフトウェア等は、当社または第三者が有する知的財産権やその他の権利により守られております。お客様は、当社が著作権を有するコンテンツについて、特に定めた場合を除き、複製、改変、頒布などをすることはできません。

本資料に記載されている情報は予告なしに変更されることがあります。また、時間の経過などにより記載内容が不正確となる場合がありますが、当社は、当該情報を更新する義務を負うものではありません。