{"action":"closed","issue":{"url":"https://api.github.com/repos/zstackorg/zstack/issues/185","labels_url":"https://api.github.com/repos/zstackorg/zstack/issues/185/labels{/name}","comments_url":"https://api.github.com/repos/zstackorg/zstack/issues/185/comments","events_url":"https://api.github.com/repos/zstackorg/zstack/issues/185/events","html_url":"https://github.com/zstackorg/zstack/issues/185","id":124063468,"number":185,"title":"cannot add the localhost after deleting the /usr/local/zstack, then re-install","user":{"login":"lstfyt","id":10667305,"avatar_url":"https://avatars.githubusercontent.com/u/10667305?v=3","gravatar_id":"","url":"https://api.github.com/users/lstfyt","html_url":"https://github.com/lstfyt","followers_url":"https://api.github.com/users/lstfyt/followers","following_url":"https://api.github.com/users/lstfyt/following{/other_user}","gists_url":"https://api.github.com/users/lstfyt/gists{/gist_id}","starred_url":"https://api.github.com/users/lstfyt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lstfyt/subscriptions","organizations_url":"https://api.github.com/users/lstfyt/orgs","repos_url":"https://api.github.com/users/lstfyt/repos","events_url":"https://api.github.com/users/lstfyt/events{/privacy}","received_events_url":"https://api.github.com/users/lstfyt/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/zstackorg/zstack/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-12-28T12:44:50Z","updated_at":"2016-01-25T07:34:06Z","closed_at":"2016-01-25T07:34:06Z","body":"在升级系统过程中出错，接着强制删除/usr/local/zstack（期间服务正常运行）,接着重新安装zstack。\r\n在引导配置界面中，添加安装zstack的本地节点，出现下以下错误。\r\n如果添加另外机器，则添加成功。\r\n\r\nerror info in UI:\r\n  \"details\": \"unhandled exception happened when calling private void org.zstack.core.ansible.AnsibleFacadeImpl.1.run(org.zstack.header.core.Completion), \\nshell command[sudo ansible-playbook /usr/local/zstack/ansible/kvm.yaml -i /usr/local/zstack/ansible/hosts --private-key /usr/local/zstack/apache-tomcat-7.0.35/webapps/zstack/WEB-INF/classes/ansible/rsaKeys/id_rsa -e '{\\\"pip_url\\\":\\\"http://192.168.0.110:8080/zstack/static/pypi/simple\\\",\\\"host\\\":\\\"192.168.0.110\\\",\\\"zstack_root\\\":\\\"/var/lib/zstack/\\\",\\\"init\\\":\\\"true\\\",\\\"hostname\\\":\\\"192-168-0-110.zstack.org\\\",\\\"pkg_zstacklib\\\":\\\"zstacklib-0.9.tar.gz\\\",\\\"pkg_kvmagent\\\":\\\"kvmagent-0.9.tar.gz\\\",\\\"yum_server\\\":\\\"192.168.0.110:8080\\\",\\\"trusted_host\\\":\\\"192.168.0.110\\\"}'] failed\\nret code: 2\\nstderr: \\nstdout: \\nPLAY [192.168.0.110] ********************************************************** \\n\\nGATHERING FACTS *************************************************************** \\nok: [192.168.0.110]\\n\\nTASK: [state epel.repo] ******************************************************* \\nok: [192.168.0.110]\\n\\nTASK: [install libselinux-python, since next step might use it.] ************** \\nok: [192.168.0.110] => (item=libselinux-python)\\n\\nTASK: [install epel-release yum repo] ***************************************** \\nskipping: [192.168.0.110]\\n\\nTASK: [install epel-release] ************************************************** \\nskipping: [192.168.0.110]\\n\\nTASK: [enable epel repository] ************************************************ \\nok: [192.168.0.110]\\n\\nTASK: [set RHEL7 zstack local yum repo] *************************************** \\nskipping: [192.168.0.110]\\n\\nTASK: [set RHEL6 zstack local yum repo] *************************************** \\nskipping: [192.168.0.110]\\n\\nTASK: [set ALIYUN mirror yum repo] ******************************************** \\nskipping: [192.168.0.110]\\n\\nTASK: [set 163 mirror yum repo] *********************************************** \\nskipping: [192.168.0.110]\\n\\nTASK: [install libselinux-python and other command system libs from user defined repos] *** \\nskipping: [192.168.0.110]\\n\\nTASK: [install libselinux-python and other command system libs from system repos] *** \\nfailed: [192.168.0.110] => {\\\"changed\\\": true, \\\"cmd\\\": \\\"yum clean metadata && yum --nogpgcheck install -y libselinux-python python-devel python-setuptools python-pip gcc autoconf\\\", \\\"delta\\\": \\\"0:00:01.301394\\\", \\\"end\\\": \\\"2015-12-28 20:14:29.914879\\\", \\\"rc\\\": 1, \\\"start\\\": \\\"2015-12-28 20:14:28.613485\\\", \\\"warnings\\\": [\\\"Consider using yum module rather than running yum\\\"]}\\nstderr: Repository 'epel' is missing name in configuration, using id\\nRepository 'epel' is missing name in configuration, using id\\n\\n\\n One of the configured repositories failed (Unknown),\\n and yum doesn't have enough cached data to continue. At this point the only\\n safe thing yum can do is fail. There are a few ways to work \\\"fix\\\" this:\\n\\n     1. Contact the upstream for the repository and get them to fix the problem.\\n\\n     2. Reconfigure the baseurl/etc. for the repository, to point to a working\\n        upstream. This is most often useful if you are using a newer\\n        distribution release than is supported by the repository (and the\\n        packages for the previous distribution release still work).\\n\\n     3. Disable the repository, so yum won't use it by default. Yum will then\\n        just ignore the repository until you permanently enable it again or use\\n        --enablerepo for temporary usage:\\n\\n            yum-config-manager --disable <repoid>\\n\\n     4. Configure the failing repository to be skipped, if it is unavailable.\\n        Note that yum will try to contact the repo. when it runs most commands,\\n        so will have to try and fail each time (and thus. yum will be be much\\n        slower). If it is a very temporary problem though, this is often a nice\\n        compromise:\\n\\n            yum-config-manager --save --setopt=<repoid>.skip_if_unavailable=true\\n\\nCannot find a valid baseurl for repo: epel\\nstdout: Loaded plugins: fastestmirror\\nCleaning repos: base epel extras updates\\n1 metadata file removed\\n0 sqlite files removed\\n0 metadata files removed\\nLoaded plugins: fastestmirror\\n\\nFATAL: all hosts have already failed -- aborting\\n\""}}