在N1的OpenWRT上安装centos环境

  1. 创建磁盘镜像
cd /mnt/data
dd if=/dev/zero of=centos.img bs=1M count=1024
mkfs.ext4 centos.img
mkdir /centos
mount centos.img /centos
  1. 安装centos
wget http://vault.centos.org/altarch/7.4.1708/isos/aarch64/CentOS-7-aarch64-rootfs-7.4.1708.tar.xz
xz -d CentOS-7-aarch64-rootfs-7.4.1708.tar.xz
tar -xvf CentOS-7-aarch64-rootfs-7.4.1708.tar -C /centos
  1. 进入centos环境
mount -o bind /dev /centos/dev
mount -o bind /dev/pts /centos/dev/pts
mount -o bind /proc /centos/proc
mount -o bind /sys /centos/sys
chroot /centos /bin/bash --login
  1. centos环境下
yum update
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容