Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Buildrootでsftpサーバーをビルド

Sponsored · Your Podcast. Everywhere. Effortlessly. Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
Avatar for kazueda kazueda
February 19, 2024
200

 Buildrootでsftpサーバーをビルド

2024. 2. 18開催の「鹿児島Linux勉強会 2024.2」での発表

Avatar for kazueda

kazueda

February 19, 2024
Tweet

More Decks by kazueda

Transcript

  1. kazueda(かずえだ)の紹介 • 大阪出身、丙午、おとめ座、O型 • 科学者(化学) • 2003年4月から浜松で、働き始める • 自転車での移動が生活の足 •

    趣味は「ラジオを聴くこと」、「アメ リカのコミックの邦訳を読むこと」 @kazueda 2 slideshare speaker deck https://qiita.com/kazueda
  2. Milk-v duo 6 - CVITEK CV1800B (C906@1Ghz + C906@700MHz) -

    Dual RV64 Core up to 1GHz - 64MB RAM - Provides 10/100Mbps Ethernet via optional add-on board - Technology supports running both Linux and RTOS 「Milk-v duoでPython」秋葉原ロボット部 第131回、2023. 8. 27
  3. Milk-v duo 7 - CVITEK CV1800B (C906@1Ghz + C906@700MHz) -

    Dual RV64 Core up to 1GHz - 64MB RAM - Provides 10/100Mbps Ethernet via optional add-on board - Technology supports running both Linux and RTOS 「Milk-v duoでPython」秋葉原ロボット部 第131回、2023. 8. 27 特徴 • コミュニィティ主体で展開 • 情報の鮮度が短い(すぐ、自動でパッチが当てられなくな る、ソースへのマージを待つ方が時間の節約)。 • 情報の主な言語が中国語(ソフトはBaidu、ハードは Oshwhub、利用にはWeChatのIDが必要) • Raspberry pi (pico)の情報や周辺機器を転用可能 • オープンハードウェアとオープンソフトウェア • Linuxのリソース • pinpongライブラリを介してPythonで制御
  4. Mind+ 9 https://mindplus.cc/en.html 特徴 • Scratch3.0から派生 • ブロックを使ったビジュアルプログラミング環境 • 対応言語は、Arduino

    CとPython • ブロックプログラムをテキストファイルに • 対応マイクロコントローラは、Arduino、microbit、ESP32ベ ースのデバイス等
  5. Mind+ 10 https://mindplus.cc/en.html 特徴 • Scratch3.0から派生 • ブロックを使ったビジュアルプログラミング環境 • 対応言語は、Arduino

    CとPython • ブロックプログラムをテキストファイルに • 対応マイクロコントローラは、Arduino、microbit、ESP32ベ ースのデバイス等 • Debian OSで動作するUNIHIKER
  6. Mind+ 11 https://mindplus.cc/en.html 特徴 • Scratch3.0から派生 • ブロックを使ったビジュアルプログラミング環境 • 対応言語は、Arduino

    CとPython • ブロックプログラムをテキストファイルに • 対応マイクロコントローラは、Arduino、microbit、ESP32ベ ースのデバイス等 • Debian OSで動作するUNIHIKER <ーMilk-v duoでも使える?
  7. これまでのお話 • SSH接続してきたクライアントのログをとる • 「/etc/ssh/sshd_config」 の Log Level「-l log_level」 Jan

    21 16:29:34 raspi4 sftp-server[2043]: received client version 3 Jan 21 16:29:34 raspi4 sftp-server[2043]: open "/usr/local/lib/python3.7/dist-packages/.pth" flags WRITE,CREATE,TRUNCATE mode 0666 Jan 21 16:29:34 raspi4 sftp-server[2043]: sent status No such file Jan 21 16:29:34 raspi4 sftp-server[2043]: debug1: read eof Jan 21 16:29:34 raspi4 sftp-server[2043]: session closed for local user root from [192.168.0.31] 15
  8. これまでのお話 • 「/etc/ssh/sshd_config」 の Log Level「-l log_level」 Jan 21 16:29:34

    raspi4 sftp-server[2043]: received client version 3 Jan 21 16:29:34 raspi4 sftp-server[2043]: open "/usr/local/lib/python3.7/dist-packages/.pth" flags WRITE,CREATE,TRUNCATE mode 0666 Jan 21 16:29:34 raspi4 sftp-server[2043]: sent status No such file Jan 21 16:29:34 raspi4 sftp-server[2043]: debug1: read eof Jan 21 16:29:34 raspi4 sftp-server[2043]: session closed for local user root from [192.168.0.31] 16 Linuxマシン側に "/usr/local/lib/python3.7/dist-packages を作成
  9. buildrootでsftpサーバー The build of gesftserver in an environment without Python

    fails with: checking for Python 2.4 or better... configure: error: cannot find Python 2.4 or better However, it turns out that Python is only needed for tests, which we don't run/use in Buildroot, so we can safely build gesftpserver without Python. 21 https://git.buildroot.net/buildroot/commit/?id=422fd73fadfbe33523e1687f90bbfecd3f7ab5d5
  10. buildrootでsftpサーバー @@ -23,6 +23,10 @@ GESFTPSERVER_DEPENDENCIES += ¥ $(if $(BR2_ENABLE_LOCALE),,libiconv)

    ¥ $(if $(BR2_PACKAGE_OPENSSH),openssh) +# Python on the host is only used for tests, which we don't use in +# Buildroot +GESFTPSERVER_CONF_ENV += rjk_cv_python24=false + # openssh/dropbear looks here define GESFTPSERVER_ADD_SYMLINK ln -sf gesftpserver $(TARGET_DIR)/usr/libexec/sftp-server 23 https://lore.kernel.org/buildroot/[email protected]/T/