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

websocket: bad handshake for lxc exec command #832

Closed
larrycai opened this Issue Jul 13, 2015 · 2 comments

Comments

2 participants
@larrycai

new to LXD, try to establish environment, and met problem when I run lxc exec command

Ubuntu 15.04 version

add-apt-repository ppa:ubuntu-lxc/lxd-git-master 
apt-get update
apt-get install lxd
lxd-images import lxc ubuntu trusty amd64 --alias ubuntu
lxc launch ubuntu ub
lxc exec ub /bin/bash

While in the last command, it returns error like below

root@lxd:~# lxc exec ub /bin/bash
error: websocket: bad handshake

What's wrong with the procedure ?

@stgraber

This comment has been minimized.

Show comment
Hide comment
@stgraber

stgraber Jul 13, 2015

Member

so that typically hints that your client and server aren't running the same version somehow.

Can you paste:

which lxc
which lxd
lxc --version
lxd --version
/usr/bin/lxc --version
/usr/bin/lxd --version
Member

stgraber commented Jul 13, 2015

so that typically hints that your client and server aren't running the same version somehow.

Can you paste:

which lxc
which lxd
lxc --version
lxd --version
/usr/bin/lxc --version
/usr/bin/lxd --version
@larrycai

This comment has been minimized.

Show comment
Hide comment
@larrycai

larrycai Jul 14, 2015

@stgraber thx.

lxc is just 0.7 version.

root@lxd:~# lxc --version
0.7

I thought it will be auto-updated by apt-get install lxd, and after I found the real package name lxd-client (not package lxc) and install the latest version for lxc, it works fine

root@lxd:~# dpkg -S /usr/bin/lxc
lxd-client: /usr/bin/lxc
root@lxd:~# apt-get install lxd-client
...

Now I have same version for lxc/lxd

root@lxd:~# lxc --version
0.13
root@lxd:~# lxd --version
0.13

@stgraber thx.

lxc is just 0.7 version.

root@lxd:~# lxc --version
0.7

I thought it will be auto-updated by apt-get install lxd, and after I found the real package name lxd-client (not package lxc) and install the latest version for lxc, it works fine

root@lxd:~# dpkg -S /usr/bin/lxc
lxd-client: /usr/bin/lxc
root@lxd:~# apt-get install lxd-client
...

Now I have same version for lxc/lxd

root@lxd:~# lxc --version
0.13
root@lxd:~# lxd --version
0.13

@larrycai larrycai closed this Jul 14, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment