UPGRADING/v0_07.md
v0.6.0 to v0.7.0Version 0.7.0 of Stalwart introduces significant improvements and features that enhance performance and functionality. However, it also comes with multiple breaking changes in the configuration files and a revamped database layout optimized for accessing large mailboxes. Additionally, Stalwart now supports compression for binaries stored in the blob store, further increasing efficiency.
Due to these extensive changes, the recommended approach for upgrading is to perform a clean reinstallation of Stalwart and manually migrate your accounts to the new version.
v0.7.0 mail-server and CLI binaries for your platform from the releases page.sudo ./stalwart-mail --init /path/to/new-install. This command will print the administrator password required to access the web-admin.bin directory using mkdir /path/to/new-install/bin.bin directory using the command mv stalwart-mail stalwart-cli /path/to/new-install/bin./path/to/new-install/etc/config.toml in a text editor and comment out all listeners except the HTTP listener for port 8080.sudo /path/to/new-install/bin/stalwart-mail --config /path/to/new-install/etc/config.toml.http://yourserver.org:8080 and login using the auto-generated administrator password.stalwart-mail user and stalwart-mail group from Settings > Server > System. This is not necessary if you are using Docker.Ctrl+C in the terminal.v0.6.0 installation, open in a text editor the smtp/listener.toml, imap/listener.toml files and comment out all listeners except the JMAP/HTTP listener (we are going to need it to export the user accounts) and then restart the service.~/exports directory, here we will store the exported accounts../stalwart-cli -u https://your-old-server.org -c <ADMIN_PASSWORD> export account <ACCOUNT_NAME> ~/exports.v0.6.0 installation using the command sudo systemctl stop stalwart-mail.v0.6.0 installation to a backup directory, for example mv /opt/stalwart-mail /opt/stalwart-mail-backup.v0.7.0 installation to the old installation directory, for example mv /path/to/new-install /opt/stalwart-mail.sudo chown -R stalwart-mail:stalwart-mail /opt/stalwart-mail.sudo systemctl start stalwart-mail../stalwart-cli -u http://yourserver.org:8080 -c <ADMIN_PASSWORD> import account <ACCOUNT> ~/exports/<ACCOUNT>.sudo systemctl restart stalwart-mail.We apologize for the complexity of the upgrade process associated with this version of Stalwart. We understand the challenges and inconveniences that the requirement for a clean reinstallation and manual account migration poses. Moving forward, an automated migration tool will be included in any future releases that necessitate changes to the database layout, aiming to streamline the upgrade process for you. Furthermore, as we approach the milestone of version 1.0.0, we anticipate that such foundational changes will become increasingly infrequent, leading to more straightforward updates. We appreciate your patience and commitment to Stalwart during this upgrade.