Updating Mattermost from 16.1 - Stuck and mattermost wont restart

In the upgrade process when i run the command:
ls /opt/mattermost I get: client config data logs plugins

proceeding to the next step
sudo find mattermost/ mattermost/client/ -mindepth 1 -maxdepth 1 ! ( -type d ( -path mattermost/client -o -path mattermost/client/plugins -o -path mattermost/config -o -path mattermost/logs -o -path mattermost/plugins -o -path mattermost/data -o -path mattermost/yourFolderHere ) -prune ) | sort | sudo xargs rm -r

I guess i’m not exactly sure what to put in the: mattermost/yourFolderHere portion:
My existing directory is located at: etc/mattermost /opt/mattermost/bin/mattermost

ive tried different combinations here but am unsure exactly what i should be putting here because nothing i try seems to work.

Hi anatwick,

you do not need to put anything in the yourFolderHere portion; this was just meant as an example if you have any custom directories below the /opt/mattermost parent directory, because if you do, the documentation will remove all of them by default. If you do not have any custom directories (which you most likely don’t, otherwise you would know that), you can skip this command. It was meant as an alternative to command above in the documentation.

i tried that as well but get:
find: ‘mattermost/’: No such file or directory
find: ‘mattermost/client/’: No such file or directory
rm: missing operand

This command only works when you’re in the directory /opt. It seems you’ve moved out of this directory, so please try cd /opt and continue with your commands.

I did just that and was still left with:
rm: missing operand

Please post a screenshot or the full commands you entered and the full output you were seeing.

This command is not supposed to be run multiple times and you’ve already run it successfully, so you can now continue to the next step (that’s why you get the error message from rm telling you that there is nothing more to delete, basically…).
So go ahead with Step 8 (Copy the new files to your install directory) in the instructions now.