1. mongodb version installed before is 2.6
2 Error reported when reinstalling 3.6
Speculation: mongodb2.6 did not completely uninstall before reporting the cause of the error when possible. The specific uninstallation method should be informed by the Great God. It is better to have relevant commands.
Do you want the old data? If not, please delete and reinstall the /var/lib/mongodb directory. We need dump+restore if we want more.