"There are no available volumes" error when trying to add a public ssh key

Questions about SNMP, Power, System, Logs, disk, & RAID.
Post Reply
donttakeanap
New here
Posts: 2
Joined: Sun Jun 04, 2023 7:49 pm

"There are no available volumes" error when trying to add a public ssh key

Post by donttakeanap »

I can ssh into my TS-453D using my password, but I'd like to place my public ssh key on the nas so I can do without the password.

Now when I hit "Add" in Control Panel / Privilege / Users / username / Options / SSH Keys, I get the error

"There are no available volumes to save the key. Go to Storage & Snapshots to create a volume."

I do have a volume, to be precise: One "Static Volume". It is marked "Ready", and it actually works. It takes up all disk space of the 2 disks, so I couldn't even create a new volume even if I tried to. And why should I? I already have a working volume.

How can this be fixed?

Some more background information that seems related and may perhaps be helpful:
Directly after ssh-ing into the nas, I get a "Could not chdir to home directory" error. See the following session.

Code: Select all

> ssh username@qnap-ts-453d.local
username@qnap-ts-453d.local's password: 
Could not chdir to home directory /share/homes/username: No such file or directory
[username@QNAP-TS-453D /]$ ls /share/homes/     
/bin/ls: cannot access /share/homes/: No such file or directory
[username@QNAP-TS-453D /]$ ls /share/
CE_CACHEDEV1_DATA/  HDB_DATA/  HDE_DATA/  HDH_DATA/  HDK_DATA/  HDN_DATA/  HDQ_DATA/  HDT_DATA/  HDW_DATA/  HDZ_DATA/    Public@
...
So /share exists, but /share/homes does not. Now I can create /share/homes/username/.ssh and put my public key there, but the folder will be gone after the next reboot.
User avatar
dolbyman
Guru
Posts: 35275
Joined: Sat Feb 12, 2011 2:11 am
Location: Vancouver BC , Canada

Re: "There are no available volumes" error when trying to add a public ssh key

Post by dolbyman »

If you have a volume with the default shares ('homes is "one" of them) and it does not work, open a ticket with QNAP support

Also why user keys ? Just add keys top right under the admin options.
donttakeanap
New here
Posts: 2
Joined: Sun Jun 04, 2023 7:49 pm

Re: "There are no available volumes" error when trying to add a public ssh key

Post by donttakeanap »

Thanks dolbyman. I didn't know about "default shares", so this was very helpful.

I tried to do
Control Panel / Privilege / Shared Folders / "Others" button / Restore Default Shared Folders
but got the error "System default shares have already existed, or the disk volume is not formatted or unmounted."

Next I just tried to create a "homes" share manually. Now the funny thing was that in the folder dropdown list, there already was a /homes/username/.ssh/authorized_keys containing the keys that I had manually copied there via scp months ago, after creating the shares/homes folder manually via ssh.

Long story short, after creating the homes share manually, and setting the folder to /homes, my old manual folder reappeared (wherever it had been all those months...), and all is good now, including reboots.

So thanks for pointing me in the right direction!
Post Reply

Return to “System & Disk Volume Management”