I followed the guide on RethinkDB Documentation
After setting up RethinkDB on system startup on Ubuntu 14.04 server, port 8080 does not start.
I checked rethinkdb log.
2015-10-29T18:28:53.207447805 0.086002s notice: Listening for administrative HTTP on 127.0.1.1, 10.17.0.6, 159.203.115.29, 10.132.204.34
What am I doing wrong?
Maybe you already had something listen on port 8080 but only for 127.0.0.1, from your log, the server did listen on 127.0.1.1, 10.17.0.6, 159.203.115.29, 10.132.204.34.
Try to check your /etc/hosts to see if you assign something to 127.0.1.1 and check the binding
lsof -i :8080
Once you found out the program that listen on, try to remove/stop it from binding to that.
Also, you can try to run this command directly:
rethinkdb --bind all
to ensure that RethinkDB will bind to all ips.
Related
I was not able to use port 8080 because it was apparently already used.
In order to see which program was using it, I typed the following command in my terminal (on MacOS):
sudo lsof -n -i :8080
Here's the result:
httpd is also listening on port 80, which I found out by using the following command:
sudo lsof -n -i :80 | grep LISTEN
Here's the result:
So I went to find out what this "httpd"-process was. Apparently it is basically the web server installed on my machine. The web server installed on my machine is Apache2.
Given this fact I concluded that Apache2 was apparently configured to listen on port 80 AND on port 8080.
BUT: Here's the crazy thing: I went to the folder /etc/apache2 and opened the file "httpd.conf". In the file Apache is configured to listen on port 80 only !!!
Why the hell is it also listening on port 8080 ?!
How can I make it listen on port 80 only ?
I have a ubuntu server, but I have to connect to by <ip>:8820. I want to setup a shadowsocks server on it on port 1081, then how to connect to it? Say something like <ip>:8820:1081(which is invalid)? I have tried to use ssh to map it's 1081 port to my 1081 port:
ssh -N -f -L localhost:1081:localhost:1081 -p 8820 user#<ip>
Then I config my sslocal as:
{
"server":"127.0.0.1",
"server_port":1081,
"local_address":"127.0.0.1",
"local_port":10081,
"password":"password",
"timeout":300,
"method":"rc4-md5",
"workers":1
}
But it doesn't work, how can I do?
First, Server ip must be your vps ip adress. And use 443 port(or othders but now GFW has upgrade to use whitelist, 443 port temporarily safe)
Second, Could you share your ss-local.log on here ?
If your method:rc4-md5 doesn't work, you can try aes-256-cfb. I also have problems with the service on method:rc4-md5
Don't forget restart your ss-server.
Finally, Make sure your internet don't has any othder proxy.
You don’t actually need that.
{
"server":"0.0.0.0",
"server_port":<your server port here>,
"password":"password",
"timeout":300,
"method":"rc4-md5",
"workers":1
}
Configure ss-server to listen on ‘0.0.0.0’.
Mapping remote port, simply you can use ss-tunnel instead.
Suggestions:
DO NOT USE STANDARD PORTS. (Random port number larger than 3000 smaller than 65536 is OK for me.)
The rc4-md5 solution:
https://github.com/shadowsocks/shadowsocks-libev/issues/1966
Reference:
https://github.com/shadowsocks/shadowsocks-libev/blob/master/doc/ss-tunnel.asciidoc
I've been following this tutorial for beginners about docker which basically instructs you to create an apache container and map a localhost port to the one on the container.
when I try localhost:80 it doesn't connect, although the container is up and running.
I even made a rule in the firewall to allow connection to port 80, but couldn't get connected to the localhost.
Any ideas ?
On Windows/OS X, Docker is running inside a Linux virtual machine (Docker Toolbox) with a default IP address of 192.168.99.100. Thus, when you use docker run -p 80:80 to bind the container port to host port, it in fact binds to the virtual machine's port 80. Thus the address you need is http://192.168.99.100.
The 172.17.0.3 address is the address of the docker container inside that virtual machine, and is not accessible directly from Windows/OS X.
Add a line to your DockerFile before restarting apache.
RUN echo 'ServerName localhost' >> /etc/apache2/apache2.conf
I stumbled upon this question as I was looking for a way to bind my local HTTP port (80) to the HTTP port of my container, an Apache container running on Docker Desktop for Windows - through WSL2 (this is important)
I couldn't find a quick and easy way to do this, so I figured it out myself.
What you must do is bind your local port (on Windows) to the port on WSL.
Here is how I did it :
$wsl_ip = (wsl -d "docker-desktop" -- "ifconfig" "eth0" "|" "grep" "inet addr:").trim("").split(":").split()[2]
netsh interface portproxy add v4tov4 listenport=443 listenaddress=0.0.0.0 connectport=443 connectaddress=$wsl_ip
netsh interface portproxy add v4tov4 listenport=80 listenaddress=0.0.0.0 connectport=80 connectaddress=$wsl_ip
You can either create a Powershell Script (.ps1) and run it with Powershell, or copy/paste each command line into Windows Terminal / Powershell running with Administrator Privileges.
What this does is :
attach to the "docker-desktop" distribution running in WSL2 2
run "ifconfig eth0 | grep inet addr:" to get the local IP address of
the "virtual machine"
parse the result, and use Netsh to
create a portproxy between port 80 of your Windows machine and port
80 of your Linux machine. Same is done for port 443. You can easily
map other ports if you understand what the command is doing.
More explanation :
Since Docker for Windows 10/11 uses WSL2, when you expose a port (through docker-compose or with an EXPOSE command in your Dockerfile), it is exposed to a Linux Distribution called "docker-desktop" that is ran with WSL2. For some reason, ports 80 and 443 that are exposed from a container are NOT forwarded to the host.
The official documentation acknoledges some issues but their solution is just to use another port (for example, 8080 mapped to 80).
Issues with this method :
Each time you reboot your system (or WSL2), the Linux machine gets assigned a new IP and you have to do it again. What you could do is setup a command to run when your container starts that connects through ssh to the host and runs the script, but I'm too lazy to have done it myself.
03:32:35[Apache]Problem detected!
03:32:35[Apache]Port 80 in use by "Unable to open process" with PID 4!
03:32:35[Apache]Apache WILL NOT start without the configured ports free!
03:32:35[Apache]You need to uninstall/disable/reconfigure the blocking application
03:32:35[Apache]or reconfigure Apache and the Control Panel to listen on a different port
03:32:35[Apache]Attempting to start Apache app...
03:32:35[Apache]Status change detected: running
As log said, Port 80 is already used by another process
to check wich process use port :
WINDOWS: netstat -a -b
LINUX : sudo netstat -tulpn (must run with root)
To change the port of Apache, you have to modify this file:
APACHE_INSTALLATION_PATH/conf/httpd.conf and change this configuration Listen 80 to the port you want to use, example : Listen 8085
N.B: in your browser you must type this url http://www.mywebsite.com:8085 instead of http://www.mywebsite.com ( == http://www.mywebsite.com:80)
You must restart your apache server
I think that skype is using port 80, but i'm not sure
unable to install apache 2.2.Showing port80 and 443 allreday in use.
Help needed
Asmita
You have a webserver running already. Assuming you're on some version of Linux (you don't say) you can identify the process running on that port using lsof.
lsof -i :80
See here for more detail