zoukankan      html  css  js  c++  java
  • ubuntu安装zookeeper和ruby

    安装zookeeper服务

    1. 下载zookeeper包
    2. wget https://mirrors.tuna.tsinghua.edu.cn/apache/zookeeper/zookeeper-3.4.12/zookeeper-3.4.12.tar.gz
    3. 解压拷贝进/usr/local下
    4. sudo cp zoo_sample.cfg zoo.cfg
    5. 修改zoo.cfg配置

     

    1. 在/var/lib/zookeeper建myid文件。在myid文件中输入1表示为server.1。 输入2则表示server.2
    2. 在/usr/local/ zookeeper-3.4.12/bin下,最好是整个zookeeper目录赋777权限,在bin目录下./zkServer.sh start|stop|restart,启动、停止、重启等命令
    3. 启动后,在bin目录下./zkCli.sh进入zookeeper客户端,进入后,输入ls,或者新建create /NewCrawlerTest crawlertest,

    或者删除delete /NewCrawlerTest

    或者查看 get /NewCrawlerTest

    安装ruby:

    1. Sudo apt-get install ruby ruby-dev
    2. 查看版本号:ruby –v; gem –v

    **Bundler** — If Ruby is already installed, but the `bundle` command doesn't work, just run `gem install bundler`

            3.sudo gem install bundler

    4.

    出现如上图错误:安装bundler,执行bundle install –deployment

    5.执行build代码bundle exec middleman build –clean,出现如下图错误

    解决:安装nodejs即可,安装后查看node -v:

    5.1 sudo apt-get install nodejs

    5.2  sudo apt-get install nodejs-legacy

  • 相关阅读:
    hdu5249
    hdu5673-Robot
    hihoCoder 1033
    simpleOS 1.0
    hdu3511-Prison Break
    单调栈
    关于每次取PC的值为PC+4的问题
    hdu3652
    Linux MySQL5.7.18安装手册
    Linux MySQL5.6.36安装手册
  • 原文地址:https://www.cnblogs.com/lingwang3/p/10120892.html
Copyright © 2011-2022 走看看