Home › Forums › FABRIC General Questions and Discussion › Not able to execute commands: Error-Authentication failed
- This topic has 4 replies, 2 voices, and was last updated 7 months, 2 weeks ago by Manas Das.
-
AuthorPosts
-
April 11, 2024 at 10:06 pm #6912
Hello Fabric Team,
When trying to execute commands at various nodes in the slice I am getting this error:
Exception: Authentication failed. The code is:
try:
for node in slice.get_nodes():
stdout, stderr = node.execute(‘ls /home/ubuntu’) [just an example nothing works]
print(stdout)
print(stderr)except Exception as e:
print(f”Exception: {e}”)Also not able to print the slice interfaces (slice.list_interfaces())
I am using FabLib 1.6.1. My Slice ID is: bbee268d-dbce-4258-b5ad-08837ef84f12
Any help is appreciated
Thanks
April 11, 2024 at 10:12 pm #6913Hi Manas,
This typically happens when either your bastion keys are expired or sliver keys used by fablib don’t match the keys inside the slivers.
Could you please run this notebook:
jupyter-examples-rel1.6.1/configure_and_validate.ipynb
to ensure your config is valid and if bastion keys are expired they are regenerated?Please try list/show on your slice after that and let us know if you still face the problem.
P.S: Verified that all your VMs are accessible via SSH.
Thanks,
Komal
- This reply was modified 7 months, 2 weeks ago by Komal Thareja.
April 11, 2024 at 10:33 pm #6915Hello Komal,
Thank you for the quick response. I followed your instructions and it is working now. But I have a few questions.
- I have recently changed the bastion key, so I don’t get why the key expired.
- I am able to ssh into the node, but the bastion key I have in my laptop (local) is different from the bastion key in the Jupyter hub.
- Is multiple bastion keys possible?
- How to check the expiration date of the bastion key in my Jupyter hub, I know how to check the expiration date of the bastion key that I use to ssh into the node from my local machine.
Once again thank you for the swift response.
Regards
Manas
April 11, 2024 at 10:38 pm #6916Hi Manas,
Glad to hear the issue is resolved. Please find my responses inline below.
- I have recently changed the bastion key, so I don’t get why the key expired.
[KT] Could you please share how this was done? Please note if the bastion keys are re-created via portal, user is responsible to upload them to JH.
- I am able to ssh into the node, but the bastion key I have in my laptop (local) is different from the bastion key in the Jupyter hub.
[KT] This should not be an issue. Users can have multiple bastion keys.
- Is multiple bastion keys possible?
[KT] Yes, this not an issue.
- How to check the expiration date of the bastion key in my Jupyter hub, I know how to check the expiration date of the bastion key that I use to ssh into the node from my local machine.
[KT] You can check the bastion key expiry on the portal or run the
validate_and_configure.ipynb
to validate/update your config as needed.Hope this helps!
Thanks,
Komal
April 11, 2024 at 11:21 pm #6917Hello Komal,
I have created the bastion key in the portal and downloaded it to my local machine, but I think I have not uploaded it into Jupyter Hub. Thank you for clarifying everything.
Regards,
Manas
-
AuthorPosts
- You must be logged in to reply to this topic.