跳转到内容
主菜单
主菜单
移至侧栏
隐藏
导航
首页
最近更改
随机页面
MediaWiki帮助
Mcuzone Wiki
搜索
搜索
登录
个人工具
登录
查看“0008 MPS2.5G(SSD and 2.5G ETH)”的源代码
页面
讨论
大陆简体
阅读
查看源代码
查看历史
工具
工具
移至侧栏
隐藏
操作
阅读
查看源代码
查看历史
常规
链入页面
相关更改
特殊页面
页面信息
←
0008 MPS2.5G(SSD and 2.5G ETH)
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:
用户
您可以查看和复制此页面的源代码。
== '''Keywords''' == Raspberry Pi 5, PCIe Expansion, 2.5G, NVMe, M.2, SSD, X1 Gen2 == '''I. Introduction''' == The Raspberry Pi 5 is equipped with a 16-pin PCIe interface, through which we can attach various PCIe devices. This expansion board is specifically designed for the Raspberry Pi 5, offering 2.5G networking and NVMe SSD storage. The expansion board is plug-and-play in the Raspberry Pi system, but the 2.5G network adapter requires driver installation in Ubuntu system. Note: 1. The latest firmware for the Raspberry Pi now supports booting from an SSD connected to the rear of the PCIe Switch. The SSD can be used for storage expansion and system booting. 2. Since the PCIe Switch is x1 Gen2, changing the mode to Gen3 in config.txt will not increase the interface speed; therefore, the SSD interface speed test will be limited to around 400MB/s, which is slightly faster than CM4. <html><iframe style="width: 600px; height: 340px;" src="//player.bilibili.com/player.html?isOutside=true&aid=1950002798&bvid=BV1NC411r7fo&cid=1429673798&p=1&as_wide=1&high_quality=1&autoplay=0" scrolling="no" border="0" frameborder="no" framespacing="0" allowfullscreen="true"></iframe></html> == '''II. Hardware Spec''' == 1. Based on the PCIe interface of the Raspberry Pi 5, a PCIe Switch is used to expand one port into two, providing one NVMe SSD port and one 2.5G Ethernet port. 2. 2.5Gbps Ethernet based on the RTL8125 chip (if the workload on the 2.5G Ethernet port is high, it is recommended to add a heatsink to the onboard chip). 3. Supports NVMe SSD of 2230/2242/2280 sizes (default comes with welded 2280 copper pillars); does not support SATA and NGFF SSD. The SSD can be used for expanded storage and also supports booting from the SSD (requires the Raspberry Pi official firmware to be at least updated to 2024.5.13). Note: After firmware updates, do not modify the settings, as doing so will automatically revert the firmware to the previous version. 4. The RTL8125 2.5G Ethernet adapter is driver-free in the official Raspberry Pi OS and OpenWrt systems, but requires driver installation in Ubuntu systems. 5. Gold immersion PCB process, lead-free production, certified by UL, compliant with ROHS standards, and has a fire rating of 94V-0. 6. The board has four M2.5 mounting holes, with a recessed design on the top of the board to facilitate the use of the 40-Pin GPIO. http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_38.jpg == '''三、系统烧写及设置''' == === 3.1 概述 === This document uses the Raspberry Pi OS, Ubuntu system and OpenWrt system for testing. 1)The version of the Raspberry Pi OS is: 2024-07-04-raspios-bookworm-arm64.img.xz You can download the Raspberry Pi OS in: https://www.raspberrypi.com/software/operating-systems/#raspberry-pi-os-64-bit 2)The version of the Ubuntu system is: ubuntu-24.04-preinstalled-desktop-arm64+raspi.img.xz You can download the Ubuntu system in: https://ubuntu.com/download/raspberry-pi 3)The version of the OpenWrt system is: openwrt-bcm27xx-bcm2712-rpi-5-squashfs-sysupgrade-linux-6.1.100-20240805.img.gz === 3.2 System flashed onto the SD (TF) card === [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#3.2 Boot from TF card|Click here to read the instructions for System flashing]] === 3.3 System flashed onto the SSD === [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#3.3 Boot from SSD|Click here to read the instructions for System flashing]] == '''IV. Work with Raspberry Pi OS''' == === 4.1 2.5G Ethernet test === The 2.5G Ethernet port on the MPS2.5G expansion board is plug-and-play under Raspberry Pi OS and can obtain an IP address once the system is up and running: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_02.jpg You can also enter <code>ifconfig -a</code> in the terminal to view the network status: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_03.jpg Install the network speed testing tool iperf3: <code>sudo apt install iperf3</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_04.jpg Use iperf3 to perform a speed test between the Raspberry Pi OS and the PC. When Raspberry Pi OS acts as a client, the speed is about 2.25 Gbps: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_05.jpg When Raspberry Pi OS acts as a server, the speed is about 1.68 Gbps: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_06.jpg '''''Note: Network speed tests are affected by network conditions and testing methods. The actual speed may vary; this test is for reference only.''''' === 4.2 Fix the MAC address of the 2.5G Ethernet port === {{RTL8125_MAC_SINGLE_EN}} === 4.3 SSD test === For basic operations on the SSD drive, we can refer to the following link: [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#4.1 Use the SSD for storage expansion|1. Use the SSD for storage expansion(Raspberry Pi OS)]] [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#VI. Perform partitioning and other operations on the SSD|2. Perform partitioning and other operations on the SSD]] [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#cite ref-1|3. Adjust the boot devices order]] [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#7.2 Test the SSD speed in PCIe Gen2 mode|4. Install the SSD speed testing software hdparm]] Since the MPS2.5G cannot operate in PCIe Gen3 mode, we do not need to change the PCIe mode and can directly use the hdparm to test the speed. Run <code>df</code> in the Raspberry Pi terminal to check the partition name of the SSD, which is nvme0n1p1: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_07.jpg Excute the command; it can be executed multiple times to test the disk speed repeatedly: <code>sudo hdparm -t /dev/nvme0n1p1</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_08.jpg The test shows that the operating speed of this disk is about 395 MBps. '''''Note: The disk operation speed is affected by various factors including the quality of the disk and the file storage situation on the disk. The above test results are for reference only and do not represent the final parameters of the actual product.''''' == '''V. Work with Ubuntu System''' == === 5.1 2.5G Ethernet test === In Ubuntu system, the 2.5G network card driver needs to be installed to use the device. First, you need to update the system: <code>sudo apt-get update</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_09.jpg Next, prepare the compilation environment: <code>sudo apt-get install --reinstall linux-headers-$(uname -r) linux-headers-generic build-essential dkms</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_10.jpg Then install the driver: <code>sudo apt-get install r8125-dkms</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_11.jpg After installation is complete, excute: <code>sudo modprobe r8125</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_12.jpg Ubuntu系统默认不安装ifconfig工具,所以需要手动安装: <code>sudo apt install net-tools</code> http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_13.jpg Enter <code>ifconfig -a</code> to see the network interface called enxxx, which indicates that the 2.5G network card driver has been successfully installed: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_14.jpg Use iperf3 to perform a speed test between the Ubuntu system and the PC. When Ubuntu system acts as a client, the speed is about 2.26 Gbps: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_15.jpg When Ubuntu system acts as a server, the speed is about 1.70 Gbps: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_16.jpg '''''Note: Network speed tests are affected by network conditions and testing methods. The actual speed may vary; this test is for reference only.''''' === 5.2 SSD test === For basic operations on the SSD drive, we can refer to the following link. Only the SSD being used as storage expansion having slightly different operations under the Raspberry Pi OS, the rest of the processes are largely the same. [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#5.1 Use the SSD for storage expansion|1. Use the SSD for storage expansion(Ubuntu system)]] [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#VI. Perform partitioning and other operations on the SSD|2. Perform partitioning and other operations on the SSD]] [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#cite ref-1|3. Adjust the boot devices order]] [[0005 MPS2242 2280 2280P(Single SSD Expansion Board)#7.2 Test the SSD speed in PCIe Gen2 mode|4. Install the SSD speed testing software hdparm]] Since the MPS2.5G cannot operate in PCIe Gen3 mode, we do not need to change the PCIe mode and can directly use the hdparm to test the speed. Run <code>df</code> in the terminal to check the partitions' name of the SSD, which are nvme0n1p1 and nvme0n1p2: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_17.jpg We select one to perform a speed test: <code>sudo hdparm -t /dev/nvme0n1p1</code> Excute the command; it can be executed multiple times to test the disk speed repeatedly: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_18.jpg The test shows that the operating speed of this disk is about 430 MBps. '''''Note: The disk operation speed is affected by various factors including the quality of the disk and the file storage situation on the disk. The above test results are for reference only and do not represent the final parameters of the actual product.''''' == '''VI. Work with OpenWrt System''' == === 6.1 Overview === The MPS2.5G expansion board can be configured as a two-in-two-out switch mode under the OpenWrt system. The 2.5G Ethernet port on the expansion board can be used as the WAN port (connected to the Internet), or the built-in WiFi on the Raspberry Pi 5 can be used as the WAN port (connected to the Internet). The Ethernet port on the Raspberry Pi 5 is configured as a LAN port for connecting to a PC, or the built-in WiFi on the Raspberry Pi 5 can be used as a wireless AP to connect devices such as smartphones. === 6.2 Preparation === After flashing the OpenWrt system and powering it up, we connect an Ethernet cable from the Raspberry Pi 5's built-in Ethernet port to the PC's Ethernet port, connect the Ethernet cable from the router to the 2.5G Ethernet port on the expansion board.Once the connection between the PC's network card and the Raspberry Pi's Ethernet port is successful, we find Network and Internet settings in Windows, then open the connected network under Ethernet to view the default gateway IP address. This address is the backend configuration page address for the OpenWrt system. As shown in the figure, the address for this test is 192.168.198.1: http://www.mcuzone.com/wiki/2001_CM4_Ultra/2001_CM4_Ultra_53.jpg Then open a web browser and enter 192.168.198.1 to access the OpenWrt system. The default username is <code>root</code>, and the default password is <code>password</code>: http://www.mcuzone.com/wiki/2001_CM4_Ultra/2001_CM4_Ultra_54.jpg === 6.3 PC accesses the internet through the 2.5G Ethernet port. === Open "Network - Interfaces", and click "Add new interface": http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_19.jpg Set "Name of the new interface" as WAN, choose "DHCP client" for "Protocol of the new interface," select "eth1" for "Cover the following interface," and then click the "SUBMIT" button: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_20.jpg In the "Firewall Settings", select the WAN and then click the "SAVE & APPLY" button: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_21.jpg Go back to "Network - Interfaces", wait a moment, and you will see the newly created WAN interface has obtained an IP address. This way, the PC can access the internet through the MPS2.5G expansion board: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_22.jpg Open https://www.speedtest.cn/ on the PC to test speed. The test results are as follows: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_23.jpg '''''Note: The speed test can be affected by the network environment and the testing method. Speeds should be considered based on actual results; this test is for reference only.''''' === 6.4 Use the Raspberry Pi's built-in WiFi as a wireless AP (in master mode) === By default, the wireless module included with the Raspberry Pi 5 is already configured as a wireless AP, which we can see under "Network - Wireless": http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_24.jpg Click "Edit", and under "Interface Configuration - Basic Settings", you can see the SSID of this AP: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_25.jpg We can use a smartphone to search for this AP, and after connecting to it, we can access the internet (the smartphone connects to the AP created by the Raspberry Pi 5's native wireless network card, the 2.5G Ethernet port acts as the WAN port connected to the upstream router, and the native Gigabit Ethernet port acts as the LAN port connected to the PC): http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_26.jpg === 6.5 Use the Raspberry Pi's built-in WiFi as a Client === This section mainly describes how to use the Raspberry Pi's built-in WiFi as a client, meaning the Raspberry Pi connects to an upstream router via WiFi. View the wireless profile under "Network - Wireless": http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_27.jpg Click the "Scan" button to scan for nearby wireless APs: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_28.jpg Select one to connect, and choose WAN for the firewall: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_29.jpg Then click "SUBMIT", and after submitting, click "SAVE & APPLY": http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_30.jpg After succeeding, go back to "Wireless Overview", and you will see that the wireless connection has been established successfully:http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_31.jpg Go back to "Network - Interfaces", and you can see that the newly created WAN interface has obtained an IP address. The PC can connect to the internet through the wireless module and the upstream router: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_32.jpg Open https://www.speedtest.cn/ on the PC to test speed. The test results are as follows: http://www.mcuzone.com/wiki/0008_MPS2_5G/0008_MPS2_5G_40.jpg '''''Note: The speed test can be affected by the network environment and the testing method. Speeds should be considered based on actual results; this test is for reference only.''''' === 6.6 SSD test === Under the OpenWrt system, the MPS2.5G expansion board defaults to the native Gigabit Ethernet port on the Raspberry Pi as the LAN port. We can set the 2.5G Ethernet port on the expansion board as LAN port and use the native Ethernet port on the Raspberry Pi 5 as the WAN port. So we can leverage the 2.5G port for high-speed file transfer within the local network. Switch the LAN port, and then proceed with the SSD disk testing. Please refer to the following document: [[0015 MP2.5G(单2.5G以太网)#6.3 MP2.5D的2.5G网口的配置和应用|MP2.5D的2.5G网口的配置和应用]] [[0010 MPSD2.5GD(双SSD和双2.5G以太网)#6.4 双SSD硬盘存储测试|双SSD硬盘存储测试]] {{联系我们_图标}}
本页使用的模板:
模板:Contact Us icon
(
查看源代码
)
模板:RTL8125 MAC SINGLE EN
(
查看源代码
)
返回
0008 MPS2.5G(SSD and 2.5G ETH)
。
开关有限宽度模式