LoginSignup
1
1

More than 5 years have passed since last update.

RaspberryPi 3(Stretch) でAWS Greengrass のチュートリアルをやるときのメモ

Posted at

AWS GreengrassチュートリアルをRaspberry Pi 3(Stretch)で実践するに当たって、ハマったところのメモです。

RaspberryPiにSDカードを挿す前にすること

以下の/Volumes/bootはMacの場合です。Windowsの場合は、そのままbootという名前でディスクが見えていると思います。

ネットワーク設定

SDカードにイメージを書き込んで/Volumes/bootsshというファイルを作成した後、同じく/Volumes/bootwpa_supplicant.confを作成します。
こちらのツールを使うと簡単にファイルを作成することができます。
Raspberry Piの無線LANをmicroSDで簡単に設定するためのツールを作った

cmdline.txtの修正(ハマりどころ)

/Volumes/boot/cmdline.txtcgroup_memory=1を追記します。

dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=PARTUUID=37665771-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet init=/usr/lib/raspi-config/init_resize.sh cgroup_memory=1

これをしないと、GreengrassCoreを起動するときに、runtime.logこのようなエラーが発生して起動できません。

Started all system components
Deployment agent connected to cloud
Started Deployment Agent and listening for updates
Started Deployment Agent and listening for updates
Runtime execution error: unable to start lambda container. container_linux.go:259: starting container process caused "process_linux.go:345: container init caused \"process_linux.go:286: setting cgroup config for ready process caused \\\"no such directory for memory.limit_in_bytes\\\"\""
failed to start worker: container_linux.go:259: starting container process caused "process_linux.go:345: container init caused \"process_linux.go:286: setting cgroup config for ready process caused \\\"no such directory for memory.limit_in_bytes\\\"\""
Runtime failed to start: post-start check failed, error: a check has timed out, check

参考:Greengrass v1.1.0 ARMv7l runtime execution error

上記Forumの議論でsudo apt-get install --reinstall raspberrypi-bootloader raspberrypi-kernelが出てきますが、これはやらなくても大丈夫でした。

必要なファイルを入れておく(Optional)

チュートリアルの中で、Greengrasscoreと証明書類をSCPでRaspberryPiに送るという手順がありますが、これらのファイルを/Volumes/bootに入れておくと、起動後のRaspberryPiの/bootにこのファイルが残っているので、ちょっと楽できます。

残りの手順

後は、チュートリアルのページ通りに進めるだけです。

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1