Report this

What is the reason for this report?

Please verify the note as given in the cp command section, I think author is talking about cp command rather than mv command.

Posted on November 29, 2025

Connected Tutorial(This question is a follow-up to this tutorial):

Linux Navigation and File Management

Note: As with the mv command, it is possible to overwrite a file if you are not careful about the filename you are using as the target of the operation. For instance, if file4 already existed in the above example, its content would be completely replaced by the content of file3.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Heya, @378226414b344d3d9ef057316f83e8

The note refers to the cp command indeed. When using cp, if the target file already exists, it will be overwritten without warning (unless you use cp -i).

Regards

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.