未找到 juju 环境,无法引导

未找到 juju 环境,无法引导

我在 Ubuntu 15.04 上安装了 juju,并且已经使用了几天。我设法让它与 Amazon EC2 实例一起启动并运行,这很有趣。我再次尝试在 EC2 上启动几个实例,但整个过程似乎都挂起了。Juju 没有返回任何内容,并且实例尚未在 EC2 中启动。但是,在我按 ctrl+c 完成该过程后,我现在无法对 Amazon 环境执行任何操作。尝试引导:

brian@tonk:~$ juju bootstrap
WARNING ignoring environments.yaml: using bootstrap config in file "/home/brian/.juju/environments/amazon.jenv"
WARNING This juju environment is already bootstrapped. If you want to start a new Juju environment, first run juju destroy-environment to clean up, or switch to an alternative environment.
ERROR environment is already bootstrapped

它说它已经引导了。但是,我无法销毁引导程序。

brian@tonk:~$ juju -v destroy-environment amazon
WARNING environment not found, removing config file environment not found, removing config file

所以我尝试删除环境和 ssh 文件夹

brian@tonk:~$ rm -R .juju/environments
brian@tonk:~$ rm -R .juju/ssh
brian@tonk:~$ ls .juju/
environments.yaml  environments.yaml.backup  id_rsa  id_rsa.pub  local

然后再次尝试引导:

brian@tonk:~$ juju bootstrap
WARNING This juju environment is already bootstrapped. If you want to start a new Juju environment, first run juju destroy-environment to clean up, or switch to an alternative environment.
ERROR environment is already bootstrapped

还是没有效果。然后我尝试了状态:

brian@tonk:~$ juju status
ERROR Unable to connect to environment "amazon".
Please check your credentials or use 'juju bootstrap' to create a new environment.

Error details:
instances not found

所以,我现在有点不知所措。juju 显然存储了“某物”...“某处”。知道在哪里吗,这样我就可以删除引用,这样我就可以重新启动 AWS EC2。:)

提前谢谢大家。:)

答案1

它可能在 s3 控制存储桶中找到它。尝试以下操作:

juju destroy-environment amazon --force

答案2

如果手动部署并且作为最后的手段(Ubuntu1804,juju 2.6.8)

清理控制节点

sudo rm -rf /var/lib/juju

sudo rm -rf /lib/systemd/system/juju*

sudo rm -rf /run/systemd/units/invocation:juju*

sudo rm -rf /etc/systemd/system/juju*

相关内容