QNAP monitoring
In case of usage of
Virtual Appliance
- Use local account lpar2rrd for hosting of STOR2RRD on the virtual appliance
- Use /home/stor2rrd/stor2rrd as the product home
The product obtains all data from QNAP Q'center via ssh.
Storage connectivity
-
Allow access from the STOR2RRD host to QNAP Q'center on ports 22 (SSH).
$ perl /home/stor2rrd/stor2rrd/bin/conntest.pl 192.168.1.1 22
Connection to "192.168.1.1" on port "22" is ok
-
Connect to the QNAP Q'center as admin and allow ssh access
- Create OS level user on the QNAP Q'center appliance, preferably stor2rrd with no any special rights
Log as admin to the QNAP Q'center appliance:
admin@qcenter:/home/admin$ sudo useradd -c "STOR2RRD user" -m stor2rrd
[sudo] password for admin:
admin@qcenter:/home/admin$ sudo passwd stor2rrd
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
- Exchange ssh keys to allow ssh-key based access
Create ssh-keys on STOR2RRD host under stor2rrd user if do not exist yet.
It should already exist on the Virtual Appliance, skip it there.
Type enter instead of passphrase
# su - stor2rrd # (use lpar2rrd user on the Appliance)
$ ls -l ~/.ssh/id_rsa.pub
$ ssh-keygen -t rsa -N ""
Generating public/private rsa key pair.
Enter file in which to save the key (/home/stor2rrd/.ssh/id_rsa):
...
$ ls -l ~/.ssh/id_rsa.pub
-rw-r--r-- 1 stor2rrd stor2rrd 382 Jun 1 12:47 /home/stor2rrd/.ssh/id_rsa.pub
- Copy ssh-key into the QNAP Q'center under storage stor2rrd
$ scp ~/.ssh/id_rsa.pub stor2rrd@<Q'center IP/hostname>:/tmp/id_rsa.pub
$ ssh stor2rrd@<Q'center IP/hostname>
stor2rrd@qcenter:/home/stor2rrd$ mkdir .ssh
stor2rrd@qcenter:/home/stor2rrd$ chmod 700 .ssh
stor2rrd@qcenter:/home/stor2rrd$ mv /tmp/id_rsa.pub .ssh/authorized_keys
- Test connectivity, you should not be prompted for password:
$ ssh stor2rrd@<Q'center IP/hostname> "date"
Mon May 25 23:30:01 CEST 2020
STOR2RRD storage configuration