As Brian pointed out in the comment, the easiest solution is to make ptr2 be a reference to ptr1. That way, once you change ptr1 (or ptr2 for that matter), they will be alright.
shared_ptr<myClass> ptr1;
shared_ptr<myClass> &ptr2 = ptr1;
Then, you will also be able delete the needless copy like this:
ptr2 = ptr1;
You could also write this as the operator=
returns a reference to the shared pointer, but I am not sure this is the smart solution you need:
ptr1 = ptr2 = ptr3;
Yet another mechanism would be to create your own function managing all this, and call that instead of the assignment operator, so something like a "smart setter".