redis add 'vm.overcommit_memory = 1' to /etc/sysctl.conf

w

root@well:/etc# vim sysctl.conf

#kernel.domainname = example.com

#
# /etc/sysctl.conf - Configuration file for setting system variables
# See /etc/sysctl.d/ for additional system variables.
# See sysctl.conf () for information.
# #kernel.domainname = example.com # Uncomment the following to stop low-level messages on console
#kernel.printk = ##############################################################
# Functions previously found in netbase
# # Uncomment the next two lines to enable Spoof protection (reverse-path filter)
# Turn on Source Address Verification in all interfaces to
# prevent some spoofing attacks
#net.ipv4.conf.default.rp_filter=
#net.ipv4.conf.all.rp_filter= # Uncomment the next line to enable TCP/IP SYN cookies
# See http://lwn.net/Articles/277146/
# Note: This may impact IPv6 TCP sessions too
#net.ipv4.tcp_syncookies= # Uncomment the next line to enable packet forwarding for IPv4
#net.ipv4.ip_forward= # Uncomment the next line to enable packet forwarding for IPv6
# Enabling this option disables Stateless Address Autoconfiguration
# based on Router Advertisements for this host
#net.ipv6.conf.all.forwarding= ###################################################################
# Additional settings - these settings can improve the network
# security of the host and prevent against some network attacks
# including spoofing attacks and man in the middle attacks through
# redirection. Some network environments, however, require that these
# settings are disabled so review and enable them as needed.
#
# Do not accept ICMP redirects (prevent MITM attacks)
#net.ipv4.conf.all.accept_redirects =
#net.ipv6.conf.all.accept_redirects =
# _or_
# Accept ICMP redirects only for gateways listed in our default
# gateway list (enabled by default)
# net.ipv4.conf.all.secure_redirects =
#
# Do not send ICMP redirects (we are not a router)
#net.ipv4.conf.all.send_redirects =
#
# Do not accept IP source route packets (we are not a router)
#net.ipv4.conf.all.accept_source_route =
#net.ipv6.conf.all.accept_source_route =
#
# Log Martian Packets
#net.ipv4.conf.all.log_martians =
#
root@well:/# redis-server
[] Apr ::13.317 # Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf
_._
_.-``__ ''-._
_.-`` `. `_. ''-._ Redis 2.8. (/) bit
.-`` .-```. ```\/ _.,_ ''-._
( ' , .-` | `, ) Running in stand alone mode
|`-._`-...-` __...-.``-._|'` _.-'| Port:
| `-._ `._ / _.-' | PID: 1143
`-._ `-._ `-./ _.-' _.-'
|`-._`-._ `-.__.-' _.-'_.-'|
| `-._`-._ _.-'_.-' | http://redis.io
`-._ `-._`-.__.-'_.-' _.-'
|`-._`-._ `-.__.-' _.-'_.-'|
| `-._`-._ _.-'_.-' |
`-._ `-._`-.__.-'_.-' _.-'
`-._ `-.__.-' _.-'
`-._ _.-'
`-.__.-' [] Apr ::13.318 # Server started, Redis version 2.8.
[] Apr ::13.318 # WARNING overcommit_memory is set to ! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
[] Apr ::13.318 * The server is now ready to accept connections on port
^C
上一篇:postgresql----聚合函数


下一篇:redis 事务,持久化,日志,主从,VM