1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

CentOS基本コマンド

Last updated at Posted at 2019-05-15

初投稿です。
自分用にメモ。

Cent OS 6.8

ファイルの作成

qiita.rb
touch ファイル名

ファイルの編集

qiita.rb
vi ファイル名

ファイルの中身を表示

qiita.rb
cat ファイル名

フォルダーの作成

qiita.rb
mkdir フォルダー名

ファイルエントリ情報の表示

qiita.rb
ls

オプション ls ファイルタイプ、パーミッション(権限)なども表示

qiita.rb
ls -l

ファイルを ディレクトリ へコピー

qiita.rb
cp ファイル名 ディレクトリ名/

ファイルの削除

qiita.rb
rm ファイル名

ディレクトリの削除

qiita.rb
rm -r ディレクトリ名

ディレクトリから tar.gz形式 圧縮ファイル作成

qiita.rb
tar cvzf 生成ファイル名.tar.gz 圧縮元ディレクトリ名

tar.gz形式 圧縮ファイル解凍

qiita.rb
tar xzvf 圧縮ファイル名

ディレクトリの同期
※コピー元ディレクトリ名の後ろに/をつけると、ディレクトリ自体はコピーせず、その中身だけををコピー先に入れることができる

qiita.rb
rsync -r コピー元ディレクトリ名/ コピー先ディレクトリ名
1
0
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?