Does this even work on a Raspberry Zero !?

Brian, thanks for all the effort put into this.
I’d be reasonably confident I could build on a piz-1w.
Will it still break if apt upgrade is done ?

If I took the lazy mans way out used a July21 emonsd, will it break if upgraded, or have all your now-merged changes prevented that ?

Nothing merged yet.

The Jul21 is not a Bullseye based release, which is half the reason for the Nov22 release. Jul21 is an old Raspbian base system that is really out of date now. Over 600 packages need updated and that isn’t good.

Thanks again Brian, that helps me.

As I only need emonhub for the MBUS hat, I’ll start with RaspPiOs 32bit Lite, and manually install only emonhub using emonscripts (making relevant mods to ensure it doesn’t pull php8.1).

I’ll see how that goes

Alan

Good news.
Following the instructions above, on top of a base RaspPiOs 32bit Lite, worked like a charm.
I have a working emonhub ( I chose not to install the rest of emon* as I don’t need that).

This is a nice little solution for the M-BUS hat, and a nice bonus is sticking a USB Jeenode in one of the USB ports allows it to be a great RF relay for some dead spots in my house.

Thanks Brian (and everyone) for all the work on this.

Alan

16 posts were split to a new topic: Odd error in single senor config in emonhub

2 posts were merged into an existing topic: Odd error in single sensor config in emonhub

Thanks @borpin for looking into this! I have merged your pull request and created a stable release of the EmonScripts repository (v1.6.1). The Pi Zero 2W’s have arrived here, will hopefully get a chance to test this week :slight_smile:

Thanks. I’ll run the scripts and find out what I have missed :slight_smile:

This probably needs merging as well for a robust system.

1 Like

Thanks, merged!

1 Like

I have just pushed new docs re making the data partition.

Just ran the stable install, and it installs fine on an ARMv6 platform. Not tested it on an ARMv7, but hopefully that will be fine.

[edit]

  1. Don’t install the Wi-Fi module - configure Wi-Fi when flashing image.
  2. Do reboot at the end.

@borpin

Brian, when I run the instructions, something odd happens. When I run df -h, it reports the rootfs partition as being only as big as it was before making the new partition etc. But lsblk shows it being the size I was expecting. I did change 20 to 12 in the instruction to make the 3rd partition but that’s the only change. This is on a 32G microSD.

See below.

Then when I run the script, it complains that there isn’t enough room in /var/cache/apt/archives/, so presumably based n what df -h is reporting?

Here’s the console output:

Filesystem      Size  Used Avail Use% Mounted on
/dev/root       1.5G  1.2G  153M  89% /
devtmpfs         87M     0   87M   0% /dev
tmpfs           215M     0  215M   0% /dev/shm
tmpfs            86M  988K   85M   2% /run
tmpfs           5.0M  4.0K  5.0M   1% /run/lock
tmpfs            30M     0   30M   0% /tmp
tmpfs           1.0M     0  1.0M   0% /var/lib/php/sessions
tmpfs           1.0M     0  1.0M   0% /var/tmp
/dev/mmcblk0p1  255M   50M  206M  20% /boot
/dev/mmcblk0p3   18G   14K   17G   1% /var/opt/emoncms
tmpfs            43M     0   43M   0% /run/user/1000
pi@raspberrypi:~ $ lsblk
NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
mmcblk0     179:0    0 29.7G  0 disk
├─mmcblk0p1 179:1    0  256M  0 part /boot
├─mmcblk0p2 179:2    0 11.7G  0 part /
└─mmcblk0p3 179:3    0 17.7G  0 part /var/opt/emoncms
pi@raspberrypi:~ $ blkid
pi@raspberrypi:~ $ sudo blkid
/dev/mmcblk0p1: LABEL_FATBOOT="boot" LABEL="boot" UUID="AE82-4BC1" BLOCK_SIZE="512" TYPE="vfat" PARTUUID="c45f02f6-01"
/dev/mmcblk0p2: LABEL="rootfs" UUID="6d2ff93e-eacd-415c-96d5-4611ad21e05f" BLOCK_SIZE="4096" TYPE="ext4" PARTUUID="c45f02f6-02"
/dev/mmcblk0p3: UUID="a6442646-7702-45b0-906c-88d91bef8778" BLOCK_SIZE="1024" TYPE="ext2" PARTUUID="c45f02f6-03"

And here’s the output from the install

After this operation, 72.9 MB of additional disk space will be used.
E: You don't have enough free space in /var/cache/apt/archives/.

Have you rebooted?

Did you definitely run sudo resize2fs /dev/mmcblk0p2?

pi@emonpi:~ $ df -h
Filesystem      Size  Used Avail Use% Mounted on
/dev/root        14G  2.0G   11G  16% /
devtmpfs         87M     0   87M   0% /dev
tmpfs           215M     0  215M   0% /dev/shm
tmpfs            86M  9.6M   77M  12% /run
tmpfs           5.0M  4.0K  5.0M   1% /run/lock
tmpfs            30M     0   30M   0% /tmp
tmpfs           1.0M     0  1.0M   0% /var/lib/php/sessions
tmpfs           1.0M     0  1.0M   0% /var/tmp
/dev/mmcblk0p3  479M   19K  454M   1% /var/opt/emoncms
/dev/mmcblk0p1  255M   50M  206M  20% /boot
log2ram          50M  2.0M   49M   4% /var/log
tmpfs            43M     0   43M   0% /run/user/1000

Damn!! No!! Grrrrrr… Apologies for troubling you, I must have done this 20 times over the last few days - obviously getting instruction blind…

Apologies again.

Simon

Edit PS - probably need a script for this as well.

No bother - we have all been there! Partly it’s understanding what each bit does.

Yes, possibly. Not tried scripting it yet :frowning:.

Unfortunately the microSD now looks as though it is bricked :frowning:

Re-installing raspbian fails the verify and when I put the card back in the windows PC, I can’t do anything to the partitions. 2nd one this year while I’ve been messing around.

So maybe we do need a script to make sure that the instructions are followed - you can rely on idiots like me to idiot proof instructions!!

Simon

Try and clear the disk of all partitions before writing in Windows?

Never had one go bad on me like that.

Use this:

instead of the Windows native formatting tool.

Windows doesn’t always format flash media correctly. i.e. the partition start location may
be such that writes to flash memory end up getting done twice, which shortens the media life considerably.

The SD card formatter creates partitions that start in the correct location, thus avoiding that issue.

1 Like

Thanks Bill but I’ve tried that and several 3rd party tools - non of them work.

The official tool you point to says it does a quick format - but it doesn’t. The full format bombs out saying formatting failed after a few seconds. Basically whatever you try, you can’t get rid of the partitions, I’ve tried on Windows and on Raspbian.

Interestingly if you look at the SanDisk warranty page the High Endurance cards have about the lowest warranty period - 2 years - some Ultra cards are warranted for a lot longer, 5 or 10 years and the Extreme have a lifetime warranty → Warranty Table

I’ve applied for a replacement under the scheme - we’ll see what happens.

Simon

1 Like