[ZUN] Accessing the container commad Issue and Installing Zun-UI Issue

Anirudh Gupta anyrude10 at gmail.com
Wed Mar 27 07:39:18 UTC 2019


Note - Subject Changed

Hi Hongbin,

I am facing 2 issue in Zun Services

*Issue 1 : Accessing the Container giving 500 Internal Server Error*

When I am trying to access the container, using the command given in doc
openstack --debug appcontainer exec --interactive
c58c4c9d-6043-4501-8ef3-3ac587ab1481 /bin/sh

I am facing the below issue:


http://controller:9517 "POST
/v1/containers/c58c4c9d-6043-4501-8ef3-3ac587ab1481/execute_resize?h=43&exec_id=0cdca9d060fe17dc832be766f7fd41bda7a78ed9e401bffedfb0badc6a11f4a1&w=122
HTTP/1.1" 500 261
RESP: [500] Connection: keep-alive Content-Length: 261 Content-Type:
application/json Date: Wed, 27 Mar 2019 07:22:52 GMT
Openstack-Api-Maximum-Version: container 1.22
Openstack-Api-Minimum-Version: container 1.1 Openstack-Api-Version:
container 1.20 Vary: OpenStack-API-Version X-Openstack-Request-Id:
req-6dfefd40-3021-4c0f-a053-0f43952b661b
RESP BODY: {"errors": [{"status": 500, "code": "container.", "links": [],
"title": "Internal Server Error", "detail": "Your request could not be
handled because of a problem in the server. Error Correlation id is:
b2895347-0625-406f-b291-b8a5527b25ee", "request_id": ""}]}
POST call to container for
http://controller:9517/v1/containers/c58c4c9d-6043-4501-8ef3-3ac587ab1481/execute_resize?h=43&exec_id=0cdca9d060fe17dc832be766f7fd41bda7a78ed9e401bffedfb0badc6a11f4a1&w=122
used request id req-6dfefd40-3021-4c0f-a053-0f43952b661b
Internal Server Error (HTTP 500) (Request-ID:
req-6dfefd40-3021-4c0f-a053-0f43952b661b)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 400, in
run_subcommand
    result = cmd.run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/osc_lib/command/command.py", line
41, in run
    return super(Command, self).run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/cliff/command.py", line 184, in run
    return_code = self.take_action(parsed_args) or 0
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/osc/v1/containers.py",
line 537, in take_action
    websocketclient.do_exec(client, url, container, exec_id, "~", 0.5)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/websocketclient/websocketclient.py",
line 379, in do_exec
    wscls.handle_resize()
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/websocketclient/websocketclient.py",
line 196, in handle_resize
    self.tty_resize(height=rows, width=cols)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/websocketclient/websocketclient.py",
line 294, in tty_resize
    self.cs.containers.execute_resize(self.id, self.exec_id, width, height)
  File "/usr/local/lib/python2.7/dist-packages/zunclient/v1/containers.py",
line 165, in execute_resize
    qparams={'exec_id': exec_id, 'w': width, 'h': height})[1]
  File "/usr/local/lib/python2.7/dist-packages/zunclient/v1/containers.py",
line 128, in _action
    **kwargs)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/httpclient.py",
line 367, in json_request
    resp = self._http_request(url, method, **kwargs)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/httpclient.py",
line 350, in _http_request
    error_json.get('debuginfo'), method, url)
InternalServerError: Internal Server Error (HTTP 500) (Request-ID:
req-6dfefd40-3021-4c0f-a053-0f43952b661b)
clean_up ExecContainer: Internal Server Error (HTTP 500) (Request-ID:
req-6dfefd40-3021-4c0f-a053-0f43952b661b)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/osc_lib/shell.py", line 135, in run
    ret_val = super(OpenStackShell, self).run(argv)
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 279, in run
    result = self.run_subcommand(remainder)
  File "/usr/lib/python2.7/dist-packages/osc_lib/shell.py", line 175, in
run_subcommand
    ret_value = super(OpenStackShell, self).run_subcommand(argv)
  File "/usr/lib/python2.7/dist-packages/cliff/app.py", line 400, in
