参考文章:

https://blog.csdn.net/a60919820/article/details/101847890

安装mysql

参考:https://www.cnblogs.com/haima/p/15504670.html

再安装libmysqlclient-devmysql2

sudo cp /etc/apt/sources.list /etc/apt/sources.listbak #备份源
sudo vim /etc/apt/sources.list # 添加下面的源
deb [by-hash=force] https://mirrors.huaweicloud.com/deepin/ apricot main contrib non-free
sudo apt-get update #更新源
sudo apt-get upgrade 不用执行 安装mysql
参考下面的链接下载 mysql-apt-config_0.8.20-1_all.deb https://www.ywnz.com/linuxysjk/9249.html 选择安装mysql87或者mysql5.7的源
sudo dpkg -i ./mysql-apt-config_0.8.20-1_all.deb sudo apt-get update #更新源
sudo apt-get install mysql-server #安装mysql sudo service mysql status #查看MySQL是否安装成功 sudo apt-get install libmysqlclient-dev #安装mysql客户端依赖 cd 进入项目的根目录里
gem install mysql2 -v '0.4.10' --source 'https://gems.ruby-china.com/'
bundle install #安装项目的依赖
rails s #启动项目

ERROR: Error installing mysql2: ERROR: Failed to build gem native extension [@Ubuntu 15.04]的更多相关文章

  1. warning insecure world writable dir ruby mode 040777,gem insstal sass error failed to build gem native extension

    //1.删除原gem源 gem sources --remove https://rubygems.org/ //2.添加国内镜像 gem source -a https://gems.ruby-ch ...

  2. 安装sass时遇到Failed to build gem native extension

    错误信息 执行命令: sudo gem install sass时遇到下面的错误信息 Building native extensions. This could take a while... ER ...

  3. Ruby 踩坑 “Failed to build gem native extension”

    ruby新手,总是会出现这样那样的问题,这里先记录下,希望能解决你得问题. 首先是安装ruby 环境,楼主愚钝,在公司和自己的电脑上来来回回整了好几天,每次安装 gem 包的时候总是报错,错误信息大致 ...

  4. HADOOP 2.6 INSTALLING ON UBUNTU 14.04 (hadoop 2.6 部署到ubuntu 14.04上面)

    Hadoop on Ubuntu 14.04 In this chapter, we'll install a single-node Hadoop cluster backed by the Had ...

  5. Installing Nginx With PHP5 (And PHP-FPM) And MySQL Support (LEMP) On Ubuntu 12.04 LTS [repost]

    from : http://www.howtoforge.com/installing-nginx-with-php5-and-php-fpm-and-mysql-support-lemp-on-ub ...

  6. 解决 React-Native mac 运行报错 error Failed to build iOS project. We ran "xcodebuild" command but it exited with error code 65. To debug build logs further, consider building your app with Xcode.app, by ope

    React-Native 开发的项目,Android 方面没有任何问题,IOS 就是无法跑起来,报错信息如下: mac 10.14.4 xcode 10.2.1 error Failed to bui ...

  7. postman Installation has failed: There was an error while installing the application. Check the setup log for more information and contact the author

    Error msg: Installation has failed: There was an error while installing the application. Check the s ...

  8. 报error:getNetworkFromStore for nid failed while trying to build sandbox for cleanup: network

    docker服务起不来.报error:getNetworkFromStore for nid failed while trying to build sandbox for cleanup: net ...

  9. Entrypoint undefined = index.html html-webpack-plugin 错误ERROR in Error: Child compilation failed: Module build failed (from ./node_modules/html-webpack-plu SyntaxError: Unexpected token )

    Entrypoint undefined = index.html html-webpack-plugin 错误 ERROR in Error: Child compilation failed: M ...

  10. Mac 无法安装安装psutil 报错 error: command '/usr/bin/clang' failed with exit status 1

    psutil是一个特别好用来检查系统资源的一个包, 但是 在Mac安装却总是报错 查看监控系统脚本, 点这里 mac系统版本: Macos Mojave 10.14.3 报错信息如下: WARNING ...

随机推荐

  1. KGIS支持的扩展介绍

    1.postgis postgis的基本核心功能,仅支持地理图形(矢量要素),在其他Extension前启用. 2.postgis_raster 对栅格数据的支持. 3.postgis_topolog ...

  2. 15 JavaScript ES6中的箭头函数

    15 JavaScript ES6中的箭头函数 什么是箭头函数 ES6中允许使用=>来定义函数.箭头函数相当于匿名函数,并简化了函数定义. 基本语法 // 箭头函数 let fn = (name ...

  3. #莫比乌斯函数,Miller-Rabin#洛谷 3653 小清新数学题

    题目 求\(\sum_{i=l}^r\mu(i),r-l\leq 10^5,1\leq l\leq r\leq 10^{18}\) 分析 其实有一道可以算是弱化版的题目 这种类型的tricks就是枚举 ...

  4. #后缀数组,单调队列#洛谷 2852 [USACO06DEC]Milk Patterns G

    题目 给定一个长度为\(n\)的字符串,求出现至少\(k\)次的最长子串长度 分析 由于后缀排序后的LCP才是最长的,既然要求至少\(k\)次, 实际上也就是维护长度为\(k\)的height数组最小 ...

  5. 一种基于DeltaE(CIE 1976)的找色算法Cuda实现

    书接上文 一种基于DeltaE(CIE 1976)的找色算法 Delta E 是评估色彩准确度的重要测量指标.摄影师.影片编辑和平面设计师等创意专业人士都应重视这项标准,因其是选择专业级显示器的重要考 ...

  6. Gitee码云:用git上传本地文件到码云gitee的方法

    首先登录码云 https://gitee.com/,注册一个账号,并登录账号. 1. 在码云上创建项目 在码云首页顶部,下图所示,右上角头像旁边的加号,鼠标移上去会显示下拉的,点击"新建项目 ...

  7. openGauss事务机制中MVCC技术的实现分析

    openGauss 事务机制中 MVCC 技术的实现分析 概述 事务 事务是为用户提供的最核心.最具吸引力的数据库功能之一.简单地说,事务是用户定义的一系列数据库操作(如查询.插入.修改或删除等)的集 ...

  8. HDC2021技术分论坛:HarmonyOS低代码开发介绍

    作者:sunyuhui,wangxiaoyan,华为2012实验室软件IDE专家 什么是低代码开发?低代码开发主要特点有哪些?如何利用低代码开发原子化服务?本文带你一探究竟~ 一.什么是Harmony ...

  9. CentOS下修改 MySQL 的密码

    做服务器运维,修改 MySQL 的密码是经常的需要,定期修改 MySQL 密码是网站安全的一个保证.这里记录一下修改 MySQL 密码的一些命令,方便以后查看. 修改root密码 CentOS 下 M ...

  10. linux 性能自我学习 ———— cpu 快速定位问题 [六]

    前言 主要介绍一下cpu如何快速定位问题. 正文 cpu 的一些性能指标: 1. cpu 使用率 cpu 使用率描述了非空闲时间占总cpu时间的百分比,根据cpu上运行任务的不同,又被分为用户cpu. ...