0
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 1 year has passed since last update.

yum localinstall とは?やってみた。

Posted at

勉強前イメージ

yum installとは違う?

調査

yum localinstall とは

そもそも yum とはrpmを管理するマネージャーのことを指しています。
詳細は こちら に記載しておりますが
大きな特徴としては、依存関係を自動的に解決してくれるというものがあります。

yum localinstallを使ってみる

今回はtreeコマンドを入れようとおもいます。
今のところはtree使えません。

rpmを取ってきます。

wget https://ftp.centos.org/7.9.2009/os/x86_64/Packages/tree-1.6.0-10.el7.x86_64.rpm

できました。

[root@localhost ~]# ll | grep tree
-rw-r--r-- 1 root root 47508  7月  4  2014 tree-1.6.0-10.el7.x86_64.rpm

それをlocalinstallします。

yum localinstall tree-1.6.0-10.el7.x86_64.rpm

普通にyum installするのと似たような感じですね。

[root@localhost ~]# yum localinstall tree-1.6.0-10.el7.x86_64.rpm
読み込んだプラグイン:fastestmirror, product-id, search-disabled-repos, subscription-manager

This system is not registered with an entitlement server. You can use subscription-manager to register.

tree-1.6.0-10.el7.x86_64.rpm を調べています: tree-1.6.0-10.el7.x86_64
tree-1.6.0-10.el7.x86_64.rpm をインストール済みとして設定しています
依存性の解決をしています
--> トランザクションの確認を実行しています。
---> パッケージ tree.x86_64 0:1.6.0-10.el7 を インストール
--> 依存性解決を終了しました。

依存性を解決しました

=======================================================================================================================================================
 Package                     アーキテクチャー              バージョン                           リポジトリー                                      容量
=======================================================================================================================================================
インストール中:
 tree                        x86_64                        1.6.0-10.el7                         /tree-1.6.0-10.el7.x86_64                         87 k

トランザクションの要約
=======================================================================================================================================================
インストール  1 パッケージ

合計容量: 87 k
インストール容量: 87 k
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  インストール中          : tree-1.6.0-10.el7.x86_64                                                                                               1/1 
  検証中                  : tree-1.6.0-10.el7.x86_64                                                                                               1/1 

インストール:
  tree.x86_64 0:1.6.0-10.el7                                                                                                                           

完了しました!

これでtreeコマンド使えるようになりました。

[root@localhost ~]# tree
.
├── test.txt
├── tree-1.6.0-10.el7.x86_64.rpm
└── xx.txt

勉強後イメージ

今回はtreeコマンドで大した依存性もなかったと思うけど
もっとややこしいやつとかならスゴイ効果的なのかな

参考

0
0
0

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
0
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?