Tag Info

Hot answers tagged

17

Your post doesn't describe much in the way of specs (memory on the LS indexer, log volume or much else) but I'll try and answer your questions best I can first. Disclaimer: I'm one of the logstash devs - Apache going nuts was likely a side effect of the logstash process acting up. I'd put that aside for now. The sane way to make ES f/b/s is add more ES ...


14

Create a new config file /etc/redis/redis-new.conf (copied from redis.conf) and change these fields in the new config pidfile port logfile dir (for the default db) Create a new file /etc/init.d/redis-server-new (copied from the file redis-server) and change these fields in the new file name pidfile (same as in the config file in step 1) deamon_args (the ...


13

By default, the SELinux policy will only allow services access to recognized ports associated with those services: # semanage port -l | egrep '(^http_port_t|6379)' http_port_t tcp 80, 81, 443, 488, 8008, 8009, 8443, 9000 # curl http://localhost/redis.php Cannot connect to redis server. - add Redis port (6379) to SELinux policy # ...


11

Either compile from source or build a .deb package via fpm: Install fpm with gem: # apt-get install rubygems # gem install fpm Compile Redis: # cd /usr/local/src/ # wget http://redis.googlecode.com/files/redis-2.4.16.tar.gz # tar zxvf redis-2.4.16.tar.gz # cd redis-2.4.16/ # make Build .deb package: # mkdir -p /tmp/redis-$VERSION.$$/usr/bin # mkdir ...


9

By default redis listens on 127.0.0.1 have you edited your redis.conf to include the line bind your.private.ip.address ?


7

After few days of intense trial and errors, I'm glad to be able to say that I've understood where the bottleneck was, and I'll post it here so that other people can benefit from my findings. The problem lies in the pub/sub connections that I was using with socket.io, and in particular in the RedisStore used by socket.io to handle inter-process ...


6

You're abusing Nginx's worker_threads. There is absolutely no need to run that many workers. You should run as many workers as you have CPUs and call it a day. If you're running gunicorn on the same server, you should probably limit nginx workers to two. Otherwise, you're just going to thrash the CPUs with all the context switching required to manage all of ...


6

Is it possible that, in your innermost else block, the call to redis-server is returning immediately, but the server itself is taking more than one second to start up? In that case, wait won't wait long enough.


6

There are two ways: The first is just to specify a numeric --retry value. Then it will use /signal/timeout/KILL/timeout schedule. I.e. send a terminating signal (specified with --signal option), then wait the specified number of seconds and then send a KILL signal that could not be ignored by a process and therefore it will be forced to exit. The command ...


5

The way we handle this is by creating multiple groups of servers in a layered stack (even if a group currently only needs one instance). The first layer is your Elastic Load Balancer, clearly. The second layer is an Auto Scaling Group of web servers (multi-availability zone). These boot a custom AMI designed be in a proper ready-state for this task on ...


5

To do this, you need to make sure that your IPTables rules are configured properly. Ubuntu generally leaves their servers wide open by default, which is why I still don't recommend their use as servers unless you are quite well aware of how to do this properly already. I imagine that your iptables -L -nv looks something like this, yes? # iptables -L -nv ...


5

I would recommend installing redis on something, your laptop, whatever you have available now. Then generate some nontrivial amount of data shaped like what you plan to store on the eventual server. Say 100,000 values. Then, load that into redis in the way you expect your application to. Then, see how much memory redis is using: redis-cli info | grep ...


5

At Stack Exchange we run multiple instances of Redis on a single server and we have never seen any issues: [kbrandt@ny-redis01: ~] ps -e -o vsz,cmd | grep redis-server | sort -nr 15943668 /usr/sbin/redis-server *:6382 14966708 /usr/sbin/redis-server *:6379 7878376 /usr/sbin/redis-server *:6380 2692092 /usr/sbin/redis-server *:6384 1855480 ...


5

You installed the EPEL repository for EL7, but you are actually running EL6. Remove the epel-release package, i.e., sudo yum search epel && sudo yum remove epel-release and replace it with the correct package. According to this documentation Redis could be installed on CentOS6 by issuing the following commands: // --- Compiling --- $ wget ...


4

It is not an environmental setting, but a default setting. Check the source code: def __init__(self, host='localhost', port=6379, password=None, ... ) Change it in the configuration file: # Accept connections on the specified port, default is 6379. # If port 0 is specified Redis will not listen on a TCP socket. #port 6379 # If you want you can bind a ...


4

Edit your config file to set the dir option to the current working directory: # The filename where to dump the DB dbfilename dump.rdb # The working directory. # # The DB will be written inside this directory, with the filename specified # above using the 'dbfilename' configuration directive. # # Also the Append Only File will be created inside this ...


4

Adding to Dan's answer, According to this error in the log file we have to create one extra directory # Can't chdir to '/var/lib/redis-new': No such file or directory so mkdir /var/lib/redis-new Otherwise /etc/init.d/redis-server-new won't start. Don't forget to add proper rights by chown redis:redis /var/lib/redis-new


4

Find your redis.conf file and comment out the line that reads Bind 127.0.0.1. Most out of the box installs have the interface only excepting local connections. Once you comment that out and restart redis server you will be able to connect assuming no other firewall is keeping from getting in On Ubuntu Linux you can go location /etc/init.d and issue the this ...


4

The output from 'top' might yield some clues. There's a field near the top left labeled '% stolen' which reflects the amount of hardware CPU diverted to other guests on the same physical box. I've seen these kinds of slow downs when the hypervisor decides to allocate more CPU to another guest, especially when I'm performing some long-running CPU-intensive ...


4

At the server side, for a simple failover, you can do it by using Nagios and NRPE. On the Nagios server: define service{ use critical-service host_name B service_description redis:2302 check_command check_tcp!2302 event_handler promote_redis!C!2302 contact_groups ...


3

The trick is to put an init script in your /etc/init.d/ and then use the update-rc.d command to enable/disable it. I use a modified version of this init script. Also take a look at this post. Hope it points you to the right direction.


3

Obviously, if you're actively swapping, you have too many. Swap usage doesn't mean you're actively swapping. Swap I/O means you're actively swapping. However, actively swapping isn't the only way excessive application memory use can hurt you. Every byte of memory that applications are actively using is one byte of memory that can't be used as a disk cache. ...


3

This is pretty well covered in the Supervisord intro chapter. Most services will run/work just fine with init.d, and that will be their default, out-of-the-box config. The process managers exist to give you expanded and finer-grained control and monitoring of your critical processes and services if that is something you desire/require.


3

Redis is an in-memory database, you are probably better off looking at something designed to be "on disk", though there are some really nice aspects of redis I have struggled to find elsewhere :(


3

Go to source tree and try this command: make uninstall If that doesn't work you can list the steps that the software would take to install itself (without actually installing anything): make -n install


3

I'm trying to segment a few servers for a Rails project and part of that is entertaining the idea of isolating Resque workers to their own box. I already have Redis broken out, but is it common to put Resque workers elsewhere? I'm going to make this a bit more generic. Is it common to put job processing workers on different machines than the ...


3

What exactly are you asking for? Redis is not officially supported on Windows, so there should be no question about installing it on the RHEL boxes. Redis RPMs are available at http://rpmfind.net/linux/rpm2html/search.php?query=redis Redis is a memory hungry process, so you will want to install it on the instances that have the most spare RAM.


3

Buy another server, do sharding. This is how Redis is intended to work. If that isn't that what you want, then Redis is the wrong software for your purpose.


3

Do you have Redis listening on an interface other than localhost or 127.0.0.1? If so, the stop command is never being sent to the right interface, as the official Redis init template fails to include the host address. In the /etc/init.d/redis files I’ve worked with, I had to define REDISHOST=10.150.0.18 and then on line 30 (look for “shutdown”) add that ...


3

If you were like me, you required a password (requirepass) in your redis.conf. the redis-cli command won't respond without the password now. In the first few lines of your /etc/init.d/redis file look for CLIEXEC and change the default CLIEXEC=/usr/local/bin/redis-cli to CLIEXEC="/usr/local/bin/redis-cli -a <password>" Please take note of the ...



Only top voted, non community-wiki answers of a minimum length are eligible