Raspberry Pi 定制Archlinux

步骤。

linux机器一台。本人用的是linux mint 13 cinnamon

now we use "dd" promote to copy files into SD card.

dd if=/home/xxx/Downloads/archlinux.img of=/dev/sdX bs=2M

According to the references on  https://wiki.archlinux.org/index.php/Raspberry#Installation

The default img is of 2GB.

Home

The downloaded image file is approximately 2 gigabytes of which is /boot 94 megabytes and / 1.8 gigabytes. If you used a larger card to 2GB, so I recommend the rest of the card to connect as /home (or /usr). Clearance must be formatted using the exampleGparted. At the first possible opportunity (after booting RPI or after mounting the card in the computer) need to be adjusted /etc/fstab

Now we use

cfdisk /dev/sdb


We change the /dev/sdb disk into this style


Then:


Now we need to edit /etc/fstab file of /dev/mmcblkp2.  /dev/mmcblkp1 is the /boot folder whose format is fat32.

sudo mount /dev/sdb2 /mnt
cd /mnt
sudo vim ./etc/fstab



we add these things into the "fstab"


you will get more help from :

https://wiki.archlinux.org/index.php/Raspberry#Installation

https://wiki.archlinux.org/index.php/Installation_Guide#Install_the_base_system

https://wiki.archlinux.org/index.php/HOW_TO:_Create_swap_file#Swap_file


After these settings, we need to plug the SD card into Raspberry Pi and boot.

By default, Archlinux on Raspberry Pi will automatically start a SSH daemon service.

We could use:

ssh root@192.168.1.105
password:

password is root by default

Then we get into the Archlinux system over there.

Now we can do these stuff to initiate our Archlinux.

The first operation

Summary of the official procedure:

Remote SSH access

If you do not use the HDMI output RPI and you will access the device using SSH, the following applies. Root pasword is: root. I recommend to perform key exchange SSH_Keys.

$ ssh root@192.168.1.123 (Use your Ip RPI)

Localization

# vim /etc/locale.gen

uncomment en_US.UTF-8 UTF-8 and en_US ISO-8859-2

generate localization files

# locale-gen

Setting the time and date using OpenNTP

dopnit

Setting the time and date manually

complete

Changing the root password

After the first start RPI is native root password to root. It is therefore necessary to change it. Executed after power command passwd

# passwd root

Adding another user

Using adduser to add the user.

# adduser

Sudo

Start visudo

# sudo visudo

add the line "USER ALL = (ALL) ALL" below the line root ALL = (ALL) ALL

Video

The generic xf86-video-fbdev driver can be used.

Serial Console

Edit the default /boot/cmdline.txt

Change loglevel to 5 to see boot messages

# loglevel=5

Change speed from 11520 to 38400

# console=ttyAMA0,38400 kgdboc=ttyAMA0,38400

Start getty service

# systemctl start getty@ttyAMA0

Enable on boot

#systemctl enable getty@ttyAMA0.service

Creating the proper service link:

# ln -s /usr/lib/systemd/system/getty@.service /etc/systemd/system/getty.target.wants/getty@ttyAMA0.service

Then connect :)

# screen /dev/ttyUSB0 38400

https://wiki.archlinux.org/index.php/Raspberry#Installation


Then we get the whole new Archlinux running on Raspberry Pi as we wish :D


Enjoy!



  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值