Skip to content
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

Always loading And can't connection failed with terminal Help! #1507

Closed
stoneqsl opened this issue Jun 15, 2016 · 61 comments
Closed

Always loading And can't connection failed with terminal Help! #1507

stoneqsl opened this issue Jun 15, 2016 · 61 comments
Labels
status/open-for-dev An issue has had its specification reviewed and confirmed. Waiting for an engineer to take it.

Comments

@stoneqsl
Copy link

stoneqsl commented Jun 15, 2016

Machine [ws = workspaceu15kanarzxlainbu: env = wksp-6tl2: machine = ws-machine] was successfully created, its id is 'machineboxbnx5yqoenlypp'
I can't connection with terminal!
I use che 14.2.0.

2016-06-15 11-36-21

@stoneqsl stoneqsl changed the title Always loading And can't connection failed with terminal Always loading And can't connection failed with terminal Help! Jun 15, 2016
@ddementieva
Copy link
Contributor

It seems like it's a security/network issue. Can you try disabling firewall, selinux and iptables?

service iptables stop or service firewalld stop and then service docker restart. Restart Che after.

@james10174
Copy link

@stoneqsl Might be the processor type of the workspace server. See issue #1205 for additional information. Please run this command this command and let us know output.

docker info

@stoneqsl
Copy link
Author

@ddementieva Thanks for your response. I have done as you said,but it doesn't work.I stopped my firewalld.

@stoneqsl
Copy link
Author

@james10174 Thanks for your response. Ihave changed linux_arm7 to linux_arm64,but it doesn't work.so I changed back.
2016-06-16 09-14-15

I found this Warning in Starting workspace agent:

