"Processing" during image upload

I re-tried my install instructions for both Ubuntu 18.04.4 and 19.10 64bit (instead of Raspbian 32-bit), for Mattermost Team server.

That’s the fix!! Don’t use Raspbian 32-bit. Use Ubuntu 18.04.4 64bit, or 19.10 64-bit.

There’s something about 32bit Raspbian which is slow, for Mattermost. But 64bit Ubuntu 18.04.4 (or 19.10) rips way, way faster on an image upload. The server is totally usable in a daily driver sort of way!!

How much faster?

Here’s a test I did. I ran Mattermost Team Server in a Debian 10.3 64-bit VM (ARM64). I gave the VM only one of my CPU cores, non-hyperthreaded (SMT is disabled). This is an i5 Intel Core, 8th gen. A laptop, Asus UX330U. Then I uploaded a 4.0 MB image. The thumbnail-processing with maxed-out CPU took just under 4 seconds (just timed on a wristwatch). Then I uploaded that same 4.0MB image into the RPi4. It also took just under 4 seconds (utilizing all 4 cores). Like it was identical performance! This is a night and day difference, going from 32-bit to 64-bit. This is going from minutes and minutes, down to under 4 seconds. That 4.0MB image would have crippled the RPi4 in 32bit Raspbian!

Problem solved! No code changes needed!

@b3lt3r, @justinegeffen, @hmhealey

Hi @esbeeb

As mentioned I replicated your result with ubuntu server 18.04 and 64 bit mm code running on a Pi3 with very acceptable performance.

I then got to wondering. Raspbian now has a 64 bit kernel but apparently all userland code is stuck at 32 bit, however - plenty of time atm :slight_smile:

So - I have my pi3 running raspbian buster with a mm instance. Did a update/upgrade and then added “arm_64bit=1” to config.txt in /boot

After reboot it’s using the arm8 kernel.

Fire up existing 32bit mm instance and upload my test image (1.46mb) and that still takes well over 30 seconds to process.

I then simply copied the 64bit bin/mattermost executable from my ubuntu 18.04 instance onto the raspiban pi3 and re-ran the test - that image loaded in under 5 seconds which is more or less identical to ubuntu full blown 64 bit…

So - this is all fixed for stock Rasbian with one line of config and the 64 bit arm image…

Very happy bunny now :slight_smile:

2 Likes

Sweet find. That opens the door to Raspbian… you just have to shoehorn 64-bitness in there.

Complications can arise, however, from such a strange combination of 64bit and 32bit. For example, I just tried what you suggested, and now installing/running Wireguard became a nightmare (as in, Wireguard is broken). I can’t even compile Wireguard from source, without a build-system battle on my hands.

At least with Ubuntu 64bit, Wireguard installed and ran like a breeze.

OK - as a rule I try to avoid compiling so didn’t see that. As noted previously there is also the issue with total plugin incompatibility as I haven’t been able to find ARM versions, so if any are required/desired it’s x64 only.

Given this and your comment on general “mixing” issues I’m going to abandon my plan to migrate my main Pi4 server to 64 bit at least until a proper 64 bit Raspian release for all supported packages.

A pain as I’ll have to run MM on either the Ubuntu Pi3 or leave it on the NUC if I want plugins. Until I found “/remind” there weren’t any I wanted/needed - now I want one…

I’ll call this a moral (pyrrhic?) victory for now :slight_smile: