allen-mbp:~ allen$ ssh pi@raspberrypi.local
pi@raspberrypi.local's password:
Linux raspberrypi 4.9.59-v7+ #1047 SMP Sun Oct 29 12:19:23 GMT 2017 armv7l
The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
Last login: Fri Dec 29 12:50:59 2017 from fe80::1037:567d:9387:a9dc%eth0
SSH is enabled and the default password for the 'pi' user has not been changed.
This is a security risk - please login as the 'pi' user and type 'passwd' to set a new password.
pi@raspberrypi:~ $
更新軟體套件的清單
sudo apt-get update
更新軟體套件
sudo apt-get upgrade
更新韌體
sudo rpi-upgrade
先使用uname -a 指令查詢目前的版本
更新前先查詢版本資訊,目前為「4.9.59-v7+」
pi@raspberrypi:~ $ uname -a
Linux raspberrypi 4.9.59-v7+ #1047 SMP Sun Oct 29 12:19:23 GMT 2017 armv7l GNU/Linux
執行更新
pi@raspberrypi:~ $ sudo rpi-update
*** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
*** Performing self-update
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 13403 100 13403 0 0 20532 0 --:--:-- --:--:-- --:--:-- 20525
*** Relaunching after update
*** Raspberry Pi firmware updater by Hexxeh, enhanced by AndrewS and Dom
*** We're running for the first time
*** Backing up files (this will take a few minutes)
*** Backing up firmware
*** Backing up modules 4.9.59-v7+
#############################################################
This update bumps to rpi-4.9.y linux tree
Be aware there could be compatibility issues with some drivers
Discussion here:
https://www.raspberrypi.org/forums/viewtopic.php?f=29&t=167934
##############################################################
*** Downloading specific firmware revision (this will take a few minutes)
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 168 0 168 0 0 169 0 --:--:-- --:--:-- --:--:-- 169
100 54.1M 100 54.1M 0 0 1490k 0 0:00:37 0:00:37 --:--:-- 3138k
*** Updating firmware
*** Updating kernel modules
*** depmod 4.9.72-v7+
*** depmod 4.9.72+
*** Updating VideoCore libraries
*** Using HardFP libraries
*** Updating SDK
*** Running ldconfig
*** Storing current firmware revision
*** Deleting downloaded files
*** Syncing changes to disk
*** If no errors appeared, your firmware was successfully updated to 9b6060d3962fff5addd51b2eda97b7593c1e14c2
*** A reboot is needed to activate the new firmware
更新後而要重開機,重開機後再查詢版本資訊,已更新為「4.9.72-v7+」
pi@raspberrypi:~ $ uname -a
Linux raspberrypi 4.9.72-v7+ #1069 SMP Fri Dec 29 17:21:52 GMT 2017 armv7l GNU/Linux
Raspberry Pi Software Configuration Tool(raspi-config)
指令:sudo raspi-config
記得要加sudo,用管理者權限執行,否則會出現如下提示訊息
pi@raspberrypi:~ $ raspi-config
Script must be run as root. Try 'sudo raspi-config'