Low Orbit Flux Logo 2 F

Linux Command - mv

mv - move (rename) files,



mv file1 file2   # rename file
mv file1 dir1    # move file into dir ( if dest is a dir )

mv dir1 dir2     # move dir into another dir 
                 # ( or rename if dest doesn't exist )

mv /var/log/test  /data/backup/test
mv /var/log/test  /data/backup

-b backup
-f don’t prompt to overwrite
-i interactive, prompt before overwrite
-n no clobber, don’t overwrite
-u update, only move when source is newer than dest
-v verbose
-z set SELinux security context to default on dest