Install Redis 2.8.9
sudo apt-add-repository ppa:chris-lea/redis-server sudo apt-get update sudo apt-get install redis-server
Remove Redis 2.8.9
sudo apt-get purge--auto-remove redis-server
启动 redis 的服务
root@ubuntu:/usr/local/redis-2.4.14# ./src/redis-server
注意这种方式启动 redis 使用的是默认配置。也可以通过启动参数告诉 redis 使用指定配置文件使用下面命令启动 . $ ./redis-server redis.conf |
启动 redis 客户端和服务端进行交互
naxsu@ubuntu:/usr/local/redis-2.4.14$ ./src/redis-cli redis 127.0.0.1:6379> set foo bar OK redis 127.0.0.1:6379> get foo "bar" redis 127.0.0.1:6379> |
关闭 redis
redis 127.0.0.1:6379> shutdown |
退出客户端
redis 127.0.0.1:6379> quit |
========================================================================
MONGODB
Ubuntu package manager use this key to check the consistency and authenticity of the packages
1
2
3
4
5
6
|
$
sudo
apt
-
key
adv
--
keyserver
hkp
:
//keyserver.ubuntu.com:80 --recv 7F0CEB10
Executing
:
gpg
--
ignore
-
time
-
conflict
--
no
-
options
--
no
-
default
-
keyring
--
homedir
/
tmp
/
tmp
.
nG6OPIkakq
--
no
-
auto
-
check
-
trustdb
--
trust
-
model
always
--
keyring
/
etc
/
apt
/
trusted
.
gpg
--
primary
-
keyring
/
etc
/
apt
/
trusted
.
gpg
--
keyring
/
etc
/
apt
/
trusted
.
gpg
.
d
/
gnome
-
terminator
-
ppa
.
gpg
--
keyserver
hkp
:
//keyserver.ubuntu.com:80 --recv 7F0CEB10
gpg
:
solicitando
clave
7F0CEB10
de
hkp
servidor
keyserver
.
ubuntu
.
com
gpg
:
Cantidad
total
procesada
:
1
gpg
:
importadas
:
1
(
RSA
:
1
)
|
1
2
|
$
echo
'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen'
|
sudo
tee
/
etc
/
apt
/
sources
.
list
.
d
/
mongodb
.
list
deb
http
:
//downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen
|
1
|
$
sudo
apt
-
get
update
|
(a) To restart the mongod service
sudo service <span style="font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 13.3333330154419px; line-height: 24px;">mongod</span> restart
(b) To start mongod Service
sudo service <span style="font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 13.3333330154419px; line-height: 24px;">mongod</span> start
(c) To stop mongod service
sudo service <span style="font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 13.3333330154419px; line-height: 24px;">mongod</span> stop
(c) To get status of mongod service
sudo service <span style="font-family: Verdana, Geneva, Arial, Helvetica, sans-serif; font-size: 13.3333330154419px; line-height: 24px;">mongod</span> status
转自:http://www.sysads.co.uk/2014/05/install-redis-2-8-9-ubuntu-14-04-13-10/
http://itway.iteye.com/blog/1555063
http://www.cnblogs.com/SuperLiangG/p/4335657.html