admin管理员组文章数量:1355136
准备材料:
- Armbian镜像包
- U盘
- 机顶盒
一、下载Armbian镜像包
项目路径:
GitHub
GitCode国内访问速度很快的"GitHub"但release的安装包什么的无法下载
文件 Armbian_25.02.0_amlogic_s905l3a_noble_6.12.13_server_2025.02.12.img.gz
里面的 25.02.0
是Armbian版本, s905l3a
是芯片版本, 6.12.13
是linux的内核版本, 根据自己实际的芯片下载
二、下载烧写工具,烧写镜像包
下载安装BalenaEtcher镜像烧写工具
- 选择镜像
注: 镜像下载完可以不用解压直接使用
-> U盘 -> 烧录
- 烧录完成
三、启动安装Armbian系统
- 机顶盒插入烧录好的U盘,重启机顶盒(如果重启无法进入Armbian系统,需要连接adb或串口执行
reboot update
) - 系统启动完成
- 设置root的密码
- 设置新用户和用户语言
Choose default system command shell:
1) bash
2) zsh
1 # 选择bash
Shell: BASH
Creating a new user account. Press <Ctrl-C> to abort
Please provide a username (eg. your first name): balabala # 设置用户balabala账号
Create user (balabala) password: ****** # 设置用户balabala密码
Repeat user (balabala) password: ****** # 重复balabala密码
...
Set user language based on your location? [Y/n]Y # 设置用户语言
At your location, more localer are possible:
1) bo_CN 4) ug_CN@latin
2) ug_CN 5) zh_CN.UTF-8
3) ug_CN@latin 6) Skip generating locales
Please enter your choice:5 # 选择中文语言
Generating locales: zh_CN.UTF-8
- 设置完成
_ _ _ ___ ___
/_\ _ _ _ __ | |__(_)__ _ _ _ / _ \/ __|
/ _ \| '_| ' \| '_ \ / _` | ' \ | (_) \__ \
/_/ \_\_| |_|_|_|_.__/_\__,_|_||_| \___/|___/
v25.02.0 for Aml.S905l3a running Armbian Linux 6.12.13-ophub
Packages: Ubuntu stable (noble)
IP addresses: (LAN) IPv4: 192.168.3.154 (WAN) 183.239.***.***
Performance:
Load: 44% Up time: 7 min
Memory usage: 9% of 1.89G
CPU temp: 40°C Usage of /: 4% of 57G
storage/: 29% of 510M
RX today: 2 KiB
Commands:
Configuration : armbian-config
Monitoring : htop
root@armbian:~#
- 默认的源大概率是无法拉到安装包,需要切换源站点
armbian-apt
root@armbian:~# armbian-apt
[ STEPS ] Welcome to the Armbian source change script.
[ INFO ] Please select a [ noble ] mirror site.
┌──────┬───────────────────┬────────────────────────────────┐
│ ID │ Country/Region │ Mirror Site │
├──────┼───────────────────┼────────────────────────────────┤
│ 0 │ - │ Restore default source │
│ 1 │ China │ mirrors.tuna.tsinghua.edu │
│ 2 │ China │ mirrors.bfsu.edu │
│ 3 │ China │ mirrors.aliyun │
│ 4 │ Hongkong, China │ mirrors.xtom.hk │
...
│ 20 │ Japan │ mirrors.xtom.jp │
└──────┴───────────────────┴────────────────────────────────┘
[ OPTIONS ] Please Input ID: 2 # 我选择了mirrors.bfsu.edu的源
[ INFO ] Your selected source ID is: [ 2 ]
[ STEPS ] Start to change the source of the system: [ mirrors.bfsu.edu ]
[ INFO ] The system release is: [ noble ]
[ SUCCESS ] Change the source of the system successfully.
- 获取源安装包列表
apt update
root@armbian:~# apt update # 更新列表
Get:1 http://mirrors.bfsu.edu/ubuntu-ports noble InRelease [256 kB]
Get:2 http://mirrors.bfsu.edu/ubuntu-ports noble-security InRelease [126 kB]
Get:3 http://mirrors.bfsu.edu/ubuntu-ports noble-updates InRelease [126 kB]
...
Get:23 http://mirrors.bfsu.edu/ubuntu-ports noble-backports/universe arm64 Packages [16.1 kB]
Fetched 187 MB in 36s (5,188 kB/s)
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
36 packages can be upgraded. Run 'apt list --upgradable' to see them.
- 安装apache
apt install apache2 -y
- 需要共享的文件放到
/var/www/html
目录下,html目录下的index.html修改后缀,不然每次访问http://机顶盒ip
都是访问index.html
四、如果没有把Armbian系统安装到EMMC,所有的设置都会设置在U盘内,下面是把系统安装到机顶盒内
root@armbian:~# armbian-install
[ STEPS ] Installing Armbian to internal eMMC...
[ STEPS ] Checking dependencies...
[ INFO ] Dependency check completed. Proceeding installation...
[ STEPS ] Initializing the environment...
[ INFO ] Use mainline u-boot: [ no ]
[ INFO ] Use ampart tool: [ yes ]
[ INFO ] Show all devices: [ no ]
[ INFO ] Internal eMMC : [ /dev/mmcblk2 ]
[ STEPS ] Start selecting device...
-----------------------------------------------------------------------------------------------------
ID SOC MODEL DTB
-----------------------------------------------------------------------------------------------------
301 s905x2 X96-Max-4GB,Tx5-Max meson-g12a-x96-max.dtb
302 s905x2 X96-Max-2GB,A95X-F2 meson-g12a-x96-max-rmii.dtb
303 s905x2 MECOOL-KM3-4G meson-g12a-sei510.dtb
304 s905l3a ♥,E900V22C-D,CM311-1a-CH,IP112H,B863AV3.1 meson-g12a-s905l3a-e900v22c.dtb
305 s905l3a ♥,CM311-1a-YST meson-g12a-s905l3a-cm311.dtb
306 s905l3a M401A,UNT403A,B863AV3.2-M meson-g12a-s905l3a-m401a.dtb
0 Other Customize Enter-custom-dtb-name
-----------------------------------------------------------------------------------------------------
[ OPTIONS ] Please Input ID: 304 # 我的机顶盒是CM311-1a-CH所以选择304
[ INFO ] Input Box ID: [ 304 ]
[ INFO ] Model Name: [ ♥,E900V22C-D,CM311-1a-CH,IP112H,B863AV3.1 ]
[ INFO ] FDTFILE: [ meson-g12a-s905l3a-e900v22c.dtb ]
[ INFO ] MAINLINE_UBOOT: [ ]
[ INFO ] BOOTLOADER_IMG: [ ]
[ INFO ] UBOOT_OVERLOAD: [ u-boot-e900v22c.bin ]
[ INFO ] NEED_OVERLOAD: [ yes ]
[ STEPS ] Which type of filesystem do you want for your root?
-----------------------------------------------
ID TYPE
-----------------------------------------------
1 ext4
2 btrfs
-----------------------------------------------
[ OPTIONS ] Please Input ID (1/2): 1 # 选择系统格式,一般都是ext4
[ INFO ] Input Type ID: [ 1 ]
[ INFO ] Type of filesystem: [ ext4 ]
[ STEPS ] Partitioning eMMC...
[ INFO ] Start backing up the default bootloader.
4+0 records in
4+0 records out
4194304 bytes (4.2 MB, 4.0 MiB) copied, 0.339601 s, 12.4 MB/s
[ STEPS ] Successfully partitioned internal eMMC with amaprt.
[ INFO ] Start create MBR and partittion.
[ 725.559467] mmcblk2:
[ 725.646379] mmcblk2: p1
[ 725.735320] mmcblk2: p1 p2
[ INFO ] 03. Write the mybox bootloader: [ /usr/lib/u-boot/mybox-bootloader.img ]
444+0 records in
444+0 records out
444 bytes copied, 0.0[ 725.748082] mmcblk2: p1 p2
0734977 s, 60.4 kB/s
8191+0 records in
8191+0 records out
4193792 bytes (4.2 MB, 4.0 [ 726.009661] mmcblk2: p1 p2
MiB) copied, 0.259703 s, 16.1 MB/s
[ STEPS ] Processing BOOTFS partition...
[ INFO ] Formatting BOOTFS partition...
mkfs.fat 4.2 (2021-01-31)
[ INFO ] Copying BOOTFS ...
[ INFO ] Update the [ uEnv.txt ] file.
[ INFO ] Copy [ u-boot-e900v22c.bin ] to u-boot.emmc
[ STEPS ] Start processing the rootfs partition...
[ INFO ] Formatting ROOTFS ...
[ 760.837447] EXT4-fs (mmcblk2p2): mounted filesystem 6a737033-1141-4674-8fd4-0e1e255ee38d r/w with ordered data mode. Quota mode: none.
[ INFO ] Copying ROOTFS ...
[ INFO ] Copying [ etc ] ...
[ INFO ] Copying [ home ] ...
[ INFO ] Copying [ opt ] ...
[ INFO ] Copying [ root ] ...
[ INFO ] Copying [ selinux ] ...
[ INFO ] Copying [ srv ] ...
[ INFO ] Copying [ usr ] ...
[ INFO ] Copying [ var ] ...
[ INFO ] Generate the new fstab file.
[ INFO ] Update parameters related to the releases file.
[ INFO ] Update the MAC address for the wireless network card.
[ 866.502123] EXT4-fs (mmcblk2p2): unmounting filesystem 6a737033-1141-4674-8fd4-0e1e255ee38d.
[ SUCCESS ] Installation successful. Run [ poweroff ], remove the installation media then re-insert the power supply to boot new system. # 安装成功。运行[poweroff],移除安装介质,然后重新插入电源以启动新系统。
root@armbian:~# poweroff
版权声明:本文标题:Armbian安装搭建apache 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/biancheng/1743967938a2570232.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论