run_subcommand
    result = cmd.run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/osc_lib/command/command.py", line
41, in run
    return super(Command, self).run(parsed_args)
  File "/usr/lib/python2.7/dist-packages/cliff/command.py", line 184, in run
    return_code = self.take_action(parsed_args) or 0
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/osc/v1/containers.py",
line 537, in take_action
    websocketclient.do_exec(client, url, container, exec_id, "~", 0.5)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/websocketclient/websocketclient.py",
line 379, in do_exec
    wscls.handle_resize()
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/websocketclient/websocketclient.py",
line 196, in handle_resize
    self.tty_resize(height=rows, width=cols)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/websocketclient/websocketclient.py",
line 294, in tty_resize
    self.cs.containers.execute_resize(self.id, self.exec_id, width, height)
  File "/usr/local/lib/python2.7/dist-packages/zunclient/v1/containers.py",
line 165, in execute_resize
    qparams={'exec_id': exec_id, 'w': width, 'h': height})[1]
  File "/usr/local/lib/python2.7/dist-packages/zunclient/v1/containers.py",
line 128, in _action
    **kwargs)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/httpclient.py",
line 367, in json_request
    resp = self._http_request(url, method, **kwargs)
  File
"/usr/local/lib/python2.7/dist-packages/zunclient/common/httpclient.py",
line 350, in _http_request
    error_json.get('debuginfo'), method, url)
InternalServerError: Internal Server Error (HTTP 500) (Request-ID:
req-6dfefd40-3021-4c0f-a053-0f43952b661b)


*Issue 2: When trying to integrate ZUN-UI plugin, facing issue in opening
the Horizon page*

I have tried integrating Zun with Horizon, using the following link

https://docs.openstack.org/zun-ui/latest/install/index.html#manual-installation

But after integrating it and restarting my apache2 server,  my dashboard
page malfunctions. All the content in written in textual manner and I am
not able to open it.

Can you please suggest possible solutions to both my problems.

Thanks in advance

Regards
Anirudh Gupta



On Tue, Mar 26, 2019 at 1:22 PM Anirudh Gupta <anyrude10 at gmail.com> wrote:

> Hi Hongbin,
>
> Thanks for your prompt response.
>
> With this approach I am able to scale out and scale in my Zun Containers.
>
> Looking forward for the use of k8s in future.
>
> Regards
> Anirudh Gupta
>
> On Tue, Mar 26, 2019 at 9:39 AM Hongbin Lu <hongbin034 at gmail.com> wrote:
>
>> Hi Anirudh ,
>>
>> I am not familiar with Senlin. An alternative is using Heat's
>> ResourceGroup in which you can set the count of the resources.
>>
>> It worth to mention that we are working on k8s integration [1] so another
>> alternative in the future is using k8s deployment to scale the Zun
>> containers.
>>
>> If you are using Heat, you can reference the following template:
>> http://paste.openstack.org/show/748357/
>>
>> * Create the stack:
>>
>>   $ openstack stack create -t zun-template.yaml test
>>
>> * Scale out:
>>
>>   $ openstack stack update -t zun-template.yaml --parameter "count=2" test
>>
>> * Scale in:
>>
>>   $ openstack stack update -t zun-template.yaml --parameter "count=1" test
>>
>> [1] https://github.com/virtual-kubelet/virtual-kubelet/pull/239
>>
>> Best regards,
>> Hongbin
>>
>> On Mon, Mar 25, 2019 at 1:10 PM Anirudh Gupta <anyrude10 at gmail.com>
>> wrote:
>>
>>> I have integrated Zun service with my existing openstack setup and I am
>>> able to launch a container using Heat Template.
>>>
>>> I am facing issue in scaling up of these contaiiners?
>>> I already have Senlin being installed at my setup, but senlin is unable
>>> to scale the cluster of containers.
>>>
>>> Can you please suggest any alternative i can use in order to scale Zun
>>> Containers
>>>
>>> Thanks
>>> Anirudh Gupta
>>>
>>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-discuss/attachments/20190327/6ecae6c0/attachment-0001.html>


More information about the openstack-discuss mailing list