jqコマンドをインストールする方法をご紹介します。
非常に簡単。yumコマンドで「jq」を指定するだけです。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 |
[root ~]# Loaded plugins: fastestmirror, langpacks, product-id, search-disabled-repos, : subscription-manager This system is not registered with an entitlement server. You can use subscription-manager to register. Determining fastest mirrors epel/x86_64/metalink | 9.3 kB 00:00 epel-debuginfo/x86_64/metalink | 9.0 kB 00:00 epel-source/x86_64/metalink | 9.0 kB 00:00 * base: ftp.iij.ad.jp * epel: mirrors.nipa.cloud * epel-debuginfo: ftp.riken.jp * epel-source: ftp.riken.jp * extras: ftp.iij.ad.jp * remi-safe: ftp.riken.jp * updates: ftp.iij.ad.jp base | 3.6 kB 00:00 docker-ce-stable | 3.5 kB 00:00 epel | 4.7 kB 00:00 epel-debuginfo | 3.0 kB 00:00 epel-source | 3.5 kB 00:00 extras | 2.9 kB 00:00 mariadb | 3.4 kB 00:00 nginx | 2.9 kB 00:00 remi-safe | 3.0 kB 00:00 updates | 2.9 kB 00:00 (1/9): epel/x86_64/updateinfo | 1.0 MB 00:00 (2/9): epel-source/x86_64/updateinfo | 1.0 MB 00:00 (3/9): docker-ce-stable/7/x86_64/primary_db | 69 kB 00:00 (4/9): epel-debuginfo/x86_64/primary_db | 896 kB 00:00 (5/9): epel-source/x86_64/primary_db | 2.5 MB 00:00 (6/9): remi-safe/primary_db | 2.1 MB 00:00 (7/9): epel/x86_64/primary_db | 7.0 MB 00:00 (8/9): updates/7/x86_64/primary_db | 13 MB 00:00 (9/9): nginx/x86_64/primary_db | 70 kB 00:01 Resolving Dependencies --> Running transaction check ---> Package jq.x86_64 0:1.6-2.el7 will be installed --> Processing Dependency: libonig.so.5()(64bit) for package: jq-1.6-2.el7.x86_64 --> Running transaction check ---> Package oniguruma.x86_64 0:6.8.2-1.el7 will be installed --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: jq x86_64 1.6-2.el7 epel 167 k Installing for dependencies: oniguruma x86_64 6.8.2-1.el7 epel 181 k Transaction Summary ================================================================================ Install 1 Package (+1 Dependent package) Total download size: 348 k Installed size: 1.0 M Is this ok [y/d/N]: y Downloading packages: (1/2): oniguruma-6.8.2-1.el7.x86_64.rpm | 181 kB 00:00 jq-1.6-2.el7.x86_64.rpm FAILED http://mirrors.nipa.cloud/epel/7/x86_64/Packages/j/jq-1.6-2.el7.x86_64.rpm: [Errno 14] HTTP Error 404 - Not Found Trying other mirror. To address this issue please refer to the below wiki article https://wiki.centos.org/yum-errors If above article doesn't help to resolve this issue please use https://bugs.centos.org/. (2/2): jq-1.6-2.el7.x86_64.rpm | 167 kB 00:00 -------------------------------------------------------------------------------- Total 1.1 MB/s | 348 kB 00:00 Running transaction check Running transaction test Transaction test succeeded Running transaction Installing : oniguruma-6.8.2-1.el7.x86_64 1/2 Installing : jq-1.6-2.el7.x86_64 2/2 Verifying : oniguruma-6.8.2-1.el7.x86_64 1/2 Verifying : jq-1.6-2.el7.x86_64 2/2 Installed: jq.x86_64 0:1.6-2.el7 Dependency Installed: oniguruma.x86_64 0:6.8.2-1.el7 Complete! [root ~]# [root ~]# |
以上で完了です。