Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow either MySQLdb and PyMySQL and add -s/--socket option #1

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 26 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,29 @@
Introduction
============

Proxytop is a self contained real time monitoring tool for ProxySQL, a high performance,
high availability, protocol aware proxy for MySQL and forks (like Percona Server and MariaDB).
Proxytop is a self contained real time monitoring tool for ProxySQL, a high performance,
high availability, protocol aware proxy for MySQL and forks (like Percona Server and MariaDB).

### How to install:

Proxytop works with either MySQL-python (MySQLdb), which is attempted first, or PyMySQL. For
MySQLdb, you may first need to install system Python and MySQL dev packages, followed by
MySQL-python. E.g.:
```
## You may first need to install system Python and MySQL dev packages
## e.g. "sudo apt install python-dev libmysqlclient-dev"
pip install MySQL-python npyscreen
sudo apt install python-dev libmysqlclient-dev
pip install MySQL-python
```

PyMySQL is simply:
```
pip install PyMySQL
```

Finally, install npyscreen (used for the interface) and proxytop itself:
```
pip install npyscreen
wget -P /usr/bin https://raw.githubusercontent.com/sysown/proxytop/master/proxytop
# or curl -o /usr/bin/proxytop https://raw.githubusercontent.com/sysown/proxytop/master/proxytop
```

### How to run:
Expand All @@ -22,15 +35,18 @@ $ proxytop

The script supports connecting to a non-default confication using command line parameters:
```
usage: proxytop [-h] [-H HOST] [-P PORT] [-u USER] [-p PASSWORD] [-f DFILE]
usage: proxytop [-h] [-H HOST] [-P PORT] [-s SOCKET] [-u USER] [-p PASSWORD]
[-f DFILE]

optional arguments:
-h, --help show this help message and exit
-H HOST, --host HOST ProxySQL hostname / IP address (default=127.0.0.1)
-P PORT, --port PORT ProxySQL Admin port (default=6032)
-u USER, --user USER ProxySQL Admin username (default=admin)
-H HOST, --host HOST ProxySQL hostname / IP address
-P PORT, --port PORT ProxySQL Admin port
-s SOCKET, --socket SOCKET
ProxySQL Admin socket
-u USER, --user USER ProxySQL Admin username
-p PASSWORD, --password PASSWORD
ProxySQL Admin password (default=admin)
ProxySQL Admin password
-f DFILE, --dfile DFILE
Use the MySQL defaults file specified (expects a
[proxysqladmin] group)
Expand Down
Loading