As a system admin you frequently need to run all sorts of commands via the shell. Sometimes when you access 3rd-party servers there may already be a lot of command aliases and your copy command won’t work

How To View Command Alias

The fastest way to figure out why your copy -rf command is not working as expected is to actually check if there is an existing alias. To do that all we have to do is to run this:

alias cp

You should get something like this:

Copy Command Alias.png

As you can see the cp command is aliased to cp -i, so if you run

cp -rf

it will actually run

cp -i

Here’s How To Access Command Directly Ignoring Any Alias

1. Simply add a backslash \ before the actual command and it will directly execute the command as if you were accessing it via the full path e.g. /bin/copy


2. Alternatively, you can try to cd directly into the bin directory and run the command from there