News for hackers. Stuff that matters.
Re:Amazon has more than half of all Arm server CPUs in the w... by TheDong on Wednesday August 09, 2023 @05:17AM (#37060324)
> and our shiny new M1/M2 Macs run the same binaries

Does that mean you're all running asahi linux, or are you somehow running linux elf binaries on macOS?

Or are you using VMs, just like the x86 + docker desktop folks are doing to run the same binaries on their laptops and servers?

Re:Amazon has more than half of all Arm server CPUs in the w... by minimaul on Wednesday August 09, 2023 @05:19AM (#37060331)
VMs through things like Docker for Mac, in our case.

And yes - it’s exactly the same as you can do if you use x86 servers and dev machines.

It’s just the fact that we can also do this for ARM on hardware that doesn’t suck that makes using ARM in production more practical for us.

Re:Amazon has more than half of all Arm server CPUs in the w... by bravura on Wednesday August 09, 2023 @05:28AM (#37060379)
Sorry I missed the details:

"Does that mean you're all running asahi linux or are you somehow running linux elf binaries on macOS?" So you're running whatever linux districtuion you want or some particular flavor through Docker on Mac? And you don't have ELF binaries because you're using precompiled packages for ARM and don't need weirdo prebuilt ELFs, or you have a workaround?

Re:Amazon has more than half of all Arm server CPUs in the w... by Fnoord on Wednesday August 09, 2023 @05:36AM (#37060425)
Docker for Mac runs a full-blown Linux kernel last time I checked (Docker for Windows can use Windows containers). So whatever OS they run on the cloud (with OCI) these containers are going to work on the (very fast) M1/M2. The OS the Docker images are using is irrelevant. The OS running in the cloud is irrelevant. Only relevant factor is Docker for Mac as it means Linux kernel overhead. But this is offset by M1/M2. Clever setup!
Re:Amazon has more than half of all Arm server CPUs in the w... by minimaul on Wednesday August 09, 2023 @05:47AM (#37060486)
Exactly this.

Plus as the Apple virtualisation framework now implements pretty standard virtual hardware - it uses virtio - we are finding things work vastly better in Docker for Mac - particularly as we can use virtiofs etc to pass files through from the host.

Re:Amazon has more than half of all Arm server CPUs in the w... by happymellon on Wednesday August 09, 2023 @06:37AM (#37060771)
> Docker for Windows can use Windows containers

I thought Windows containers never went anywhere. Interesting to hear that they are still a thing.

Re:Amazon has more than half of all Arm server CPUs in the w... by thedougd on Wednesday August 09, 2023 @10:12AM (#37062938)
Yes, but pretty much in the same sad state as they were a few years ago. We're running a few in production and next time we touch it we're replacing them with Windows Server Core EC2 instances built from baked images.

Note on Linux containers:

Running Linux containers on Windows requires the use of LinuxKit or WSL. Docker Desktop for Windows requires you switch modes between Linux container mode and Windows container mode as you can't run both simultaneously. A workaround is to install an additional Docker daemon inside the WSL environment. Most people are going to install Docker Desktop and use WSL in Linux mode. It's fine. Hopefully my facts are up-to-date.

Re:Amazon has more than half of all Arm server CPUs in the w... by pjmlp on Wednesday August 09, 2023 @04:20PM (#37067837)
Windows containers have improved quite a lot in Windows 11.
Re:Amazon has more than half of all Arm server CPUs in the w... by mschuster91 on Wednesday August 09, 2023 @08:14AM (#37061481)
The interesting thing is, how is Docker for Mac able to run x86 containers at speed when Apple's Developer Documentation for Rosetta says it can't be used for virtual machines?

Or have they just embedded the QEMU on-demand translator with binfmt_misc in the ARM virtual machine and the M1/M2 is just powerful enough to make users not notice what's going on?

[1] https://developer.apple.com/documentation/apple-silicon/abou...

Re:Amazon has more than half of all Arm server CPUs in the w... by minimaul on Wednesday August 09, 2023 @10:33AM (#37063300)
Rosetta can be used to emulate individual processes inside a linux-based virtual machine - Apple provide tooling for this: https://developer.apple.com/documentation/virtualization/run...
Re:Amazon has more than half of all Arm server CPUs in the w... by minimaul on Wednesday August 09, 2023 @05:34AM (#37060415)
We deploy containers to production, and use variants of the same containers for local development - mostly Debian.

Those containers contain a mix of custom built software and packages from the distro.

Re:Amazon has more than half of all Arm server CPUs in the w... by acdha on Wednesday August 09, 2023 @07:56AM (#37061319)
Just as an aside, the same process works painlessly with podman, too, if your employer is allergic to Docker. Maybe once or twice a year I get reminded that I’m not using x86 - and it sure is nice to work all day and finish with 60% battery.
Re:Amazon has more than half of all Arm server CPUs in the w... by robbintt on Wednesday August 09, 2023 @11:35AM (#37064289)
Is this battery savings from using podman instead of docker for mac or using docker for max with M1/M2?
Re:Amazon has more than half of all Arm server CPUs in the w... by acdha on Wednesday August 09, 2023 @01:50PM (#37066241)
Running on ARM itself is a big power savings. Docker Desktop also had issues with CPU load which they might have improved since I stopped using it a couple of years ago. There were a bunch of GitHub issues starting around 2018 which were closed, moved, reopened, and it looks like it’s still a concern whereas with Podman I’ve been able to use it without thinking about it.
Re:Amazon has more than half of all Arm server CPUs in the w... by aragilar on Wednesday August 09, 2023 @06:28AM (#37060710)
asahi linux is only needed if you are running on the bare metal. A VM (which abstracts the hardware) means you can run existing ARM64 binaries.
Re:Amazon has more than half of all Arm server CPUs in the w... by dikei on Wednesday August 09, 2023 @06:50AM (#37060869)
You still need VM to run Linux ELF on macOS, but you don't need to use full-blown emulation like QEMU if the Linux ELF is for AARCH64, unlike when you try to run x86 ELF. It's much faster this way.
Re:Amazon has more than half of all Arm server CPUs in the w... by mcqueenjordan on Wednesday August 09, 2023 @07:15AM (#37061018)
I assume he just meant running binaries compiled for the same ISA / processor architecture.