Given that -f just does a silent replacement, you can do an atomic
replacement with mv -T (-T makes it work even if /loc.../link is a
directory): ln -s /location/to/link linkname ... ln -s
/location/to/link2 newlinkmv -T newlink linknamelinkname is a...