ラベル

Server (108) work (77) Idea (68) Car (31) PC (29) DAW (28) other (19) MakingWEBsite (18) 趣味 (18) health (13) CentOS (11) drupal (11) 山 (9) android (4) スマホ (4) communication (3) drupal7 (3) hint (3) meno (3) モバイル (3) 歯医者 (3) 第二種電気工事士 (3) 英語 (3) PC Server (2) drupal8 (2) ms access (2) uwp C# (2) めし (2) 整備 (2) 音楽 (2) MIDI (1) diy (1) 会計 (1) 動画再生 (1) 生活 (1) 郵便 (1) 食べ物 (1)

2013年9月15日日曜日

Backup by cp command at Centos6.4

[root@hoge ~]# \cp -apruv /home/name /hd1tb/backupCentos/home/

In case of CentOS6.4.
"cp"="cp -i"
"cp" of CentOS is running in alias.

You can know if you try command "alias" on your computer.
[root@hoge ~]# alias
alias cp='cp -i'
alias l.='ls -d .* --color=auto'
alias ll='ls -l --color=auto'
alias ls='ls --color=auto'
alias mv='mv -i'
alias rm='rm -i'
alias which='alias | /usr/bin/which --tty-only --read-alias --show-dot --show-tilde'

Or try this command
# which cp
alias cp='cp -i'
        /bin/cp

Option "cp -f" doesn't work for this alias..
When you want to use option f, simply escape "cp" or call with full path:
$ \cp -f
("\" is to escape alias.)
or
$ /bin/cp -f

0 件のコメント:

コメントを投稿