We have a goal that is very beneficial to the community.
We want to make all the official images support the mipsle64 architecture.
We can provide several mipsle64 machines for building these official images.
But we need some specific guiding steps. Could you help us?
Sure, sounds like a noble goal! I've got a couple questions to get us started:
gccgo?)I am very happy to see your reply.
Currently, the debian operating system supports mips64le,
and our own Fedora-based operating system also supports mips64le.
Golang also already supports mips64le, so you don't have to worry about it.
For machines, we can cooperate in one of following two ways.
1) We can give you two mips64le based machines, but not too much.
They will be permanently part of the community for building docker image.
2) We provide the account number and password for the virtual machine.
The community uses virtual machines to build images.
These virtual machines will be dedicated to building images without being used by others.
@tianon Could you give me some feedback?
I really hope that this will make some progress.
What country will the machines or VMs reside in? Is there a specific company that would be the "donor" for them?
What system specs (RAM, CPU, HDD, internet uplink, etc) are we looking at?
Go does appear to support it, but they don't publish official binaries (so we'll have to get creative).
@tianon Thank you for your response.
1)The machine's donor is loongson, which independently
developed a cpu based on the mipsle64 architecture.
To make it easier for the community to serve,
we can mail two machines to the community.
So please let me know specific mailing address.
2)Here are some of the system information you need.
[root@localhost ~]# cat /proc/cpuinfo
system type : generic-loongson-machine
machine : loongson,generic
processor : 0
cpu model : ICT Loongson-3 V0.13 FPU V0.1
model name : ICT Loongson-3A R3 (Loongson-3A3000) @ 1450MHz
BogoMIPS : 2887.52
wait instruction : yes
microsecond timers : yes
tlb_entries : 1088
extra interrupt vector : no
hardware watchpoint : yes, count: 0, address/irw mask: []
isa : mips1 mips2 mips3 mips4 mips5 mips32r1 mips32r2 mips64r1 mips64r2
ASEs implemented : vz
shadow register sets : 1
kscratch registers : 6
package : 0
core : 0
VCED exceptions : not available
VCEI exceptions : not available
processor : 1
cpu model : ICT Loongson-3 V0.13 FPU V0.1
model name : ICT Loongson-3A R3 (Loongson-3A3000) @ 1450MHz
BogoMIPS : 2902.61
wait instruction : yes
microsecond timers : yes
tlb_entries : 1088
extra interrupt vector : no
hardware watchpoint : yes, count: 0, address/irw mask: []
isa : mips1 mips2 mips3 mips4 mips5 mips32r1 mips32r2 mips64r1 mips64r2
ASEs implemented : vz
shadow register sets : 1
kscratch registers : 6
package : 0
core : 1
VCED exceptions : not available
VCEI exceptions : not available
processor : 2
cpu model : ICT Loongson-3 V0.13 FPU V0.1
model name : ICT Loongson-3A R3 (Loongson-3A3000) @ 1450MHz
BogoMIPS : 2902.61
wait instruction : yes
microsecond timers : yes
tlb_entries : 1088
extra interrupt vector : no
hardware watchpoint : yes, count: 0, address/irw mask: []
isa : mips1 mips2 mips3 mips4 mips5 mips32r1 mips32r2 mips64r1 mips64r2
ASEs implemented : vz
shadow register sets : 1
kscratch registers : 6
package : 0
core : 2
VCED exceptions : not available
VCEI exceptions : not available
processor : 3
cpu model : ICT Loongson-3 V0.13 FPU V0.1
model name : ICT Loongson-3A R3 (Loongson-3A3000) @ 1450MHz
BogoMIPS : 2902.61
wait instruction : yes
microsecond timers : yes
tlb_entries : 1088
extra interrupt vector : no
hardware watchpoint : yes, count: 0, address/irw mask: []
isa : mips1 mips2 mips3 mips4 mips5 mips32r1 mips32r2 mips64r1 mips64r2
ASEs implemented : vz
shadow register sets : 1
kscratch registers : 6
package : 0
core : 3
VCED exceptions : not available
VCEI exceptions : not available
[root@localhost ~]# ifconfig -a
enp0s3f0: flags=4098
ether ea:56:de:4e:8e:64 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 76
enp0s3f1: flags=4098
ether 12:5e:a0:f1:6d:d7 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device interrupt 78 base 0x8000
enp2s0: flags=4163
inet 10.20.42.13 netmask 255.255.255.0 broadcast 10.20.42.255
inet6 fe80::20b:2fff:fe17:fd5 prefixlen 64 scopeid 0x20
ether 00:0b:2f:17:0f:d5 txqueuelen 1000 (Ethernet)
RX packets 989767 bytes 250181333 (238.5 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 220736 bytes 23553089 (22.4 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
lo: flags=73
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 1 (Local Loopback)
RX packets 2108 bytes 242300 (236.6 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 2108 bytes 242300 (236.6 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
virbr0: flags=4099
inet 192.168.122.1 netmask 255.255.255.0 broadcast 192.168.122.255
ether 00:00:00:00:00:00 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
virbr0-nic: flags=4098
ether 52:54:00:2d:85:72 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
[root@localhost ~]# fdisk -l
Disk /dev/sda:119.2 GiB,128035676160 字节,250069680 个扇区
单元:扇区 / 1 * 512 = 512 字节
扇区大小(逻辑/物理):512 字节 / 512 字节
I/O 大小(最小/最佳):512 字节 / 512 字节
磁盘标签类型:dos
磁盘标识符:0xf3c897fc
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 209717247 209715200 100G 83 Linux
/dev/sda2 209717248 243271679 33554432 16G 82 Linux swap / Solaris
3)For the last question you said, golang does not have a binary version
based on mips64le that was released directly.
But we have successfully compiled the golang
based on mips64le in our system using the source code of golang.
If you need it, we can tell you the specific compilation method.
[root@localhost ~]# go version
go version go1.11.5 linux/mips64le
[root@localhost ~]#
Oh, interesting! You're the first who's wanted to ship us hardware, so we're not exactly set up where we could host that easily :sweat_smile:, but we might be able to figure something out. What's the form factor on that box? Is it one of the smaller dev boards from Loongson, a desktop style system, or is it more of a server/rackmounted? (If it's a dev board, does it come in an enclosure?)
How much RAM does it have?
That hard drive would be pretty small for what we need, but I'm guessing that's something that could be upgraded? (does it use standard SATA connectors or similar?)
@tianon Thank you for your response
It is a desktop host.
The hard drive use standard SATA connectors and you can upgraded it.
Nice goal!
@tianon What should I do next to make some progress in our cause?
Hey @wanghuaiqing2010, sorry for the delay, I had a few loose ends I needed to button down. If you'd like to ship some hardware, I think the best place for now would be our corporate office here:
Tianon Gravi
8275 S. Eastern Ave. Suite 105
Las Vegas, NV 89123
@tianon Thank you for your response.
We have applied for two machines, and there are some other processes.
Before shipping, we need to sign a gift agreement.
we will fax you the agreement, after you sign the agreement, fax the agreement to us.
Thank you for your support and help.
I've sent you an email so we can coordinate the details further. :+1:
@tianon I've sent you an email.
The gift agreement is in the attachment of the email.
@tianon
We hope to do more work for the community.
We hope to maintain the official images of mips64le.
Could we connect our device to the website below?
https://doi-janky.infosiftr.net/job/multiarch/
Could you guide me on my next job?
Is there any progress? ping @tianon @wanghuaiqing2010
Yes! We've got an agreement and hopefully hardware on the way soon. 🤘
Looking forward to your good news! 💃
How many base distributions officially support it today?
Just for completeness: I think the OpenWRT community will have a use for it (#6268) and there is some work for it at Alpine Linux.
@tianon Tianon
We have mailed the loongson machines to your company on February 17.
Have you received the machines?
If you have received the machines, could we start our community work?
Thanks @wanghuaiqing2010! They got stuck in customs for a short time due to some minor issues, but the shipment is here now. We'll work on getting them set up and get going on next steps here! :+1:
@tianon That ’s very good.
If you have any questions, please communicate with us in time.
We can help you.
@wanghuaiqing2010 do you have any tips for getting a mainstream Linux distribution (like Ubuntu or Debian) running on these machines?
It seems they boot exclusively via EFI, but MIPS machines booting via EFI doesn't seem to be officially supported by any mainstream distributions (yet?) -- we've tried a few things to work around this, but so far haven't had much success.
@tianon The problem you are experiencing is a problem we know. Because our patch about the kernel is not submitted to the official community. So the mips version of debian cannot boot via EFI。You can use the “debootstrap” command to replace the system with the debian version, but keep the kernel of the loongson system.
@tianon
@wanghuaiqing2010 and I are both from Loongson. We have debian docker images on mips64el platform, and we can support you. We have uploaded the images to docker hub. Run docker pull loongnix/debian:stretch to download the image.
But before dowload the image, please ensure the network is ok by ping ftp.loongnix.org to install docker from Loongson source. Then install the docker-ce with the command yum install docker-ce.
Thank you!
With #7797, we have hello-world, and with #7804 we'll have debian. I've got a build for busybox in-progress. :+1:
(@wanghuaiqing2010 @XiaodongLoong please let me know as soon as I can boot a more "stock" or vanilla upstream Linux kernel on these systems -- right now we've got Debian booted on that Loongnix kernel, but it's very quirky and I'd love to build/use a kernel that's built with Debian in mind instead of a RedHat-based distro :heart:)
Very good, I'm seeing our efforts are bearing fruit.
@tianon We have 4.19 version upstream Linux kernel on mips64el, and I can offer you the binary.
@tianon You can download the kernel from this URL:
wget https://github.com/XiaodongLoong/share/raw/master/kernel-4.19.90%2B-dpm.tar.gz
Or you can download with git with git clone https://github.com/XiaodongLoong/share.git.
A mipsle64 label should also be added to the images on Docker Hub
@XiaodongLoong thanks! I don't want to interrupt our current working system, but I'll hang onto this for setting up our other system. Please let me know if the efforts to upstream those changes get further along. :+1:
@J0WI unfortunately, that's not something we can control (not exactly https://github.com/docker/roadmap/issues/76, but certainly related -- it's in the realm of "Hub image metadata we don't control" :disappointed:)
Given mips64 is bi-endian, is there any way to run builds for both architectures on the same system, or would I need to set up the second system to be just mips64 in order to support both little- and big-endian builds?
If we can't support both on one system, do I need to do anything special to support a big-endian userspace with the kernel? Does that have to be a different kernel?
(For context, Alpine has added support for big-endian mips64, but little-endian is still something that's under consideration.)
Any advice on why Debian decided to go little-endian only instead of supporting both like they do for some other architectures?
(https://www.linux-mips.org/wiki/Endianness#Bi-endian_Systems is the best resource I can find, and it gives me the impression the answer is :shrug:)
@tianon We only support little-endian mips64. We have communicated with alpine community. And there is a plan to support mips64el architectures. (https://lists.alpinelinux.org/~alpine/devel?search=mips64el).
That debian decided to go little-endian only instead of supporting both, I am not very clear.
We have contact golang community. There is no plan to support mips64el, They recommend that we can build mips64le releases ourselves. (https://github.com/golang/go/issues/38536) Do you think it is appropriate to build mips64le releases ourselves?
@XiaodongLoong nice, that's great to hear!
Regarding Go, I've opened https://github.com/docker-library/golang/pull/335 to resolve that long-standing TODO (especially now that we have somewhere to link where it's explicitly stated by upstream to be the appropriate solution, and two architectures for which it will be invoked). :+1:
@tianon
Thank you for your work, you are unselfishly contributing your power to the world.
We have built mysql:8.019 and elasticsearch:7.6.1 successfully on mips64le platform.
But communities that related to these programs only release x86 version.
Could we build images of these programs ourselves like we build golang images?
Unfortunately not as part of the official images program unless there's some kind of explicit or implicit approval by the relevant upstream (as we have in the Go case).
Hi friends, any news on whether we can boot a stock Debian, Ubuntu, or some other "traditional" distribution on this hardware yet? :innocent: :smile:
(Right now, I'm chain-loading a Debian userspace off the Loongnix GRUB/kernel, which works OK, but it's not great, and I'm not having much luck finding details about whether the necessary patches have made it upstream for the kernel/GRUB.)
@tianon I am asking the relevant technical department of the company.
If there is any news, I will notify you in time.
@tianon I ask the problem to the relevant technical department of the company.
They supply the following infomation. I think that you can try it.
“The community version of debian should be able to be started directly on the loongson machine, just replace the grub file of the community version with the grub file of the loongson system.”
That's exactly what I'm doing now -- I'm booting my Debian userspace on the Loongnix kernel and Loongnix Grub but I can't easily apply things like kernel or Grub updates that way, so I'd really love a way to run a stock Debian kernel and Grub so they can be updated normally with the rest of the system. 😅
Most helpful comment
@XiaodongLoong nice, that's great to hear!
Regarding Go, I've opened https://github.com/docker-library/golang/pull/335 to resolve that long-standing TODO (especially now that we have somewhere to link where it's explicitly stated by upstream to be the appropriate solution, and two architectures for which it will be invoked). :+1: