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

API service at '10.20.0.1' using the 'http' protocol at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 389. #183

Open
PBoerst opened this issue Mar 22, 2024 · 17 comments
Assignees
Labels
Diagnose Diagnose/Discuss a issue or concern Question Further information is requested wontfix This will not be worked on

Comments

@PBoerst
Copy link

PBoerst commented Mar 22, 2024

I'm having this issue above, I'm not sure where to go next, I've been at this for about 25 hours.
If there is anything you need me to provide please let me know.
I also receive this when trying to delete a vm disk
()
Unable to connect to the FreeNAS API service at '10.20.0.1' using the 'http' protocol at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 389. (500)

@TheGrandWazoo
Copy link
Owner

TheGrandWazoo commented Mar 22, 2024

What version of TrueNAS?
Might you have the config for Proxmox ZFS over iSCSI?
Post syslog info from the start to the failure.

@TheGrandWazoo TheGrandWazoo self-assigned this Mar 22, 2024
@TheGrandWazoo TheGrandWazoo added Question Further information is requested Diagnose Diagnose/Discuss a issue or concern labels Mar 22, 2024
@PBoerst
Copy link
Author

PBoerst commented Mar 22, 2024

TrueNAS-12.0-U6.1 Core
Mar 22 13:06:01 hmlhst5 pvedaemon[123450]: <root@pam> starting task UPID:hmlhst5:0001E93F:004C32C0:65FDBA79:qmcreate:102:root@pam: Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::run_lun_command : create_lu(/dev/zvol/ProxStore/vm-102-disk-10) Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_check : called Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : called Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Authentication using Bearer Token Auth Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : REST connection header Content-Type:'text/html' Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Changing to v2.0 API's Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : called Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Authentication using Bearer Token Auth Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : REST connection header Content-Type:'text/plain; charset=utf-8' Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: [ERROR]FreeNAS::API::PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Response code: 401 Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: [ERROR]FreeNAS::API::PVE::Storage::LunCmd::FreeNAS::freenas_api_connect : Response content: 401: Unauthorized Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: VM 102 creating disks failed Mar 22 13:06:02 hmlhst5 pvedaemon[125247]: unable to create VM 102 - Unable to connect to the FreeNAS API service at '10.20.0.1' using the 'http' protocol at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 389. Mar 22 13:06:02 hmlhst5 pvedaemon[123450]: <root@pam> end task UPID:hmlhst5:0001E93F:004C32C0:65FDBA79:qmcreate:102:root@pam: unable to create VM 102 - Unable to connect to the FreeNAS API service at '10.20.0.1' using the 'http' protocol at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 389. Logs
I noticed it says using Bearer Auth token, should it be basic as I'm using root user and pw?

@TheGrandWazoo
Copy link
Owner

What branch of the plugin are you using...testing or stable?

@PBoerst
Copy link
Author

PBoerst commented Mar 22, 2024

I believe I was using stable, but at this point I really cannot remember.

@TheGrandWazoo
Copy link
Owner

Look at your repo in Proxmox and it should tell you there.

image
In yellow is the 'testing' repo. The one above without a checkmark is 'stable'

@PBoerst
Copy link
Author

PBoerst commented Mar 22, 2024

image

Not sure how, but looks like both?

@TheGrandWazoo
Copy link
Owner

The 'testing' repo has the Bearer Token auth feature so no more User/Password is needed on newer TrueNAS version.

@TheGrandWazoo
Copy link
Owner

Only select "ONE" repo.

@PBoerst
Copy link
Author

PBoerst commented Mar 22, 2024

I'm sorry, I'm not really too sure what I should do from here to fix this.
I'm kind of a beginner at this, and learning how this all works is kind of a 2 week goal for myself.

@TheGrandWazoo
Copy link
Owner

Click on the "stable" repo and a few button will appear below "APT Repositories". One should be disable.
The after that is complete refresh and see if it picks up the 'testing' repo and hopefully it will have an update.

@TheGrandWazoo
Copy link
Owner

I selected the 'testing' repo on mine but this is just to show you.

image

@TheGrandWazoo
Copy link
Owner

TheGrandWazoo commented Mar 22, 2024

I'll be back. Off to my real job for awhile.

@PBoerst
Copy link
Author

PBoerst commented Mar 22, 2024

I'm trying to set this up on TrueNAS Scale now instead, most recent stable version.
I receive this TASK ERROR: unable to create VM 102 - Undefined freenas_userand/orfreenas_password variables. at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 136.
so if I edit /etc/pve/storage.cfg, and remove 'truenas_secret' and replace it with 'freenas_password'
The error changes to this
'Use of uninitialized value in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 349.
Use of uninitialized value in concatenation (.) or string at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 349.
TASK ERROR: unable to create VM 102 - Unable to connect to the FreeNAS API service at '10.20.0.1' using the 'http' protocol at /usr/share/perl5/PVE/Storage/LunCmd/FreeNAS.pm line 389'
What am I doing wrong here?

@TheGrandWazoo
Copy link
Owner

Send me that snip of the config in the /etc/pve/storage.cfg and, or course, remove/change
the secret and/or ip/dns values when posting.

@PBoerst
Copy link
Author

PBoerst commented Mar 23, 2024

Send me that snip of the config in the /etc/pve/storage.cfg and, or course, remove/change the secret and/or ip/dns values when posting.

So the Raid 1 boot drives both failed in this proxmox host last night. Brand new custom server build less than a week old.
I picked up 2 new drives and got Truenas reinstalled for good measure and got proxmox back up on this host.
I will be attempting this again tonight or tomorrow.
Could you link me to the most recent instructions on install? I think I followed half of 2 different things on the first install

@TheGrandWazoo
Copy link
Owner

Copy link

stale bot commented May 22, 2024

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix This will not be worked on label May 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Diagnose Diagnose/Discuss a issue or concern Question Further information is requested wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants