本文章參考:Raspberry Pi 的基礎 – 安裝 CentOS 7 for ARM ~ IT 技術家
沒有使用原本 Cubie Truck 內建的 Nand 記憶體,改用 T-Flash 記憶卡。
登入帳號及密碼:root / centos
1. 登入之後,先修改密碼
# passwd
Changing password for user root.
New password:
Retype new password:
passwd: all authentication tokens updated successfully.[@more@]
2. 查看內附的說明檔
# cat ~/README
== CentOS 7 userland ==
If you want to automatically resize your / partition, just type the following (as root user):
touch /.rootfs-repartition
systemctl reboot
3. 擴展 root 分割區
# touch /.rootfs-repartition
4. 重新啟動電腦
# systemctl reboot
原本的 T-Flash 記憶卡分割
# df -h
Filesystem Size Used Avail Use% Mounted on
devtmpfs 980M 0 980M 0% /dev
tmpfs 1005M 0 1005M 0% /dev/shm
tmpfs 1005M 17M 989M 2% /run
tmpfs 1005M 0 1005M 0% /sys/fs/cgroup
/dev/mmcblk0p3 2.0G 746M 1.1G 41% /
/dev/mmcblk0p1 283M 134M 134M 51% /boot
tmpfs 201M 0 201M 0% /run/user/0
擴展之後
# df -h
Filesystem Size Used Avail Use% Mounted on
devtmpfs 982M 0 982M 0% /dev
tmpfs 1007M 0 1007M 0% /dev/shm
tmpfs 1007M 17M 991M 2% /run
tmpfs 1007M 0 1007M 0% /sys/fs/cgroup
/dev/mmcblk0p3 6.3G 747M 5.3G 13% /
/dev/mmcblk0p1 283M 134M 134M 51% /boot
tmpfs 202M 0 202M 0% /run/user/0
5. 更新套件
# yum -y update
6. 安裝一些常用但缺少的套件
# yum install vim mlocate which bind-utils ntpdate
7. 設定時區及對時
原本的時區
# date
Thu Jan 1 08:23:09 CST 1970
把時區改成 Asia/Taipei
# /usr/bin/timedatectl set-timezone Asia/Taipei
更改之後
# date
Fri Jan 1 20:10:36 CST 2016
對時
# /usr/sbin/ntpdate -s time.stdtime.gov.tw
# /usr/sbin/hwclock -w
加入工作排程
# echo “0 6 * * * /usr/sbin/ntpdate -s time.stdtime.gov.tw > /dev/null 2>&1;/usr/sbin/hwclock -w > /dev/null 2>&1” >> /var/spool/cron/root
8. 設定語系
# /usr/bin/localectl set-locale LANG=en_US.utf8
檢查設定
# /usr/bin/localectl status
System Locale: LANG=en_US.utf8
VC Keymap: n/a
X11 Layout: n/a