[MemSQL]: Installation with Ops Manager
[Dev root @ dbversity1host~]# ll -lhtr
total 164M
-rw-r–r– 1 root root 149M Jul 30 09:59 memsqlbin_amd64.tar
-rw-r–r– 1 root root 15M Jul 30 09:59 memsql-ops-4.0.31.tar
[Dev root @ dbversity1host~]
[Dev root @ dbversity1host~]# mkdir /memsql
[Dev root @ dbversity1host~]
[Dev root @ dbversity1host~]# mv * /memsql/
Create swap files as below which are required for MemSQL
[Dev root @ dbversity1host~]# snapshot_dir=”/var/lib/memsql/data/snapshots”
[Dev root @ dbversity1host~]# snapshot_file=”$snapshot_dir/memsql.swp”
[Dev root @ dbversity1host~]# mkdir -p $snapshot_dir
[Dev root @ dbversity1host~]# dd if=/dev/zero of=$snapshot_file bs=1M count=10240
10240+0 records in
10240+0 records out
10737418240 bytes (11 GB) copied, 133.463 s, 80.5 MB/s
[Dev root @ dbversity1host~]# chmod 600 $snapshot_file
[Dev root @ dbversity1host~]# mkswap $snapshot_file
mkswap: /var/lib/memsql/data/snapshots/memsql.swp: warning: don’t erase bootbits sectors
on whole disk. Use -f to force.
Setting up swapspace version 1, size = 10485756 KiB
no label, UUID=651030f4-f21d-4adf-9712-d3bebc177e10
[Dev root @ dbversity1host~]# swapon $snapshot_file
[Dev root @ dbversity1host~]# echo “$snapshot_file swap swap defaults 0 0” | tee -a /etc/fstab
/var/lib/memsql/data/snapshots/memsql.swp swap swap defaults 0 0
[Dev root @ dbversity1host~]#
[Dev root @ dbversity1host~]#
[Dev root @ dbversity1host~]#
[Dev root @ dbversity1host~]#
Set below values at limits.conf
* soft NOFILE 1000000
* hard NOFILE 1000000
* soft NPROC 128000
* hard NPROC 128000
[Dev root @ dbversity1host~]# vi /etc/security/limits.conf
# /etc/security/limits.conf
#
#Each line describes a limit for a user in the form:
#
#<domain> <type> <item> <value>
#
#Where:
#<domain> can be:
# – a user name
# – a group name, with @group syntax
# – the wildcard *, for default entry
# – the wildcard %, can be also used with %group syntax,
# for maxlogin limit
#
#<type> can have the two values:
# – “soft” for enforcing the soft limits
# – “hard” for enforcing hard limits
#
#<item> can be one of the following:
# – core – limits the core file size (KB)
# – data – max data size (KB)
# – fsize – maximum filesize (KB)
# – memlock – max locked-in-memory address space (KB)
# – nofile – max number of open file descriptors
# – rss – max resident set size (KB)
# – stack – max stack size (KB)
# – cpu – max CPU time (MIN)
# – nproc – max number of processes
# – as – address space limit (KB)
# – maxlogins – max number of logins for this user
# – maxsyslogins – max number of logins on the system
# – priority – the priority to run user process with
# – locks – max number of file locks the user can hold
# – sigpending – max number of pending signals
# – msgqueue – max memory used by POSIX message queues (bytes)
# – nice – max nice priority allowed to raise to values: [-20, 19]
# – rtprio – max realtime priority
#
#<domain> <type> <item> <value>
#
#* soft core 0
#* hard rss 10000
#@student hard nproc 20
#@faculty soft nproc 20
#@faculty hard nproc 50
#ftp hard nproc 0
#@student – maxlogins 4
# End of file
* soft NOFILE 1000000
* hard NOFILE 1000000
* soft NPROC 128000
* hard NPROC 128000
~
~
“/etc/security/limits.conf” 56L, 1921C written
[Dev root @ dbversity1host~]
[Dev root @ dbversity1host~]
# vi /etc/sysctl.conf
# Kernel sysctl configuration file for Red Hat Linux
#
# For binary values, 0 is disabled, 1 is enabled. See sysctl(8) and
# sysctl.conf(5) for more details.
# Controls IP packet forwarding
net.ipv4.ip_forward = 0
# Controls source route verification
net.ipv4.conf.default.rp_filter = 1
# Do not accept source routing
net.ipv4.conf.default.accept_source_route = 0
# Controls the System Request debugging functionality of the kernel
kernel.sysrq = 1
# Controls whether core dumps will append the PID to the core filename.
# Useful for debugging multi-threaded applications.
kernel.core_uses_pid = 1
# Controls the use of TCP syncookies
net.ipv4.tcp_syncookies = 1
# Disable netfilter on bridges.
net.bridge.bridge-nf-call-ip6tables = 0
net.bridge.bridge-nf-call-iptables = 0
net.bridge.bridge-nf-call-arptables = 0
# Controls the default maxmimum size of a mesage queue
kernel.msgmnb = 65536
# Controls the maximum size of a message, in bytes
kernel.msgmax = 65536
# Controls the maximum shared segment size, in bytes
kernel.shmmax = 68719476736
# Controls the maximum number of shared memory segments, in pages
kernel.shmall = 4294967296
vm.max_map_count=1000000000
vm.min_free_kbytes=500000
~
~
~
~
~
~
~
~
~
~
~
~
~
~
~
“/etc/sysctl.conf” 43L, 1205C written
[Dev root @ dbversity1host~]
[Dev root @ dbversity1host~]# cd /memsql/
[Dev root @ dbversity1host/memsql]
# ll -lhtr
total 164M
-rw-r–r– 1 root root 149M Jul 30 09:59 memsqlbin_amd64.tar
-rw-r–r– 1 root root 15M Jul 30 09:59 memsql-ops-4.0.31.tar
[Dev root @ dbversity1host/memsql]#
[Dev root @ dbversity1host/memsql]#
[Dev root @ dbversity1host/memsql]# tar -xvf memsql-ops-4.0.31.tar
memsql-ops-4.0.31/
memsql-ops-4.0.31/install.sh
memsql-ops-4.0.31/memsql-ops/
memsql-ops-4.0.31/README
memsql-ops-4.0.31/memsql-ops/lib/
memsql-ops-4.0.31/memsql-ops/memsql-ops
memsql-ops-4.0.31/memsql-ops/static/
memsql-ops-4.0.31/memsql-ops/static/assets/
memsql-ops-4.0.31/memsql-ops/static/fonts/
memsql-ops-4.0.31/memsql-ops/static/html/
memsql-ops-4.0.31/memsql-ops/static/images/
memsql-ops-4.0.31/memsql-ops/static/images/chrome_icon.png
memsql-ops-4.0.31/memsql-ops/static/images/favicon.ico
memsql-ops-4.0.31/memsql-ops/static/images/firefox_icon.png
memsql-ops-4.0.31/memsql-ops/static/images/intro_step_1.svg
memsql-ops-4.0.31/memsql-ops/static/images/intro_step_2.svg
memsql-ops-4.0.31/memsql-ops/static/images/intro_step_3.svg
memsql-ops-4.0.31/memsql-ops/static/images/logo.svg
memsql-ops-4.0.31/memsql-ops/static/html/index.html
memsql-ops-4.0.31/memsql-ops/static/fonts/fontawesome-webfont.eot
memsql-ops-4.0.31/memsql-ops/static/fonts/fontawesome-webfont.svg
memsql-ops-4.0.31/memsql-ops/static/fonts/fontawesome-webfont.ttf
memsql-ops-4.0.31/memsql-ops/static/fonts/fontawesome-webfont.woff
memsql-ops-4.0.31/memsql-ops/static/fonts/fontawesome-webfont.woff2
memsql-ops-4.0.31/memsql-ops/static/fonts/Roboto-Bold.ttf
memsql-ops-4.0.31/memsql-ops/static/fonts/Roboto-Bold.woff
memsql-ops-4.0.31/memsql-ops/static/fonts/Roboto-Regular.ttf
memsql-ops-4.0.31/memsql-ops/static/fonts/Roboto-Regular.woff
memsql-ops-4.0.31/memsql-ops/static/assets/index.js
memsql-ops-4.0.31/memsql-ops/static/assets/styles.css
memsql-ops-4.0.31/memsql-ops/lib/_bisect.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_bz2.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_codecs_cn.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_codecs_hk.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_codecs_iso2022.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_codecs_jp.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_codecs_kr.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_codecs_tw.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_crypt.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_csv.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_ctypes.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_curses.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_datetime.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_elementtree.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_hashlib.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_heapq.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_json.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_md5.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_multibytecodec.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_multiprocessing.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_mysql.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_opcode.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_pickle.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_posixsubprocess.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_psutil_linux.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_psutil_posix.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_random.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_sha1.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_sha256.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_sha512.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_socket.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_ssl.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/_struct.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/apsw.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/array.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/binascii.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/build_receipt.json
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Cipher._AES.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Cipher._ARC4.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Cipher._Blowfish.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Cipher._DES.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Cipher._DES3.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Hash._SHA256.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Util._counter.so
memsql-ops-4.0.31/memsql-ops/lib/Crypto.Util.strxor.so
memsql-ops-4.0.31/memsql-ops/lib/fcntl.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/grp.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/libbz2.so.1
memsql-ops-4.0.31/memsql-ops/lib/libcrypto.so.1.0.0
memsql-ops-4.0.31/memsql-ops/lib/libcrypto.so.6
memsql-ops-4.0.31/memsql-ops/lib/libgssapi_krb5.so.2
memsql-ops-4.0.31/memsql-ops/lib/libk5crypto.so.3
memsql-ops-4.0.31/memsql-ops/lib/libkeyutils.so.1
memsql-ops-4.0.31/memsql-ops/lib/libkrb5.so.3
memsql-ops-4.0.31/memsql-ops/lib/libkrb5support.so.0
memsql-ops-4.0.31/memsql-ops/lib/libmysqlclient_r.so.15
memsql-ops-4.0.31/memsql-ops/lib/libncurses.so.5
memsql-ops-4.0.31/memsql-ops/lib/libncursesw.so.5
memsql-ops-4.0.31/memsql-ops/lib/libpython3.4m.so.1.0
memsql-ops-4.0.31/memsql-ops/lib/library.zip
memsql-ops-4.0.31/memsql-ops/lib/libssl.so.1.0.0
memsql-ops-4.0.31/memsql-ops/lib/libssl.so.6
memsql-ops-4.0.31/memsql-ops/lib/math.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/memsql-ops
memsql-ops-4.0.31/memsql-ops/lib/mmap.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/netifaces.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/parser.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/pyexpat.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/readline.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/resource.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/select.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/simplejson._speedups.so
memsql-ops-4.0.31/memsql-ops/lib/termios.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/time.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/tornado.speedups.so
memsql-ops-4.0.31/memsql-ops/lib/unicodedata.cpython-34m.so
memsql-ops-4.0.31/memsql-ops/lib/zlib.cpython-34m.so
[Dev root @ dbversity1host/memsql]#
[Dev root @ dbversity1host/memsql]#
[Dev root @ dbversity1host/memsql]#
[Dev root @ dbversity1host/memsql]#
[Dev root @ dbversity1host/memsql]# ll -lhtr
total 164M
drwxr-xr-x 3 attivioid 20 4.0K Jun 29 22:30 memsql-ops-4.0.31
-rw-r–r– 1 root root 149M Jul 30 09:59 memsqlbin_amd64.tar
-rw-r–r– 1 root root 15M Jul 30 09:59 memsql-ops-4.0.31.tar
[Dev root @ dbversity1host/memsql]
[Dev root @ dbversity1host/memsql]# cd memsql-ops-4.0.31
[Dev root @ dbversity1host/memsql/memsql-ops-4.0.31]#
[Dev root @ dbversity1host/memsql/memsql-ops-4.0.31]#
[Dev root @ dbversity1host/memsql/memsql-ops-4.0.31]# ls -lhtr
total 12K
-rw-r–r– 1 attivioid 20 517 Jun 29 22:30 README
-rwxr-xr-x 1 attivioid 20 1.6K Jun 29 22:30 install.sh
drwxr-xr-x 4 attivioid 20 4.0K Jul 30 10:05 memsql-ops
[Dev root @ dbversity1host/memsql/memsql-ops-4.0.31]#
[Dev root @ dbversity1host/memsql/memsql-ops-4.0.31]# ./install.sh
Installing MemSQL Ops in /var/lib/memsql-ops
Creating a memsql user
Setting up permissions
Creating an init script so that MemSQL Ops runs on startup
Creating a symlink to MemSQL Ops at /usr/bin/memsql-ops
Successfully installed MemSQL Ops!
——————————————————————————–
You can install MemSQL across multiple machines
using the MemSQL Ops Web UI.
You can setup, manage and monitor MemSQL with the MemSQL Ops
web UI on port 9000. Make sure that port 9000 is open in your
firewall or security group.
[Dev root @ dbversity1host/memsql/memsql-ops-4.0.31]
# cd ..
[Dev root @ dbversity1host/memsql]# memsql-ops file-add -t memsql memsqlbin_amd64.tar
Adding a MemSQL file
Unpacking archive to determine its version
Copying file into MemSQL Ops data directory
Registering file with MemSQL Ops
Adding license file from MemSQL archive to MemSQL Ops
2015-07-30 10:09:08: J276ae0 [INFO] Adding a license file for agent A57dd449c4460430aa1fdc52c3cdd0bb2
2015-07-30 10:09:08: J276ae0 [INFO] Successfully added a license file for agent A57dd449c4460430aa1fdc52c3cdd0bb2
Successfully added a MemSQL file with version 4.0.0
[Dev root @ dbversity1host/memsql]
To change to normal prompt
[Dev root @ dbversity1host/memsql]# sed -i “s/readonly PS1/# readonly PS1/g” /etc/profile.d/GSFconf.sh
[Dev root @ dbversity1host/memsql]# echo ‘export PS1=”[ \u @ \h : \w ] “‘ >> ~/.bashrc
[Dev root @ dbversity1host/memsql]# source ~/.bashrc
-bash: PS1: readonly variable
[Dev root @ dbversity1host/memsql]# echo ” ” >> ~/.bashrc
[Dev root @ dbversity1host/memsql]# source ~/.bashrc
-bash: PS1: readonly variable
Logout & re-login
[Dev root @ dbversity1host/memsql]
# logout
bash-4.1$
bash-4.1$ pbrun root
Password:
Enter reason for this privilege access:
[ root @ dbversity1host: ~ ]
[ root @ dbversity1host: ~ ]
[ root @ dbversity1host: ~ ]
[ root @ dbversity1host: ~ ]
[ root @ dbversity1host: ~ ]
[ root @ dbversity1host: ~ ]
[ root @ dbversity1host: /memsql/memsql-ops-4.0.31 ] ./install.sh
Installing MemSQL Ops in /var/lib/memsql-ops
Creating a memsql user
Setting up permissions
Creating an init script so that MemSQL Ops runs on startup
Creating a symlink to MemSQL Ops at /usr/bin/memsql-ops
Successfully installed MemSQL Ops!
——————————————————————————–
You can install MemSQL across multiple machines
using the MemSQL Ops Web UI.
You can setup, manage and monitor MemSQL with the MemSQL Ops
web UI on port 9000. Make sure that port 9000 is open in your
firewall or security group.
[ root @ dbversity1host: /memsql/memsql-ops-4.0.31 ]
[ root @ dbversity1host: /memsql/memsql-ops-4.0.31 ]
[ root @ dbversity1host: /memsql/memsql-ops-4.0.31 ]
[ root @ dbversity1host: /memsql/memsql-ops-4.0.31 ] cd ..
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] ll -lhtr
total 466M
drwxr-xr-x 3 attivioid 20 4.0K Jun 29 22:30 memsql-ops-4.0.31
-rw-r–r– 1 root root 149M Jul 30 09:46 memsqlbin_amd64.tar
-rw-r–r– 1 root root 15M Jul 30 09:46 memsql-ops-4.0.31.tar
-rw-r–r– 1 root root 303M Aug 3 02:30 MySQL-5.6.24-1.rhel5.x86_64.rpm-bundle.tar
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] memsql-ops file-add -t memsql memsqlbin_amd64.tar
Adding a MemSQL file
Unpacking archive to determine its version
Copying file into MemSQL Ops data directory
Registering file with MemSQL Ops
Adding license file from MemSQL archive to MemSQL Ops
2015-08-03 02:37:20: J2b34b9 [INFO] Adding a license file for agent A5662a498e1f5493e8f18a6b1cbb7278a
2015-08-03 02:37:20: J2b34b9 [INFO] Successfully added a license file for agent A5662a498e1f5493e8f18a6b1cbb7278a
Successfully added a MemSQL file with version 4.0.0
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] ps -ef | grep memsql
memsql 7391 1 9 02:36 ? 00:00:13 /var/lib/memsql-ops/lib/memsql-ops start -u memsql –port 9000
memsql 8206 1 3 02:38 ? 00:00:00 /var/lib/memsql-ops/data/installs/MI4aa8d39b1a4741a89308703909ceca60/memsqld –defaults-file=/var/lib/memsql-ops/data/installs/MI4aa8d39b1a4741a89308703909ceca60/memsql.cnf –pid-file=/var/lib/memsql-ops/data/installs/MI4aa8d39b1a4741a89308703909ceca60/memsqld.pid –user=memsql
memsql 8207 1 3 02:38 ? 00:00:00 /var/lib/memsql-ops/data/installs/MIadb5bc02bfaa42d9b27b563401296da9/memsqld –defaults-file=/var/lib/memsql-ops/data/installs/MIadb5bc02bfaa42d9b27b563401296da9/memsql.cnf –pid-file=/var/lib/memsql-ops/data/installs/MIadb5bc02bfaa42d9b27b563401296da9/memsqld.pid –user=memsql
memsql 8210 8206 0 02:38 ? 00:00:00 /var/lib/memsql-ops/data/installs/MI4aa8d39b1a4741a89308703909ceca60/memsqld –defaults-file=/var/lib/memsql-ops/data/installs/MI4aa8d39b1a4741a89308703909ceca60/memsql.cnf –pid-file=/var/lib/memsql-ops/data/installs/MI4aa8d39b1a4741a89308703909ceca60/memsqld.pid –user=memsql
memsql 8212 8207 0 02:38 ? 00:00:00 /var/lib/memsql-ops/data/installs/MIadb5bc02bfaa42d9b27b563401296da9/memsqld –defaults-file=/var/lib/memsql-ops/data/installs/MIadb5bc02bfaa42d9b27b563401296da9/memsql.cnf –pid-file=/var/lib/memsql-ops/data/installs/MIadb5bc02bfaa42d9b27b563401296da9/memsqld.pid –user=memsql
root 8688 4927 0 02:38 pts/1 00:00:00 grep memsql
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] mysql -u root -h dbversity1host-P 3306 –prompt=”memsql> “
-bash: mysql: command not found
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] ll -lhtr
total 466M
drwxr-xr-x 3 attivioid 20 4.0K Jun 29 22:30 memsql-ops-4.0.31
-rw-r–r– 1 root root 149M Jul 30 09:46 memsqlbin_amd64.tar
-rw-r–r– 1 root root 15M Jul 30 09:46 memsql-ops-4.0.31.tar
-rw-r–r– 1 root root 303M Aug 3 02:30 MySQL-5.6.24-1.rhel5.x86_64.rpm-bundle.tar
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] tar -xvf MySQL-5.6.24-1.rhel5.x86_64.rpm-bundle.tar
MySQL-shared-5.6.24-1.rhel5.x86_64.rpm
MySQL-server-5.6.24-1.rhel5.x86_64.rpm
MySQL-embedded-5.6.24-1.rhel5.x86_64.rpm
MySQL-client-5.6.24-1.rhel5.x86_64.rpm
MySQL-test-5.6.24-1.rhel5.x86_64.rpm
MySQL-shared-compat-5.6.24-1.rhel5.x86_64.rpm
MySQL-devel-5.6.24-1.rhel5.x86_64.rpm
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] ll -lhtr
total 768M
-rw-r–r– 1 7155 wheel 23M Mar 26 06:57 MySQL-client-5.6.24-1.rhel5.x86_64.rpm
-rw-r–r– 1 7155 wheel 4.4M Mar 26 06:57 MySQL-devel-5.6.24-1.rhel5.x86_64.rpm
-rw-r–r– 1 7155 wheel 113M Mar 26 06:57 MySQL-embedded-5.6.24-1.rhel5.x86_64.rpm
-rw-r–r– 1 7155 wheel 85M Mar 26 06:58 MySQL-server-5.6.24-1.rhel5.x86_64.rpm
-rw-r–r– 1 7155 wheel 2.3M Mar 26 06:59 MySQL-shared-5.6.24-1.rhel5.x86_64.rpm
-rw-r–r– 1 7155 wheel 5.0M Mar 26 06:59 MySQL-shared-compat-5.6.24-1.rhel5.x86_64.rpm
-rw-r–r– 1 7155 wheel 72M Mar 26 06:59 MySQL-test-5.6.24-1.rhel5.x86_64.rpm
drwxr-xr-x 3 attivioid 20 4.0K Jun 29 22:30 memsql-ops-4.0.31
-rw-r–r– 1 root root 149M Jul 30 09:46 memsqlbin_amd64.tar
-rw-r–r– 1 root root 15M Jul 30 09:46 memsql-ops-4.0.31.tar
-rw-r–r– 1 root root 303M Aug 3 02:30 MySQL-5.6.24-1.rhel5.x86_64.rpm-bundle.tar
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] rpm -ivh *.rpm
Preparing… ########################################### [100%]
1:MySQL-devel ########################################### [ 14%]
2:MySQL-client ########################################### [ 29%]
3:MySQL-test ########################################### [ 43%]
4:MySQL-embedded ########################################### [ 57%]
5:MySQL-shared-compat ########################################### [ 71%]
6:MySQL-shared ########################################### [ 86%]
7:MySQL-server ########################################### [100%]
2015-08-03 02:39:55 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use –explicit_defaults_for_timestamp server option (see documentation for more details).
2015-08-03 02:39:55 0 [Note] /usr/sbin/mysqld (mysqld 5.6.24) starting as process 8919 …
2015-08-03 02:39:55 8919 [Note] InnoDB: Using atomics to ref count buffer pool pages
2015-08-03 02:39:55 8919 [Note] InnoDB: The InnoDB memory heap is disabled
2015-08-03 02:39:55 8919 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2015-08-03 02:39:55 8919 [Note] InnoDB: Memory barrier is not used
2015-08-03 02:39:55 8919 [Note] InnoDB: Compressed tables use zlib 1.2.3
2015-08-03 02:39:55 8919 [Note] InnoDB: Using Linux native AIO
2015-08-03 02:39:55 8919 [Note] InnoDB: Using CPU crc32 instructions
2015-08-03 02:39:55 8919 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2015-08-03 02:39:55 8919 [Note] InnoDB: Completed initialization of buffer pool
2015-08-03 02:39:55 8919 [Note] InnoDB: The first specified data file ./ibdata1 did not exist: a new database to be created!
2015-08-03 02:39:55 8919 [Note] InnoDB: Setting file ./ibdata1 size to 12 MB
2015-08-03 02:39:55 8919 [Note] InnoDB: Database physically writes the file full: wait…
2015-08-03 02:39:55 8919 [Note] InnoDB: Setting log file ./ib_logfile101 size to 48 MB
2015-08-03 02:39:56 8919 [Note] InnoDB: Setting log file ./ib_logfile1 size to 48 MB
2015-08-03 02:39:56 8919 [Note] InnoDB: Renaming log file ./ib_logfile101 to ./ib_logfile0
2015-08-03 02:39:56 8919 [Warning] InnoDB: New log files created, LSN=45781
2015-08-03 02:39:56 8919 [Note] InnoDB: Doublewrite buffer not found: creating new
2015-08-03 02:39:56 8919 [Note] InnoDB: Doublewrite buffer created
2015-08-03 02:39:56 8919 [Note] InnoDB: 128 rollback segment(s) are active.
2015-08-03 02:39:56 8919 [Warning] InnoDB: Creating foreign key constraint system tables.
2015-08-03 02:39:56 8919 [Note] InnoDB: Foreign key constraint system tables created
2015-08-03 02:39:56 8919 [Note] InnoDB: Creating tablespace and datafile system tables.
2015-08-03 02:39:56 8919 [Note] InnoDB: Tablespace and datafile system tables created.
2015-08-03 02:39:56 8919 [Note] InnoDB: Waiting for purge to start
2015-08-03 02:39:56 8919 [Note] InnoDB: 5.6.24 started; log sequence number 0
A random root password has been set. You will find it in ‘/root/.mysql_secret’.
2015-08-03 02:39:57 8919 [Note] Binlog end
2015-08-03 02:39:57 8919 [Note] InnoDB: FTS optimize thread exiting.
2015-08-03 02:39:57 8919 [Note] InnoDB: Starting shutdown…
2015-08-03 02:39:58 8919 [Note] InnoDB: Shutdown completed; log sequence number 1625977
2015-08-03 02:39:58 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use –explicit_defaults_for_timestamp server option (see documentation for more details).
2015-08-03 02:39:58 0 [Note] /usr/sbin/mysqld (mysqld 5.6.24) starting as process 8941 …
2015-08-03 02:39:58 8941 [Note] InnoDB: Using atomics to ref count buffer pool pages
2015-08-03 02:39:58 8941 [Note] InnoDB: The InnoDB memory heap is disabled
2015-08-03 02:39:58 8941 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2015-08-03 02:39:58 8941 [Note] InnoDB: Memory barrier is not used
2015-08-03 02:39:58 8941 [Note] InnoDB: Compressed tables use zlib 1.2.3
2015-08-03 02:39:58 8941 [Note] InnoDB: Using Linux native AIO
2015-08-03 02:39:58 8941 [Note] InnoDB: Using CPU crc32 instructions
2015-08-03 02:39:58 8941 [Note] InnoDB: Initializing buffer pool, size = 128.0M
2015-08-03 02:39:58 8941 [Note] InnoDB: Completed initialization of buffer pool
2015-08-03 02:39:58 8941 [Note] InnoDB: Highest supported file format is Barracuda.
2015-08-03 02:39:58 8941 [Note] InnoDB: 128 rollback segment(s) are active.
2015-08-03 02:39:58 8941 [Note] InnoDB: Waiting for purge to start
2015-08-03 02:39:58 8941 [Note] InnoDB: 5.6.24 started; log sequence number 1625977
2015-08-03 02:39:58 8941 [Note] Binlog end
2015-08-03 02:39:58 8941 [Note] InnoDB: FTS optimize thread exiting.
2015-08-03 02:39:58 8941 [Note] InnoDB: Starting shutdown…
2015-08-03 02:40:00 8941 [Note] InnoDB: Shutdown completed; log sequence number 1625987
A RANDOM PASSWORD HAS BEEN SET FOR THE MySQL root USER !
You will find that password in ‘/root/.mysql_secret’.
You must change that password on your first connect,
no other statement but ‘SET PASSWORD’ will be accepted.
See the manual for the semantics of the ‘password expired’ flag.
Also, the account for the anonymous user has been removed.
In addition, you can run:
/usr/bin/mysql_secure_installation
which will also give you the option of removing the test database.
This is strongly recommended for production servers.
See the manual for more instructions.
Please report any problems at http://bugs.mysql.com/
The latest information about MySQL is available on the web at
http://www.mysql.com
Support MySQL by buying support/licenses at http://shop.mysql.com
New default config file was created as /usr/my.cnf and
will be used by default by the server when you start it.
You may edit this file to change server settings
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /memsql ] cat /root/.mysql_secret
# The random password set for the root user at Mon Aug 3 02:39:56 2015 (local time): VBlpJOO8RXkoCZKL
[ root @ dbversity1host: /memsql ]
[ root @ dbversity1host: /var/lib/data ] cat /etc/my.cnf
[mysqld]
port = 4000
datadir = /var/lib/data
[ root @ dbversity1host: /var/lib/data ]
[ mysql @ dbversity1host: /var/lib/data ] /etc/init.d/mysql start
Starting MySQL. SUCCESS!
[ mysql @ dbversity1host: /var/lib/data ]
[ mysql @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ] cat /root/.mysql_secret
# The random password set for the root user at Mon Aug 3 02:39:56 2015 (local time): VBlpJOO8RXkoCZKL
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ] mysql -u root -p”VBlpJOO8RXkoCZKL” -P 4000
Warning: Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 2
Server version: 5.6.24
Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.
mysql>
[ root @ dbversity1host: /var/lib/data ] /usr/bin/mysql_secure_installation
NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL
SERVERS IN PRODUCTION USE! PLEASE READ EACH STEP CAREFULLY!
In order to log into MySQL to secure it, we’ll need the current
password for the root user. If you’ve just installed MySQL, and
you haven’t set the root password yet, the password will be blank,
so you should just press enter here.
Enter current password for root (enter for none):
OK, successfully used password, moving on…
Setting the root password ensures that nobody can log into the MySQL
root user without the proper authorisation.
You already have a root password set, so you can safely answer ‘n’.
Change the root password? [Y/n] Y
New password:
Re-enter new password:
Password updated successfully!
Reloading privilege tables..
… Success!
By default, a MySQL installation has an anonymous user, allowing anyone
to log into MySQL without having to have a user account created for
them. This is intended only for testing, and to make the installation
go a bit smoother. You should remove them before moving into a
production environment.
Remove anonymous users? [Y/n] Y
… Success!
Normally, root should only be allowed to connect from ‘localhost’. This
ensures that someone cannot guess at the root password from the network.
Disallow root login remotely? [Y/n] n
… skipping.
By default, MySQL comes with a database named ‘test’ that anyone can
access. This is also intended only for testing, and should be removed
before moving into a production environment.
Remove test database and access to it? [Y/n] n
… skipping.
Reloading the privilege tables will ensure that all changes made so far
will take effect immediately.
Reload privilege tables now? [Y/n] Y
… Success!
All done! If you’ve completed all of the above steps, your MySQL
installation should now be secure.
Thanks for using MySQL!
Cleaning up…
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ] mysql -u root -p -P 4000
Enter password:
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 12
Server version: 5.6.24 MySQL Community Server (GPL)
Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.
mysql>
mysql>
mysql>
[ root @ dbversity1host: /var/lib/data ] mysql -u root -h dbversity1host-P 3306 –prompt=”memsql> “
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 8
Server version: 5.5.8 MemSQL source distribution (compatible; MySQL Enterprise & MySQL Commercial)
Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.
memsql>
memsql>
memsql>
memsql>
Bye
[ root @ dbversity1host: /var/lib/data ] netstat -nlp | grep memsql
tcp 0 0 0.0.0.0:9000 0.0.0.0:* LISTEN 13244/memsql-ops
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 8206/memsqld
tcp 0 0 0.0.0.0:3307 0.0.0.0:* LISTEN 8207/memsqld
unix 2 [ ACC ] STREAM LISTENING 5749926 8210/memsqld @memsql_commandproc_8210
unix 2 [ ACC ] STREAM LISTENING 5749930 8212/memsqld @memsql_commandproc_8212
unix 2 [ ACC ] STREAM LISTENING 5750230 8207/memsqld memsql.sock
unix 2 [ ACC ] STREAM LISTENING 5750240 8206/memsqld memsql.sock
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ]
[ root @ dbversity1host: /var/lib/data ] mysql -u root -h dbversity1host-P 3306 –prompt=”memsql> “
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 9
Server version: 5.5.8 MemSQL source distribution (compatible; MySQL Enterprise & MySQL Commercial)
Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.
memsql>
memsql>
memsql>
memsql> show databases;
+——————–+
| Database |
+——————–+
| information_schema |
| memsql |
| sharding |
+——————–+
3 rows in set (0.00 sec)
memsql> select * from information_schema.processlist where info is not null;
+—-+————-+———————————–+———-+———+——+———–+———————————————————————+———+——————-+—————-+———————-+——-+
| ID | USER | HOST | DB | COMMAND | TIME | STATE | INFO | PLAN_ID | TRANSACTION_STATE | ROW_LOCKS_HELD | PARTITION_LOCKS_HELD | EPOCH |
+—-+————-+———————————–+———-+———+——+———–+———————————————————————+———+——————-+—————-+———————-+——-+
| 9 | root | vm-16af-8253.nam.nsroot.net:54733 | NULL | Query | 3 | executing | select * from information_schema.processlist where info is not null | 0 | NULL | 0 | 0 | 55623 |
| 2 | distributed | vm-16af-8253.nam.nsroot.net:23501 | sharding | Query | 1739 | | MEMSQL REPLICATION START | NULL | NULL | 0 | 0 | NULL |
+—-+————-+———————————–+———-+———+——+———–+———————————————————————+———+——————-+—————-+———————-+——-+
2 rows in set (3.01 sec)
memsql> show aggregators;
+———–+——+——–+——————–+——————————+——————-+
| Host | Port | State | Opened_Connections | Average_Roundtrip_Latency_ms | Master_Aggregator |
+———–+——+——–+——————–+——————————+——————-+
| 127.0.0.1 | 3306 | online | 0 | NULL | 1 |
+———–+——+——–+——————–+——————————+——————-+
1 row in set (0.00 sec)
memsql>
memsql>
memsql> SHOW REPLICATION STATUS;
+——–+———-+———–+—————-+——————————+———–+—————–+————-+—————-+—————+————–+
| Role | Database | MasterURI | MasterPosition | SlaveURI | Connected | NetworkPosition | SlaveState | ReplayPosition | MasterCommits | SlaveCommits |
+——–+———-+———–+—————-+——————————+———–+—————–+————-+—————-+—————+————–+
| master | sharding | NULL | 0:208 | 10.116.161.138:3307/sharding | yes | 0:208 | replicating | 0:208 | 3 | 3 |
+——–+———-+———–+—————-+——————————+———–+—————–+————-+—————-+—————+————–+
1 row in set (0.00 sec)
memsql>
memsql>
memsql> select * from information_schema.processlist where info is not null order by time desc;
+—-+————-+———————————–+———-+———+——+———–+—————————————————————————————-+———+——————-+—————-+———————-+——-+
| ID | USER | HOST | DB | COMMAND | TIME | STATE | INFO | PLAN_ID | TRANSACTION_STATE | ROW_LOCKS_HELD | PARTITION_LOCKS_HELD | EPOCH |
+—-+————-+———————————–+———-+———+——+———–+—————————————————————————————-+———+——————-+—————-+———————-+——-+
| 2 | distributed | vm-16af-8253.nam.nsroot.net:23501 | sharding | Query | 1780 | | MEMSQL REPLICATION START | NULL | NULL | 0 | 0 | NULL |
| 9 | root | vm-16af-8253.nam.nsroot.net:54733 | NULL | Query | 2 | executing | select * from information_schema.processlist where info is not null order by time desc | 1 | NULL | 0 | 0 | 57212 |
+—-+————-+———————————–+———-+———+——+———–+—————————————————————————————-+———+——————-+—————-+———————-+——-+
2 rows in set (2.82 sec)
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql>
memsql> SHOW STATUS;
+————————————-+———————————-+
| Variable_name | Value |
+————————————-+———————————-+
| Aborted_clients | 1 |
| Aborted_connects | 0 |
| Bytes_received | 889947 |
| Bytes_sent | 14191945 |
| Connections | 9 |
| Max_used_connections | 5 |
| Queries | 16859 |
| Questions | 16859 |
| Threads_cached | 0 |
| Threads_connected | 5 |
| Threads_created | 5 |
| Threads_running | 2 |
| Uptime | 1796 |
| Aggregator_id | 1 |
| Seconds_until_expiration | 221331 |
| License_key | 65525960351a46189c7c54e8c9e00fe6 |
| License_type | enterprise |
| Maximum_cluster_capacity | 18446744073709551615 MB |
| Used_cluster_capacity | 15744 MB |
| Query_compilations | 2 |
| Query_compilation_failures | 0 |
| GCed_versions_last_sweep | 0 |
| Average_garbage_collection_duration | 0 ms |
| Total_server_memory | 151.0 MB |
| Loaded_plans_virtual_memory | 2.0 MB |
| Malloc_active_memory | 363.4 MB |
| Malloc_cumulative_memory | 380.8 (+0.0) MB |
| Alloc_variable_cached_buffers | 0.1 MB |
| Ssl_accept_renegotiates | 0 |
| Ssl_accepts | 0 |
| Ssl_callback_cache_hits | 0 |
| Ssl_client_connects | 0 |
| Ssl_connect_renegotiates | 0 |
| Ssl_ctx_verify_depth | 18446744073709551615 |
| Ssl_ctx_verify_mode | 0 |
| Ssl_default_timeout | 0 |
| Ssl_finished_accepts | 0 |
| Ssl_finished_connects | 0 |
| Ssl_session_cache_hits | 0 |
| Ssl_session_cache_misses | 0 |
| Ssl_session_cache_overflows | 0 |
| Ssl_session_cache_size | 20480 |
| Ssl_session_cache_timeouts | 0 |
| Ssl_sessions_reused | 0 |
| Ssl_used_session_cache_entries | 0 |
| Ssl_verify_depth | 0 |
| Ssl_verify_mode | 0 |
| Ssl_cipher | |
| Ssl_cipher_list | |
| Ssl_version | |
| Ssl_session_cache_mode | SERVER |
+————————————-+———————————-+
51 rows in set (0.00 sec)
memsql>
memsql>
memsql>
memsql>
memsql> SELECT @@GLOBAL.redundancy_level;
+—————————+
| @@GLOBAL.redundancy_level |
+—————————+
| 1 |
+—————————+
1 row in set (0.00 sec)
memsql>
memsql>
memsql> SHOW REBALANCE STATUS ON db ;
ERROR 1049 (42000): Unknown database ‘db’
memsql>
memsql>
memsql>
memsql>
memsql>
memsql> SHOW LEAVES;
+—————-+——+——————–+———–+———–+——–+——————–+——————————+
| Host | Port | Availability_Group | Pair_Host | Pair_Port | State | Opened_Connections | Average_Roundtrip_Latency_ms |
+—————-+——+——————–+———–+———–+——–+——————–+——————————+
| 10.116.161.138 | 3307 | 1 | NULL | NULL | online | 1 | 0.338 |
+—————-+——+——————–+———–+———–+——–+——————–+——————————+
1 row in set (0.00 sec)
memsql>
memsql>
memsql> SHOW AGGREGATORS;
+———–+——+——–+——————–+——————————+——————-+
| Host | Port | State | Opened_Connections | Average_Roundtrip_Latency_ms | Master_Aggregator |
+———–+——+——–+——————–+——————————+——————-+
| 127.0.0.1 | 3306 | online | 0 | NULL | 1 |
+———–+——+——–+——————–+——————————+——————-+
1 row in set (0.00 sec)