Is there a method to disable a specific replication_slot? When I try to drop it I got an error because it is Active. Thanks
No, you need to turn it off on the replica side before dropping. If you can't do that, then you have to terminate the wal sender and then drop the slot before it has a chance to start up again. Since it is a race, you should arrange to submit the drop command on the same keystroke as the terminate command.
select pg_drop_replication_slot('rep_slot');
ERROR: replication slot "rep_slot" is active for PID 162564
select pg_terminate_backend(162564); select pg_drop_replication_slot('rep_slot');