[STDOUT] Listening for transport dt_socket at address: 4403
[STDOUT] 2016-06-16 01:17:01,468[main] [INFO] [o.a.c.s.VersionLoggerListener 89] - Server version: Apache Tomcat/8.0.32
[STDOUT] 2016-06-16 01:17:01,473[main] [INFO] [o.a.c.s.VersionLoggerListener 91] - Server built: Feb 2 2016 19:34:53 UTC
[STDOUT] 2016-06-16 01:17:01,474[main] [INFO] [o.a.c.s.VersionLoggerListener 93] - Server number: 8.0.32.0
[STDOUT] 2016-06-16 01:17:01,475[main] [INFO] [o.a.c.s.VersionLoggerListener 95] - OS Name: Linux
[STDOUT] 2016-06-16 01:17:01,475[main] [INFO] [o.a.c.s.VersionLoggerListener 97] - OS Version: 3.10.0-327.el7.x86_64
[STDOUT] 2016-06-16 01:17:01,476[main] [INFO] [o.a.c.s.VersionLoggerListener 99] - Architecture: amd64
[STDOUT] 2016-06-16 01:17:01,477[main] [INFO] [o.a.c.s.VersionLoggerListener 101] - Java Home: /opt/jdk1.8.0_45/jre
[STDOUT] 2016-06-16 01:17:01,477[main] [INFO] [o.a.c.s.VersionLoggerListener 103] - JVM Version: 1.8.0_45-b14
[STDOUT] 2016-06-16 01:17:01,478[main] [INFO] [o.a.c.s.VersionLoggerListener 105] - JVM Vendor: Oracle Corporation
[STDOUT] 2016-06-16 01:17:01,478[main] [INFO] [o.a.c.s.VersionLoggerListener 107] - CATALINA_BASE: /home/user/che/ws-agent
[STDOUT] 2016-06-16 01:17:01,478[main] [INFO] [o.a.c.s.VersionLoggerListener 109] - CATALINA_HOME: /home/user/che/ws-agent
[STDOUT] 2016-06-16 01:17:01,480[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Djava.util.logging.config.file=/home/user/che/ws-agent/conf/logging.properties
[STDOUT] 2016-06-16 01:17:01,482[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager
[STDOUT] 2016-06-16 01:17:01,483[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Xms256m
[STDOUT] 2016-06-16 01:17:01,483[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Xmx1024m
[STDOUT] 2016-06-16 01:17:01,484[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Djava.security.egd=file:/dev/./urandom
[STDOUT] 2016-06-16 01:17:01,485[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dche.logs.dir=/home/user/che/ws-agent/logs
[STDOUT] 2016-06-16 01:17:01,486[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -agentlib:jdwp=transport=dt_socket,address=4403,server=y,suspend=n
[STDOUT] 2016-06-16 01:17:01,488[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dcom.sun.management.jmxremote
[STDOUT] 2016-06-16 01:17:01,489[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dcom.sun.management.jmxremote.ssl=false
[STDOUT] 2016-06-16 01:17:01,489[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dcom.sun.management.jmxremote.authenticate=false
[STDOUT] 2016-06-16 01:17:01,490[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dche.local.conf.dir=/mnt/che/conf
[STDOUT] 2016-06-16 01:17:01,498[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Djava.endorsed.dirs=/home/user/che/ws-agent/endorsed
[STDOUT] 2016-06-16 01:17:01,499[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dcatalina.base=/home/user/che/ws-agent
[STDOUT] 2016-06-16 01:17:01,500[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Dcatalina.home=/home/user/che/ws-agent
[STDOUT] 2016-06-16 01:17:01,500[main] [INFO] [o.a.c.s.VersionLoggerListener 115] - Command line argument: -Djava.io.tmpdir=/home/user/che/ws-agent/temp
[STDOUT] 2016-06-16 01:17:01,620[main] [INFO] [o.a.c.http11.Http11NioProtocol 425] - Initializing ProtocolHandler ["http-nio-4401"]
[STDOUT] 2016-06-16 01:17:01,629[main] [INFO] [o.a.t.util.net.NioSelectorPool 72] - Using a shared selector for servlet write/read
[STDOUT] 2016-06-16 01:17:01,631[main] [INFO] [o.a.catalina.startup.Catalina 591] - Initialization processed in 384 ms
[STDOUT] 2016-06-16 01:17:01,643[main] [INFO] [c.m.JmxRemoteLifecycleListener 332] - The JMX Remote Listener has configured the registry on port 32002 and the server on port 32102 for the Platform server
[STDOUT] 2016-06-16 01:17:01,643[main] [INFO] [o.a.c.core.StandardService 435] - Starting service Catalina
[STDOUT] 2016-06-16 01:17:01,643[main] [INFO] [o.a.c.core.StandardEngine 259] - Starting Servlet Engine: Apache Tomcat/8.0.32
[STDOUT] 2016-06-16 01:17:01,683[ost-startStop-1] [INFO] [o.a.c.startup.HostConfig 910] - Deploying web application archive /home/user/che/ws-agent/webapps/ide.war
[STDOUT] Thu Jun 16 01:17:05 UTC 2016 - [localhost-startStop-1] Product-specified preferences called before plugin is started
[STDOUT] 2016-06-16 01:17:05,545[rrest.WSClient1] [INFO] [.c.a.c.n.WSocketEventBusClient 223] - Open connection to ws://che-host:8080/ide/api/eventbus/?token=dummy_token.
[STDOUT] 2016-06-16 01:17:05,851[ost-startStop-1] [INFO] [o.a.c.startup.HostConfig 974] - Deployment of web application archive /home/user/che/ws-agent/webapps/ide.war has finished in 4,165 ms
[STDOUT] 2016-06-16 01:17:05,855[ost-startStop-1] [INFO] [o.a.c.startup.HostConfig 1030] - Deploying web application directory /home/user/che/ws-agent/webapps/ROOT
[STDOUT] 2016-06-16 01:17:05,895[ost-startStop-1] [INFO] [o.a.c.startup.HostConfig 1142] - Deployment of web application directory /home/user/che/ws-agent/webapps/ROOT has finished in 40 ms
[STDOUT] 2016-06-16 01:17:05,911[main] [INFO] [o.a.c.http11.Http11NioProtocol 470] - Starting ProtocolHandler ["http-nio-4401"]
[STDOUT] 2016-06-16 01:17:05,921[main] [INFO] [o.a.catalina.startup.Catalina 642] - Server startup in 4289 ms
[STDOUT] 2016-06-16 01:17:06,080[nio-4401-exec-1] [WARN ] [i.ContainerResponse$BodyWriter 90] - Client has aborted connection. Response writing omitted.

And In the back of terminal,it show this warning:

2016-06-16 09:18:23,300[nio-8080-exec-4] [WARN ] [i.ContainerResponse$BodyWriter 90] - Client has aborted connection. Response writing omitted.

@james10174
Copy link

james10174 commented Jun 16, 2016

@stoneqsl Well from above it looks like your architecture is amd64. How are you starting the che server at the command line? Does seem like a port issue though.

@stoneqsl
Copy link
Author

@james10174 sh che.sh run -r:192.168.0.189 192.168.0.189 is my ip.

@james10174
Copy link

james10174 commented Jun 16, 2016

@stoneqsl If you are in the local machine as the screen capture above indicates try "che.sh run" without -r:.

@stoneqsl
Copy link
Author

@james10174 It doesn't work .I have tried it.

@james10174
Copy link

james10174 commented Jun 16, 2016

@stoneqsl Try the following on che server.

Terminal 1
nc -l 35000
#can also do nc -l <external ipaddress> 35000

Terminal 2
sudo netstat -tulpen | grep nc
#write down port number (ie 0.0.0.0:<port assigned>)
nc localhost <port assigned>
#can also do nc <external ipaddress> <port assigned>

Terminal 1
invalid connection to [127.0.0.1] from (UNKNOWN) [127.0.0.1] <number>
#<ctrl-c> to exit

@stoneqsl
Copy link
Author

stoneqsl commented Jun 16, 2016

@james10174
2016-06-16 09-58-32
there is nothing happend

@james10174
Copy link

@stoneqsl So did the local connection from terminal 2 fail? Let me know what ifconfig outputs.

@stoneqsl
Copy link
Author

@james10174 yes.[stone@localhost lib]$ ifconfig
docker0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 172.17.0.1 netmask 255.255.0.0 broadcast 0.0.0.0
inet6 fe80::42:e8ff:fe2f:9f46 prefixlen 64 scopeid 0x20
ether 02:42:e8:2f:9f:46 txqueuelen 0 (Ethernet)
RX packets 1158 bytes 127618 (124.6 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 1168 bytes 134019 (130.8 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

enp3s0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.0.189 netmask 255.255.255.0 broadcast 192.168.0.255
inet6 fe80::9e5c:8eff:fe83:cbdd prefixlen 64 scopeid 0x20
ether 9c:5c:8e:83:cb:dd txqueuelen 1000 (Ethernet)
RX packets 14902 bytes 6008272 (5.7 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 12323 bytes 2581629 (2.4 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10
loop txqueuelen 0 (Local Loopback)
RX packets 9309 bytes 1224576 (1.1 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 9309 bytes 1224576 (1.1 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

veth79860d1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet6 fe80::445c:d6ff:febc:6d74 prefixlen 64 scopeid 0x20
ether 46:5c:d6:bc:6d:74 txqueuelen 0 (Ethernet)
RX packets 315 bytes 29235 (28.5 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 363 bytes 31122 (30.3 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

virbr0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 192.168.122.1 netmask 255.255.255.0 broadcast 192.168.122.255
ether 52:54:00:a3:9b:7a txqueuelen 0 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0

@james10174
Copy link

@stoneqsl Let me know output of 'sudo iptables -L -n'

@stoneqsl
Copy link
Author

@james10174
[root@localhost lib]# sudo iptables -L -n
Chain INPUT (policy ACCEPT)
target prot opt source destination
ACCEPT udp -- 0.0.0.0/0 0.0.0.0/0 udp dpt:53
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:53
ACCEPT udp -- 0.0.0.0/0 0.0.0.0/0 udp dpt:67
ACCEPT tcp -- 0.0.0.0/0 0.0.0.0/0 tcp dpt:67

Chain FORWARD (policy ACCEPT)
target prot opt source destination
DOCKER all -- 0.0.0.0/0 0.0.0.0/0
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0 ctstate RELATED,ESTABLISHED
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0
ACCEPT all -- 0.0.0.0/0 192.168.122.0/24 ctstate RELATED,ESTABLISHED
ACCEPT all -- 192.168.122.0/24 0.0.0.0/0
ACCEPT all -- 0.0.0.0/0 0.0.0.0/0
REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-port-unreachable
REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-port-unreachable

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
ACCEPT udp -- 0.0.0.0/0 0.0.0.0/0 udp dpt:68

Chain DOCKER (1 references)
target prot opt source destination
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:9876
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:8080
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:8000
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:4411
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:4403
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:4401
ACCEPT tcp -- 0.0.0.0/0 172.17.0.2 tcp dpt:22
[root@localhost lib]#

@stoneqsl
Copy link
Author

@james10174 is there anything wrong?

@ghost ghost mentioned this issue Jun 16, 2016
@stoneqsl
Copy link
Author

@eivantsov I'm sorry. I don't know how to do with it.
2016-06-16 14-02-12
Ephemeral port range needs to be opened - 32768-65535.
But how to make sure that is opened?

@stoneqsl
Copy link
Author

@eivantsov OK! Here we talk with each other.

@james10174
Copy link

james10174 commented Jun 16, 2016

@stoneqsl The REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-port-unreachable from the iptable COULD be troublesome. Try the following.

iptables-save > iptables.dump
iptables-save > iptables.save
##Edit iptables.dump and remove all REJECT lines before doing the following.
iptables-restore < iptables.dump

##If this does not work you can restore your iptables if you would like
iptables-restore < iptables.save

@stoneqsl
Copy link
Author

stoneqsl commented Jun 17, 2016

[STDOUT] 2016-06-17 00:34:11,712[nio-4401-exec-1] [WARN ] [i.ContainerResponse$BodyWriter 90] - Client has aborted connection. Response writing omitted.
[STDOUT] 2016-06-17 00:34:15,905[nio-4401-exec-7] [ERROR] [c.s.o.RemoteOAuthTokenProvider 72] - Exception on token retrieval, message : Unsupported OAuth provider github
[STDOUT] 2016-06-17 00:34:18,413[nio-4401-exec-7] [ERROR] [c.s.o.RemoteOAuthTokenProvider 72] - Exception on token retrieval, message : Unsupported OAuth provider github

@james10174 I have tried your command. But it doesn't work. I think that The REJECT all -- 0.0.0.0/0 0.0.0.0/0 reject-with icmp-port-unreachable from the iptable COULD be troublesome.

@james10174
Copy link

@stoneqsl with the iptables modified with iptables-restore < iptables.dump did your start che with bin/ch.sh run leaving out the remote ipaddress?

@stoneqsl
Copy link
Author

@james10174 yes.I have tried it without the remote ipaddress.But it doesn't work.

@james10174
Copy link

james10174 commented Jun 17, 2016

@stoneqsl Try after shutting down che server

sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che

https://eclipse-che.readme.io/docs/usage-docker

@stoneqsl
Copy link
Author

@james10174 [root@localhost bin]# systemctl start docker.service
[root@localhost bin]# sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che

!!!
!!! Running 'docker' succeeded, but 'docker ps' failed. This usually means that docker cannot reach its daemon.
!!!

Usage:
che [OPTIONS] [COMMAND]
-v, --vmware Use the docker-machine VMware driver (instead of VirtualBox)
-m:name, --machine:name For Win & Mac, sets the docker-machine VM name; default=che
-a:driver, --machine-driver:driver For Win & Mac, specifies the docker-machine driver to use; default=vbox
-p:port, --port:port Port that Che server will use for HTTP requests; default=8080
-r:ip, --remote:ip If Che clients are not localhost, set to IP address of Che server
-h, --help Show this help
-d, --debug Use debug mode (prints command line options + app server debug)

Options when running Che natively:
-b, --blocking-entropy Security: https://wiki.apache.org/tomcat/HowTo/FasterStartUp
-g, --registry Launch Docker registry as a container (used for ws snapshots)
-s:client, --skip:client Do not print browser client connection information
-s:java, --skip:java Do not enforce Java version checks
-s:uid, --skip:uid Do not enforce UID=1000 for Docker

Options when running Che in a Docker container:
-i, --image Launches Che within a Docker container using latest image
-i:tag, --image:tag Launches Che within a Docker container using specific image
-c:name, --container:name Sets the container name if -i provided; default=che
-t, --stop-container If stopping Che, will also stop Che container if Che ran with -i

Commands:
run (Default) Starts Che server with logging in current console
start Starts Che server in new console
stop Stops Che server

Docs: http://eclipse.org/che/getting-started.

If you are running Che as a server on a VM for multiple users to access, review the various networking
configuration items that control how clients, Che and workspaces initiate connections. See:
https://eclipse-che.readme.io/docs/networking.
[root@localhost bin]#

@james10174
Copy link

james10174 commented Jun 17, 2016

@stoneqsl Is your docker daemon running?

sudo systemctl start docker
sudo systemctl status docker
sudo systemctl enable docker

http://www.tecmint.com/install-docker-and-learn-containers-in-centos-rhel-7-6/

@stoneqsl
Copy link
Author

@james10174
[root@localhost bin]# systemctl start docker
[root@localhost bin]# systemctl status docker
● docker.service - Docker Application Container Engine
Loaded: loaded (/usr/lib/systemd/system/docker.service; disabled; vendor preset: disabled)
Active: active (running) since 五 2016-06-17 08:57:33 CST; 23min ago
Docs: http://docs.docker.com
Main PID: 3969 (sh)
CGroup: /system.slice/docker.service
├─3969 /bin/sh -c /usr/bin/docker-current daemon $OPTIONS ...
├─3970 /usr/bin/docker-current daemon --selinux-enabled --storage-...
└─3971 /usr/bin/forward-journald -tag docker

6月 17 09:09:32 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:09:34 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:09:34 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:09:34 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:14:12 localhost.localdomain systemd[1]: Started Docker Application...
6月 17 09:14:16 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:14:17 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:14:17 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:14:17 localhost.localdomain forward-journal[3971]: time="2016-06-1...
6月 17 09:21:08 localhost.localdomain systemd[1]: Started Docker Application...
Hint: Some lines were ellipsized, use -l to show in full.
[root@localhost bin]# systemctl enable docker
Created symlink from /etc/systemd/system/multi-user.target.wants/docker.service to /usr/lib/systemd/system/docker.service.
[root@localhost bin]# sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che

!!!
!!! Running 'docker' succeeded, but 'docker ps' failed. This usually means that docker cannot reach its daemon.
!!!

Usage:
che [OPTIONS] [COMMAND]
-v, --vmware Use the docker-machine VMware driver (instead of VirtualBox)
-m:name, --machine:name For Win & Mac, sets the docker-machine VM name; default=che
-a:driver, --machine-driver:driver For Win & Mac, specifies the docker-machine driver to use; default=vbox
-p:port, --port:port Port that Che server will use for HTTP requests; default=8080
-r:ip, --remote:ip If Che clients are not localhost, set to IP address of Che server
-h, --help Show this help
-d, --debug Use debug mode (prints command line options + app server debug)

Options when running Che natively:
-b, --blocking-entropy Security: https://wiki.apache.org/tomcat/HowTo/FasterStartUp
-g, --registry Launch Docker registry as a container (used for ws snapshots)
-s:client, --skip:client Do not print browser client connection information
-s:java, --skip:java Do not enforce Java version checks
-s:uid, --skip:uid Do not enforce UID=1000 for Docker

Options when running Che in a Docker container:
-i, --image Launches Che within a Docker container using latest image
-i:tag, --image:tag Launches Che within a Docker container using specific image
-c:name, --container:name Sets the container name if -i provided; default=che
-t, --stop-container If stopping Che, will also stop Che container if Che ran with -i

Commands:
run (Default) Starts Che server with logging in current console
start Starts Che server in new console
stop Stops Che server

Docs: http://eclipse.org/che/getting-started.

If you are running Che as a server on a VM for multiple users to access, review the various networking
configuration items that control how clients, Che and workspaces initiate connections. See:
https://eclipse-che.readme.io/docs/networking.
[root@localhost bin]#
I have no idea.

@james10174
Copy link

@stoneqsl try sudo docker run ubuntu /bin/echo 'Hello world'. If it does not work then usermod -a -G docker root

@stoneqsl
Copy link
Author

@james10174 it's OK!

@james10174
Copy link

@stoneqsl I'm sorry did you mean that the sudo docker run ubuntu /bin/echo 'Hello world' command ran?

@stoneqsl
Copy link
Author

@james10174 It's not worked.

@james10174
Copy link

@stoneqsl What was the output of sudo systemctl status docker

@stoneqsl
Copy link
Author

@james10174 [root@localhost bin]# sudo systemctl restart docker
[root@localhost bin]# sudo systemctl status docker
● docker.service - Docker Application Container Engine
Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
Active: active (running) since 五 2016-06-17 09:57:23 CST; 8s ago
Docs: http://docs.docker.com
Main PID: 10240 (sh)
CGroup: /system.slice/docker.service
├─10240 /bin/sh -c /usr/bin/docker-current daemon $OPTIONS ...
├─10241 /usr/bin/docker-current daemon --selinux-enabled --storage...
└─10242 /usr/bin/forward-journald -tag docker

6月 17 09:57:22 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:22 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:22 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:23 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:23 localhost.localdomain forward-journal[10242]: .................
6月 17 09:57:23 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:23 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:23 localhost.localdomain forward-journal[10242]: time="2016-06-...
6月 17 09:57:23 localhost.localdomain systemd[1]: Started Docker Application...
6月 17 09:57:23 localhost.localdomain forward-journal[10242]: time="2016-06-...
Hint: Some lines were ellipsized, use -l to show in full.
[root@localhost bin]# sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che

!!!
!!! Running 'docker' succeeded, but 'docker ps' failed. This usually means that docker cannot reach its daemon.
!!!

Usage:
che [OPTIONS] [COMMAND]
-v, --vmware Use the docker-machine VMware driver (instead of VirtualBox)
-m:name, --machine:name For Win & Mac, sets the docker-machine VM name; default=che
-a:driver, --machine-driver:driver For Win & Mac, specifies the docker-machine driver to use; default=vbox
-p:port, --port:port Port that Che server will use for HTTP requests; default=8080
-r:ip, --remote:ip If Che clients are not localhost, set to IP address of Che server
-h, --help Show this help
-d, --debug Use debug mode (prints command line options + app server debug)

Options when running Che natively:
-b, --blocking-entropy Security: https://wiki.apache.org/tomcat/HowTo/FasterStartUp
-g, --registry Launch Docker registry as a container (used for ws snapshots)
-s:client, --skip:client Do not print browser client connection information
-s:java, --skip:java Do not enforce Java version checks
-s:uid, --skip:uid Do not enforce UID=1000 for Docker

Options when running Che in a Docker container:
-i, --image Launches Che within a Docker container using latest image
-i:tag, --image:tag Launches Che within a Docker container using specific image
-c:name, --container:name Sets the container name if -i provided; default=che
-t, --stop-container If stopping Che, will also stop Che container if Che ran with -i

Commands:
run (Default) Starts Che server with logging in current console
start Starts Che server in new console
stop Stops Che server

Docs: http://eclipse.org/che/getting-started.

If you are running Che as a server on a VM for multiple users to access, review the various networking
configuration items that control how clients, Che and workspaces initiate connections. See:
https://eclipse-che.readme.io/docs/networking.
[root@localhost bin]#

@james10174
Copy link

@stoneqsl docker info

@stoneqsl
Copy link
Author

@james10174

[root@localhost bin]# docker info
Containers: 21
Images: 101
Server Version: 1.9.1
Storage Driver: devicemapper
Pool Name: docker-253:0-207646011-pool
Pool Blocksize: 65.54 kB
Base Device Size: 107.4 GB
Backing Filesystem:
Data file: /dev/loop0
Metadata file: /dev/loop1
Data Space Used: 5.264 GB
Data Space Total: 107.4 GB
Data Space Available: 42.14 GB
Metadata Space Used: 8.868 MB
Metadata Space Total: 2.147 GB
Metadata Space Available: 2.139 GB
Udev Sync Supported: true
Deferred Removal Enabled: false
Deferred Deletion Enabled: false
Deferred Deleted Device Count: 0
Data loop file: /var/lib/docker/devicemapper/devicemapper/data
Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
Library Version: 1.02.107-RHEL7 (2015-10-14)
Execution Driver: native-0.2
Logging Driver: json-file
Kernel Version: 3.10.0-327.el7.x86_64
Operating System: CentOS Linux 7 (Core)
CPUs: 4
Total Memory: 7.512 GiB
Name: localhost.localdomain
ID: TITA:T3SJ:5RGB:LMIV:NLW7:JYG7:4DBJ:NXMT:BPFP:KV7X:CNEU:3SLA
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled

@james10174
Copy link

@stoneqsl From what I found on google about WARNING: bridge-nf-call-iptables is disabled try systemctl stop firewalld.

@stoneqsl
Copy link
Author

[root@localhost bin]# systemctl stop firewalld
[root@localhost bin]# docker info
Containers: 21
Images: 101
Server Version: 1.9.1
Storage Driver: devicemapper
Pool Name: docker-253:0-207646011-pool
Pool Blocksize: 65.54 kB
Base Device Size: 107.4 GB
Backing Filesystem:
Data file: /dev/loop0
Metadata file: /dev/loop1
Data Space Used: 5.264 GB
Data Space Total: 107.4 GB
Data Space Available: 42.14 GB
Metadata Space Used: 8.868 MB
Metadata Space Total: 2.147 GB
Metadata Space Available: 2.139 GB
Udev Sync Supported: true
Deferred Removal Enabled: false
Deferred Deletion Enabled: false
Deferred Deleted Device Count: 0
Data loop file: /var/lib/docker/devicemapper/devicemapper/data
Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
Library Version: 1.02.107-RHEL7 (2015-10-14)
Execution Driver: native-0.2
Logging Driver: json-file
Kernel Version: 3.10.0-327.el7.x86_64
Operating System: CentOS Linux 7 (Core)
CPUs: 4
Total Memory: 7.512 GiB
Name: localhost.localdomain
ID: TITA:T3SJ:5RGB:LMIV:NLW7:JYG7:4DBJ:NXMT:BPFP:KV7X:CNEU:3SLA
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled
@james10174

@james10174
Copy link

james10174 commented Jun 17, 2016

@stoneqsl

systemctl start firewalld
systemctl disable firewalld
systemctl stop firewalld
systemctl status firewalld
sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che

@stoneqsl
Copy link
Author

@james10174
[root@localhost bin]# systemctl disable firewalld
[root@localhost bin]# systemctl stop firewalld
[root@localhost bin]# systemctl status firewalld
● firewalld.service - firewalld - dynamic firewall daemon
Loaded: loaded (/usr/lib/systemd/system/firewalld.service; disabled; vendor preset: enabled)
Active: inactive (dead)

6月 17 10:17:36 localhost.localdomain systemd[1]: Stopped firewalld - dynami...
6月 17 10:18:11 localhost.localdomain systemd[1]: Stopped firewalld - dynami...
6月 17 10:23:04 localhost.localdomain systemd[1]: Stopped firewalld - dynami...
Hint: Some lines were ellipsized, use -l to show in full.
[root@localhost bin]# sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che

!!!
!!! Running 'docker' succeeded, but 'docker ps' failed. This usually means that docker cannot reach its daemon.
!!!

Usage:
che [OPTIONS] [COMMAND]
-v, --vmware Use the docker-machine VMware driver (instead of VirtualBox)
-m:name, --machine:name For Win & Mac, sets the docker-machine VM name; default=che
-a:driver, --machine-driver:driver For Win & Mac, specifies the docker-machine driver to use; default=vbox
-p:port, --port:port Port that Che server will use for HTTP requests; default=8080
-r:ip, --remote:ip If Che clients are not localhost, set to IP address of Che server
-h, --help Show this help
-d, --debug Use debug mode (prints command line options + app server debug)

Options when running Che natively:
-b, --blocking-entropy Security: https://wiki.apache.org/tomcat/HowTo/FasterStartUp
-g, --registry Launch Docker registry as a container (used for ws snapshots)
-s:client, --skip:client Do not print browser client connection information
-s:java, --skip:java Do not enforce Java version checks
-s:uid, --skip:uid Do not enforce UID=1000 for Docker

Options when running Che in a Docker container:
-i, --image Launches Che within a Docker container using latest image
-i:tag, --image:tag Launches Che within a Docker container using specific image
-c:name, --container:name Sets the container name if -i provided; default=che
-t, --stop-container If stopping Che, will also stop Che container if Che ran with -i

Commands:
run (Default) Starts Che server with logging in current console
start Starts Che server in new console
stop Stops Che server

Docs: http://eclipse.org/che/getting-started.

If you are running Che as a server on a VM for multiple users to access, review the various networking
configuration items that control how clients, Che and workspaces initiate connections. See:
https://eclipse-che.readme.io/docs/networking.
[root@localhost bin]# docker info
Containers: 22
Images: 101
Server Version: 1.9.1
Storage Driver: devicemapper
Pool Name: docker-253:0-207646011-pool
Pool Blocksize: 65.54 kB
Base Device Size: 107.4 GB
Backing Filesystem:
Data file: /dev/loop0
Metadata file: /dev/loop1
Data Space Used: 5.332 GB
Data Space Total: 107.4 GB
Data Space Available: 42.07 GB
Metadata Space Used: 9.019 MB
Metadata Space Total: 2.147 GB
Metadata Space Available: 2.138 GB
Udev Sync Supported: true
Deferred Removal Enabled: false
Deferred Deletion Enabled: false
Deferred Deleted Device Count: 0
Data loop file: /var/lib/docker/devicemapper/devicemapper/data
Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
Library Version: 1.02.107-RHEL7 (2015-10-14)
Execution Driver: native-0.2
Logging Driver: json-file
Kernel Version: 3.10.0-327.el7.x86_64
Operating System: CentOS Linux 7 (Core)
CPUs: 4
Total Memory: 7.512 GiB
Name: localhost.localdomain
ID: TITA:T3SJ:5RGB:LMIV:NLW7:JYG7:4DBJ:NXMT:BPFP:KV7X:CNEU:3SLA
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled

@james10174
Copy link

@stoneqsl Something seems wrong with your docker. try che nightly sudo docker run -ti --net=host -v /var/run/docker.sock:/var/run/docker.sock codenvy/che:nightly. If this doesn't work try upgrading your docker version to 1.10 or higher..

@stoneqsl
Copy link
Author

stoneqsl commented Jun 17, 2016

@james10174 Ok ,Thanks for your response.I'm trying it.

@stoneqsl
Copy link
Author

2016-06-17 18-46-43
2016-06-17 18-47-16
2016-06-17 18-48-20
@james10174

@james10174
Copy link

@eivantsov Think there might be an issue with the terminal. Do you know of ways to test it from within the container?

@stoneqsl Can you create and run mvn clean install the console-java-simple project?

@stoneqsl
Copy link
Author

@james10174 NO,I cann't! When I go into the container.There is a terminal.But it cann't be connected.

@ghost
Copy link

ghost commented Jun 18, 2016

@stoneqsl let's try to manually launch terminal.

docker ps - grab container ID
docker exec -ti $containerID bash
ps ax | grep websocket-terminal - check if terminal is running
~/che/terminal/che-websocket-terminal -addr :4411 -cmd /bin/bash -static ~/che/terminal/ run terminal manually

Provide output from this command. If the terminal starts, it produces no output. If it's so, refresh the IDE.

By the way, it looks like it is just terminal that does not work. Can you create projects at Workspace > Create Project?

@stoneqsl
Copy link
Author

stoneqsl commented Jun 19, 2016

@eivantsov

[stone@localhost /]$ docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
4c9adea8e55e eclipse-che/che_workspacei0m2fh1om7kgte30_ws-machine_edtgi "/bin/sh -c 'sudo /us" 39 hours ago Up 39 hours 0.0.0.0:32788->22/tcp, 0.0.0.0:32787->4401/tcp, 0.0.0.0:32786->4403/tcp, 0.0.0.0:32785->4411/tcp, 0.0.0.0:32784->8000/tcp, 0.0.0.0:32783->8080/tcp, 0.0.0.0:32782->9876/tcp che_workspacei0m2fh1om7kgte30_ws-machine_edtgi
[stone@localhost /]$ docker ps -grap 4c9ade
flag provided but not defined: -grap
See 'docker ps --help'.
[stone@localhost /]$ docker exec -ti 4c9ade bash
user@4c9adea8e55e:/projects$ ps ax|grep websocket-terminal
324 ? S+ 0:00 grep --color=auto websocket-terminal
user@4c9adea8e55e:/projects$ ps ax|grep websocket-terminal -check
grep: websocket-terminal: No such file or directory
user@4c9adea8e55e:/projects$ ps ax|grep websocket-terminal
328 ? S+ 0:00 grep --color=auto websocket-terminal
user@4c9adea8e55e:/projects$ ~/che/terminal/che-websocket-terminal -addr :4411 -cmd /bin/bash -static ~/che/terminal/
bash: /home/user/che/terminal/che-websocket-terminal: Permission denied
user@4c9adea8e55e:/projects$ sudo ~/che/terminal/che-websocket-terminal -addr :4411 -cmd /bin/bash -static ~/che/terminal/
sudo: /home/user/che/terminal/che-websocket-terminal: command not found
user@4c9adea8e55e:/projects$ su
su: must be run from a terminal
user@4c9adea8e55e:/projects$

I cann't creat a project.

@ghost
Copy link

ghost commented Jun 20, 2016

@stoneqsl can you run ls -la when you are in the terminal directory? And then sudo su?

By the way, it looks like it is just terminal that does not work. Can you create projects at Workspace > Create Project?

@stoneqsl
Copy link
Author

@eivantsov Thanks for your response.I have changed to the version 14.3.0.Now I can create projects.But it's a problem that Client has aborted connection. Response writing omitted.

@ghost
Copy link

ghost commented Jun 21, 2016

@stoneqsl disregard this warning.

So, is the problem solved now?

@ghost ghost added the status/open-for-dev An issue has had its specification reviewed and confirmed. Waiting for an engineer to take it. label Jun 21, 2016
@stoneqsl
Copy link
Author

It can run .But there is still some problems.Example Client has aborted connection. Response writing omitted.And I can't use IE to access che,only use firefox And google.
@eivantsov

@james10174
Copy link

@stoneqsl Please open another issue for IE issue. I could not get IE(version 10.0.9200.16899) to start che server either. My IE version seems to run GWT http://www.gwt-ext.com/demo/#gridDD but fails a lot of the html5 checks http://html5test.com/s/e36a472f8b0c251a.html versus google chrome https://html5test.com/s/a2a4642f8b0bab50.html which maybe the cause. Specifically I think communication server-sent events is needed which is not supported in my version. My IE could not load https://www.websocket.org/echo.html. I don't use IE much so I am not reporting an issue.

@ghost
Copy link

ghost commented Jun 21, 2016

@stoneqsl IE isn't among officially supported browsers. What version do you have? It should be ok with the latest IE.

@james10174
Copy link

@eivantsov Where are the official supported browsers listed?

@ghost
Copy link

ghost commented Jun 21, 2016

@james10174 right now, there's no such a list yet. I will add this info to docs.

@james10174
Copy link

@eivantsov OK I was going crazy trying to find it. Thanks.

@ghost
Copy link

ghost commented Jun 23, 2016

@stoneqsl is the issue resolved for you? Is Che fully functional for you now?

@stoneqsl
Copy link
Author

stoneqsl commented Jun 23, 2016

@eivantsov thanks for your response. everything is ok! thank you very mach.

@ghost ghost closed this as completed Jun 23, 2016
@james10174
Copy link

@stoneqsl Is the terminal working for you?

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status/open-for-dev An issue has had its specification reviewed and confirmed. Waiting for an engineer to take it.
Projects
None yet
Development

No branches or pull requests

3 participants