zoukankan      html  css  js  c++  java
  • Centos6.6安装sysstat报错/etc/cron.d

    为了使用sar和iostat监控工具,需要安装sysstat包,但遇到报错

    1.用yum安装

    [root@leader Packages]# yum install -y sysstat*
    Loaded plugins: fastestmirror, refresh-packagekit, security
    Setting up Install Process
    Examining sysstat-9.0.4-27.el6.x86_64.rpm: sysstat-9.0.4-27.el6.x86_64
    Marking sysstat-9.0.4-27.el6.x86_64.rpm to be installed
    Loading mirror speeds from cached hostfile
    Resolving Dependencies
    --> Running transaction check
    ---> Package sysstat.x86_64 0:9.0.4-27.el6 will be installed
    --> Processing Dependency: /etc/cron.d for package: sysstat-9.0.4-27.el6.x86_64
    --> Processing Dependency: /etc/cron.d for package: sysstat-9.0.4-27.el6.x86_64
    --> Finished Dependency Resolution
    Error: Package: sysstat-9.0.4-27.el6.x86_64 (/sysstat-9.0.4-27.el6.x86_64)
    Requires: /etc/cron.d
    You could try using --skip-broken to work around the problem
    You could try running: rpm -Va --nofiles --nodigest

    2.用rpm安装

    [root@leader Packages]# rpm -ivh sysstat*
    warning: sysstat-9.0.4-27.el6.x86_64.rpm: Header V3 RSA/SHA1 Signature, key ID c105b9de: NOKEY
    error: Failed dependencies:
    /etc/cron.d is needed by sysstat-9.0.4-27.el6.x86_64

    原因:

    这是由于yum初始化安装时,安装了旧版本的GPG keys造成的

    解决方法:

    (引入已安装的public key)

    [root@leader Packages]# rpm --import /etc/pki/rpm-gpg/RPM*

    再次安装rpm包时,后面加上--force --nodeps如

    [root@leader Packages]# rpm -ivh sysstat* --force --nodeps
    Preparing... ########################################### [100%]
    1:sysstat ########################################### [100%]

  • 相关阅读:
    Good Subarrays(思维)
    Just h-index(主席树裸题)
    强联通入门
    Fragrant numbers(dfs爆搜+区间dp+stoi)
    Mr. Panda and Kakin (RSA 解密+解同余方程+O(1)快速乘)
    Balance of the Force (枚举+线段树+二分图)
    2019 ICPC上海站K.Color Graph
    Wi Know (思维+线段树)
    Linux zookeeper 安装
    javaBIO
  • 原文地址:https://www.cnblogs.com/guipeng/p/12104831.html
Copyright © 2011-2022 走看看