# First you need to change the root password so you can ssh in as root vagrant ssh sudo su passwd root root exit # On your host machine: # --------------------- # Make note of the uid and gid (referenced as: host_uid, host_gid) getent passwd | grep "" # outputs: :x:::... # ssh into vagrant box as adming ssh root@dev-stuby # On your guest machine: # ---------------------- # Make note of the vagrant uid/gid (referenced as: vagrant_uid, vagrant_gid) getent passwd | grep "vagrant" # Make note of the user/group on the guest machine that machine that matches your host machine # (referenced as: guest_user, guest_group) getent passwd "" | cut -d: -f1 getent group "" | cut -d: -f4 # Move current guest occupying host uid/gid usermod -u 60000 groupmod -g 60000 find / -user -exec chown -h 60000 {} \; find / -group -exec chown -h 60000 {} \; usermod -g 60000 # Move vagrant to match host usermod -u 60000 groupmod -g 60000 find / -user -exec chown -h {} \; find / -group -exec chown -h {} \; usermod -g 60000