Subaru's Husband -10ページ目

Subaru's Husband

python、linux、バイクなんかのネタを書きます。
一応security業界でご飯を食べてます。
備忘録がメインだと思うので、未来の自分が助かれば最高。

Macにlocustをインストールしたかったので先にhomebrewをインストールしてから

1.libevent
2.sudo easy_install locustio

を実行
------------------------------------------
$brew install libevent
==> Installing libevent dependency: openssl
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/openssl-1.0.1k.yosemite.bottle.tar.gz
######################################################################## 100.0%
==> Pouring openssl-1.0.1k.yosemite.bottle.tar.gz
==> Caveats
A CA file has been bootstrapped using certificates from the system
keychain. To add additional certificates, place .pem files in
/usr/local/etc/openssl/certs

and run
/usr/local/opt/openssl/bin/c_rehash

This formula is keg-only, which means it was not symlinked into /usr/local.

Mac OS X already provides this software and installing another version in
parallel can cause all kinds of trouble.

Apple has deprecated use of OpenSSL in favor of its own TLS and crypto libraries

Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:

LDFLAGS: -L/usr/local/opt/openssl/lib
CPPFLAGS: -I/usr/local/opt/openssl/include

==> Summary
/usr/local/Cellar/openssl/1.0.1k: 431 files, 15M
==> Installing libevent
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/libevent-2.0.22.yosemite.bottle.tar.gz
######################################################################## 100.0%
==> Pouring libevent-2.0.22.yosemite.bottle.tar.gz
/usr/local/Cellar/libevent/2.0.22: 48 files, 1.8M

$sudo easy_install locustio
pythonの負荷テストツール「locust」をMacにインストールしたかったのでhomebrewをインストール

22B-mac:~ mandkc$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
==> This script will install:
/usr/local/bin/brew
/usr/local/Library/...
/usr/local/share/man/man1/brew.1
==> The following directories will be made group writable:
/usr/local/.
/usr/local/bin
/usr/local/include
/usr/local/lib
/usr/local/lib/pkgconfig
/usr/local/share
/usr/local/share/man
/usr/local/share/man/man1
==> The following directories will have their group set to admin:
/usr/local/.
/usr/local/bin
/usr/local/include
/usr/local/lib
/usr/local/lib/pkgconfig
/usr/local/share
/usr/local/share/man
/usr/local/share/man/man1

Press RETURN to continue or any other key to abort
==> /usr/bin/sudo /bin/chmod g+rwx /usr/local/. /usr/local/bin /usr/local/include /usr/local/lib /usr/local/lib/pkgconfig /usr/local/share /usr/local/share/man /usr/local/share/man/man1
Password:
==> /usr/bin/sudo /usr/bin/chgrp admin /usr/local/. /usr/local/bin /usr/local/include /usr/local/lib /usr/local/lib/pkgconfig /usr/local/share /usr/local/share/man /usr/local/share/man/man1
==> /usr/bin/sudo /bin/mkdir /Library/Caches/Homebrew
==> /usr/bin/sudo /bin/chmod g+rwx /Library/Caches/Homebrew
==> Downloading and installing Homebrew...
remote: Counting objects: 225283, done.
remote: Compressing objects: 100% (59257/59257), done.
remote: Total 225283 (delta 164815), reused 225234 (delta 164779)
Receiving objects: 100% (225283/225283), 51.32 MiB | 3.54 MiB/s, done.
Resolving deltas: 100% (164815/164815), done.
From https://github.com/Homebrew/homebrew
* [new branch] master -> origin/master
HEAD is now at 6d91bcb nodebrew 0.8.0
==> Installation successful!
==> Next steps
Run `brew doctor` before you install anything
Run `brew help` to get started

コンソールで日本語が化けるから調べてみたら、下記のやり方で対応できました。

$sudo
localedef -i ja_JP -f UTF-8 ja_JP.UTF-8

$sudo nano /etc/default/locale

#LANG="en_US.UTF-8"
LANG="ja_JP.UTF-8"
LANGUAGE="en_US:en"