網頁查詢Raspberry Pi狀態-RPi-Monitor 安裝
RPi-Monitor 是一款專給Raspberry Pi使用的網頁程式,它能從網頁清楚的了解Raspberry Pi的狀態,
除此之外還能透過自訂的方式增加功能,例如透過增加溫度感測器之後讓網頁增加溫度顯示:
這會在另一篇來做介紹,現在要先了解如何安裝RPi-Monitor。
安裝RPi-Monitor
首先透過直接操作的方式或是遠端ssh
登入的方式進到Console並一步一步的依照指令輸入。
- 更新套件來源
sudo apt-get update
- 安裝相關套件
RPi-Monitor套件來源使用https
的方式,apt-get
本身預設不支援,需要先安裝相關套件來支援。
sudo apt-get install apt-transport-https ca-certificates
- 加入RPi-Monitor套件來源
sudo wget http://goo.gl/rsel0F -O /etc/apt/sources.list.d/rpimonitor.list
- 加入public key
sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 2C0D3C0F
- 安裝RPi-Monitor
sudo apt-get update sudo apt-get install rpimonitor
- 更新apt-get套件資訊
sudo apt-get update sudo apt-get upgrade
- 更新RPi-Monitor套件資訊
這個動態會透過網路連接來檢查目前的狀態是否要更新,所以會耗一點時間耐心等待。
sudo /usr/share/rpimonitor/scripts/updatePackagesStatus.pl
啟動/停止 RPi-Monitor
重新啟動
sudo service rpimonitor restart
啟動
sudo service rpimonitor start
停止
sudo service rpimonitor stop
使用RPi-Monitor
在使用之前先看一下Raspberry Pi的IP位址:
ifconfig | grep inet
可能會看到:
inet addr:192.168.9.130 Bcast:192.168.9.255 Mask:255.255.255.0 inet addr:127.0.0.1 Mask:255.0.0.0
127.0.0.1是屬於localhost,把它排除,第一個192.168.9.130
就是對外的IP位址,接下來開啟瀏覽器:
http://192.168.9.130:8888
預設的情況下連接埠為8888
,運作正常的話就能看到歡迎的頁面:
按下Start
進入主要的頁面:
第一頁為OverView整個狀態,如果要細看的話選擇Statistics
選單並選擇Raspberry Pi
:
這篇完成RPi-Monitor的安裝,該作者已經簡化很多流程使用與安裝都非常的簡便,官網上也有許多教學及說明推廣RPi-Monitor,如果按照上途安裝的過程不理想的話,也可以看著官網說明RPi-Monitor Installation下載rpimonitor_latest_all.deb
套件自行手動安裝。
關鍵字
網頁查詢Raspberry Pi狀態-RPi-Monitor 安裝