Connection refused when restoring db over ssh

Hello InfluxDB Community,

I am having issues restoring an InfluxDB database on a headless Raspberry Pi 3B+ (with Raspbian Buster) over SSH from a PC on the same network. The backup was made a day ago over SSH on the same system and OS without any issues.

When typing the command:
sudo influxd restore -portable /var/lib/openhab2/backups/influxdb/

I get the error:

2020/05/30 15:33:55 error updating meta: dial tcp [::1]:8088: connect: connection refused
restore: dial tcp [::1]:8088: connect: connection refused

Before issuing the restore command I stopped the influxdb service (sudo systemctl stop influxdb) and checked the status to ensure it is not running. Also, changing the bind address in the .config file to bind-address = ":8088" as suggested in this post did not help.

Very grateful for any help, I have searched for hours without success.

Solved by restoring through a terminal in VNC Viewer. Not ideal as I had to install the whole Raspbian UI but at least the data is there.