Fixing parent scopes
Fixing final replication terminal ad
Fixing socket to use, and command to use