ipsan server base on linux IPSAN web api modules:
-
System settings(apisystem) 1.1) View system information 1.2) Datetime setting 1.3) Reboot & Shutdown
-
Network setting(apisystem) 2.1) IP Address, Gateway, Route
-
User Management(apiuser) 3.1) Add/Delete/Update user
-
RAID Management(apiarray) 4.1) View RAID 4.2) Create RAID (0, 1, 5,6,10)
-
Storage Management(apilvm, apivg) 5.1) Volume group management(apivg). Add/Delete volume group 5.2) LVM Management(apilvm), Add/Delete/Update LVM
-
SAN Management 6.1) ISCSI Target Management. Add/Delete target. Modify target name.
-
Mantance/Update(apisystem, apievent) 7.1) Software upgrade. support upload files to upgrade 7.2) Event log
IPSAN api provide HTTP API. JSON fomatted data
Response success: { "retcode": 0 .... }
Response failure: { "retcode": 400, "message": "add user failure" }
Success: retcode=0 Failure: retcode != 0. message member store failure reason.
IPSAN Server Dependency:
= python3 aiohttp: http server supervisor: unix process control nginx: web/proxy server
Install:
-
$ zypper in python-pip
-
$ pip install supervisor --pre or $ pip install supervisor or $ easy_setup supervisor
-
config supervisor
$ echo_supervisord_conf > /etc/supervisord.conf
-
chkconfig supervisord on
-
install aiohttp $ pip3 install aiohttp or $ easy_setup aiohttp
-
nginx Suse: $ zypper in nginx $ chkconfig nginx on $ chkconfig nginx start
$ vim /etc/nginx/nginx.conf #nginx server configuration $ mkdir -p /etc/nginx/vhosts.d $ cd /et/nginx/vhosts-d $ vim sanweb.conf serrver { listen 80; server_name localhost;
location / { root /srv/san/sanweb; index index.html; }
} $ nginx -s reload
Ubuntu:
$ apt-get install nginx
$ vim /etc/nginx/sites-available/default
server {
listen 80;
server_name localhost;
location / {
root /srv/san/sanweb;
index index.html;
}
}
$ nginx -s reload