I can’t seem to get the aql command line tool working after I customize aerospike.conf on a fresh Ubuntu instance with Aerospike Community 3.5.
Problem: When running the aql CLI tool on Ubuntu, I see the following error:
root@test:~/aerospike-server-community-3.5.12-ubuntu12.04# aql
WARN AEROSPIKE_ERR_CLIENT Socket write error: 111
Error -1: Failed to seed cluster
Environment:
Distributor ID: Ubuntu
Description: Ubuntu 14.04.2 LTS
Release: 14.04
Box is a fresh Rackspace VPS with 1GB ram, 1 GHz CPU.
Aerospike version is aerospike-server-community-3.5.12-ubuntu12.04
To Replicate:
Step 1. On a fresh Ubuntu instance, install Aerospike using the following directions then run ‘aql’ to test that the tool works: http://www.aerospike.com/docs/operations/install/linux/ubuntu/
Output:
wget -O aerospike.tgz 'http://aerospike.com/download/server/latest/artifact/ubuntu12'
tar -xvf aerospike.tgz
cd cd aerospike-server-community-3.5.12-ubuntu12.04/
./asinstall
service aerospike start
service aerospike start
* Start aerospike: asd kernel.shmall too low, setting to 4G pages = 16TB
kernel.shmall = 4294967296
kernel.shmmax too low, setting to 1GB
kernel.shmmax = 1073741824
root@test:~/aerospike-server-community-3.5.12-ubuntu12.04# aql
Aerospike Query
Copyright 2013 Aerospike. All rights reserved.
aql>
Step 2: Edit the default /etc/aerospike/aerospike.conf and insert the following namespace configuration:
namespace default {
replication-factor 2
memory-size 1G
default-ttl 0
storage-engine device {
file /opt/aerospike/data/default.dat
filesize 2T
data-in-memory true
}
}
Step 3: Restart aerospike and try the aql tool again (everything seems to work fine at this point)
Output:
root@test:~/aerospike-server-community-3.5.12-ubuntu12.04# service aerospike restart
* Halt aerospike: asd [ OK ]
* Start aerospike: asd [ OK ]
root@test:~/aerospike-server-community-3.5.12-ubuntu12.04# aql
Aerospike Query
Copyright 2013 Aerospike. All rights reserved.
aql>
Step 4: Restart aerospike again and then running aql will exit mysteriously with an error
Output:
root@test:~/aerospike-server-community-3.5.12-ubuntu12.04# service aerospike restart
* Halt aerospike: asd [ OK ]
* Start aerospike: asd [ OK ]
root@test:~/aerospike-server-community-3.5.12-ubuntu12.04# aql
2015-06-05 08:59:32 WARN AEROSPIKE_ERR_CLIENT Socket write error: 111
Error -1: Failed to seed cluster
Note that I’ve been able to reproduce this many times on new server instances. Any ideas?