sh MakeArchLinux-Rpi2.sh

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了sh MakeArchLinux-Rpi2.sh相关的知识,希望对你有一定的参考价值。

TGTDEV=/dev/sdb
# to create the partitions programatically (rather than manually)
# we're going to simulate the manual input to fdisk
# The sed script strips off all the comments so that we can
# document what we're doing in-line with the actual commands
# Note that a blank line (commented as "defualt" will send a empty
# line terminated with a newline to take the fdisk default.
sed -e 's/\s*\([\+0-9a-zA-Z]*\).*/\1/' << EOF | fdisk ${TGTDEV}
  o # clear the in memory partition table
  n # new partition
  p # primary partition
  1 # partition number 1
    # default - start at beginning of disk
  +100M # 100 MB boot parttion
  t # type
  c # W95 FAT32 (LBA)
  n # new partition
  p # primary partition
  2 # partion number 2
    # default, start immediately after preceding partition
    # default, extend partition to end of disk
  a # make a partition bootable
  1 # bootable partition is partition 1 -- /dev/sda1
  p # print the in-memory partition table
  w # write the partition table
  q # and we're done
EOF
mkfs.vfat /dev/sdb1
mkfs.ext4 -F /dev/sdb2
mkdir boot
mkdir root
wget -c http://os.archlinuxarm.org/os/ArchLinuxARM-rpi-2-latest.tar.gz
bsdtar -xpf ArchLinuxARM-rpi-2-latest.tar.gz -C root
sync
mv root/boot/* boot
umount boot root

以上是关于sh MakeArchLinux-Rpi2.sh的主要内容,如果未能解决你的问题,请参考以下文章

sh nuke-pj2.sh

sh habitat_plan_2.sh

sh node_build_2.sh

sh jupyter_notebook_ec2.sh

sh jupyter_notebook_ec2.sh

sh ec2-describe-list.sh