How to install or upgrade MAAS

It seems to have worked for me by just eliminating the entire offending argument. Like this…

sudo maas init region+rack --database-uri “postgres://$MAAS_DBUSER:$MAAS_DBPASS@$HOSTNAME/$MAAS_DBNAME”

Whether this leaves MAAS unlinked to a DB, I’m not sure but I was able to login to the web gui. The command without the argument will automatically run through the admincreate script, unless switched off. I also noticed when trying to install 3.4 from deb, there is no command in the man pages for the offending argument. When I attempted to use the db name “maasdb” it errored out and said it already existed on a fresh attempt. Does 3.4 autocreate the postgresql during apt install of MAAS? I’m currently testing how it works if I manually upgrade postgresql to v14 and pre-create the DB. I’m hoping the MAAS install sees it and uses it by default with the db name “maasdb.”

Two things:

  • after editing pg_hba.conf I had to sudo service postgresql restart otherwise maas init failed
  • I’m stuck on maas $PROFILE subnet read $SUBNET_CIDR | grep fabric_id since there is no explanation of how to set SUBNET_CIDR

thanks for spotting the issue @rgarcia2009 !

In the meantime, you can list the existing subnets with maas $PROFILE subnets read and extract the CIDR of the subnet you want

I think for

  1. Import your selected image(s):
    maas admin boot-resources import

it should be (for consistency)

  1. Import your selected image(s):
    maas $PROFILE boot-resources import

*Would have made the edit, but discourse wouldn’t let me