I am looking for a script to remove smb shares that were setup to mount during the login for the users local account.
Our company split apart and we used to setup and have home directories automatically mount using samba during the initial login to the Mac. System Preferences > Users & Groups > Login Options > + (add the mapping)
For example the mapped drive for the old company is smb://fs01.oldcompany.com/doej using the FQDN.
We are now a different company with a different domain. The new mapped drive would be smb://fs02.newcompany.com/doej
Is there a script I can push out to remove any mappings just for the "old company.com" domain mappings? We still have some of these on some of our users that work remotely and it's causing performance issues.