树莓派centos7系统安装配置
目录1.烧录系统2.配置自动连接wifi3.扩展内存4.更换yum源5.docker安装1.烧录系统Centos ARM芯片的版本下载地址:http://mirror.centos.org/altarch/7/isos/armhfp/首先,格式化内存卡,然后将下载的Centos系统解压,写入系统到SD卡中,最后将SD卡插入树莓派。2.配置自动连接wifi...
·
目录
1.烧录系统
Centos ARM芯片的版本下载地址:http://mirror.centos.org/altarch/7/isos/armhfp/
首先,格式化内存卡,然后将下载的Centos系统解压,写入系统到SD卡中,最后将SD卡插入树莓派。
2.配置自动连接wifi
首先,进入vi /etc/wpa_supplicant/wpa_supplicant.conf 文件中配置:
network={
ssid="无线网名称"
psk="密码"
priority=10
}
然后,连接wifi,配置好后每次启动自动连接无线网。
nmcli d wifi connect 无线网名称 password '密码'
3.扩展内存
rootfs-expand
4.更换yum源
首先,将/etc/yum.repos.d/ 文件夹下的文件除了CentOS-Base.repo 都删掉
# 1. 编辑CentOS-Base.repo
[root@centos-rpi3 ~]# vi /etc/yum.repos.d/CentOS-Base.repo
# 2. 不会用vi的朋友别乱动,可以按着d键不松手,即可清空整个文件
# 会的朋友直接清空它就行了
# 3. 复制下面的文字到这个文件中,使用putty的话就是在windows下复制,然后再putty中右键就可以粘贴
# 4. 按Esc,然后输入引号内的内容:“:wq”注意英文符号,随后会退出vi
# 5. 执行下面两句代码:
yum clean all
yum makecache
CentOS-Base.repo 文件内容
# CentOS-Base.repo
#
# The mirror system uses the connecting IP address of the client and the
# update status of each mirror to pick mirrors that are updated to and
# geographically close to the client. You should use this for CentOS updates
# unless you are manually picking other mirrors.
#
# If the mirrorlist= does not work for you, as a fall back you can try the
# remarked out baseurl= line instead.
#
#
[base]
name=CentOS-$releasever - Base
#mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os
baseurl=http://mirrors.ustc.edu.cn/centos-altarch/$releasever/os/$basearch/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-AltArch-Arm32
#released updates
[updates]
name=CentOS-$releasever - Updates
# mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates
baseurl=http://mirrors.ustc.edu.cn/centos-altarch/$releasever/updates/$basearch/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-AltArch-Arm32
#additional packages that may be useful
[extras]
name=CentOS-$releasever - Extras
# mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras
baseurl=http://mirrors.ustc.edu.cn/centos-altarch/$releasever/extras/$basearch/
gpgcheck=1
enabled=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-AltArch-Arm32
#additional packages that extend functionality of existing packages
[centosplus]
name=CentOS-$releasever - Plus
# mirrorlist=http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus
baseurl=http://mirrors.ustc.edu.cn/centos-altarch/$releasever/centosplus/$basearch/
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7
file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-AltArch-Arm32
5.docker安装
安装
#docker安装
sudo yum install docker -y
docker version
启动
service docker start
查看镜像列表
#拉取镜像
docker pull [options] name[:tag]
#查看镜像列表
docker images [options] [repository[:tag]]
更多推荐
已为社区贡献1条内容
所有评论(0)