zoukankan      html  css  js  c++  java
  • Error: undefined method `resolve_alias' for Formula:Class

    问题描述

    • 操作环境:mac

    • 动作:通过brew services命令启动grafana

    brew services start grafana
    
    

    报错信息:

    Error: undefined method `resolve_alias' for Formula:Class
    /usr/local/bin/brew-services.rb:154:in `service'
    /usr/local/bin/brew-services.rb:203:in `check'
    /usr/local/bin/brew-services.rb:193:in `run!'
    /usr/local/bin/brew-services.rb:397:in `<top (required)>'
    /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.3/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
    /usr/local/Homebrew/Library/Homebrew/vendor/portable-ruby/2.6.3/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
    /usr/local/Homebrew/Library/Homebrew/utils.rb:82:in `require?'
    /usr/local/Homebrew/Library/Homebrew/brew.rb:108:in `<main>'
    

    解决过程

    • 根据关键报错信息google,得到的解决办法是执行命令brew update,没有work。
    • 考虑安装brew-services过程中执行了以下命令,怀疑是brew-services.rb版本旧,无奈https://gist.githubusercontent.com/打不开,无法验证猜测。
    curl -o /usr/local/bin/brew-services.rb https://gist.githubusercontent.com/lwe/766293/raw/75a7907004bbff0eb3b072d1d951be2cfe7e5020/brew-services.rb
    
    
    • 更新HomeBrew
    /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
    
    

    至此,问题解决,启动grafana成功。

    grafana started stephen /Users/stephen/Library/LaunchAgents/homebrew.mxcl.grafana.plist
    
    
  • 相关阅读:
    4-6 随机数
    linux下安装jdk
    markdown使用教程
    IDE新建gradle各种坑
    day05泛型类和泛型方法
    day05集合
    day15 Ui自动化中三种等待方式
    day15 Ui自动化元素的定位
    Windows系统
    解决sublime text 3使用Install Package时出现There are no packages available for installation问题
  • 原文地址:https://www.cnblogs.com/webDepOfQWS/p/12766614.html
Copyright © 2011-2022 走看看