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
Click Tracking IP Problem #413
Comments
I think the configuration is a little wrong, please remove the following lines Nginx is only for securing access to the admin web interface, the click tracking looks after itself. |
after changing the ip address to 52.237.75.66:80 and 52.237.75.66:443 in /etc/nginx/sites-enabled/default file. I'm Receiving an error
Here is the details
After changing it to again 0.0.0.0:80 and 0.0.0.0:443, Server was able to start. |
Oh hang on I misread what you said
You should remove those two server blocks, the only things in that file should be for the main app. After removing those blocks you should restart postal and use |
What Do you actually Mean by removing two blocks? Because if remove those two blocks nothing would be left behind Here is the full configuration in that file
I tried removing the listen line from both of blocks and i restarted the postal and nginx successfully. Here is what i got after netstat -lnp
|
can you send your postal.yml (minus confidential information of course) |
|
Also you can try running |
That's the real problem. I just don't know where to start from to add that secondary ip into main virtual machine. |
I suggest that you consult the azure documentation (unless someone who knows it is able to chime in) and come back later. |
Follow this to add a new ip address in Microsoft Azure After that make sure that the ip is attached to NIC in your VM. Type command Use that ip to bind address for fast server.
Restart postal server by |
Thanks for this Article, Now the IP is Working but when I'm opening that IP, It is showing the postal login page. Even the cname is also showing that login page. I think the listen parameter in /etc/nginx/sites-enabled/default is causing the hole problem. because the nginx server is confused which ip to handle and show the data. Now the problem is if i add the server redirects all request to postal login page if i add the primary ip such as listen 52.237.75.66:80; and listen 52.237.75.66:443 ssl; the nginx server starts giving error and does not restart. any other way to solve this problem? |
Can you share the results of |
Primary IP 52.237.75.66 Here is the output of ip a
10.0.0.4 is Private IP of primary IP Output of netstat -nlp | grep nginx
|
So 10.0.0.4 is either equal to 52.237.75.66 or 52.237.72.203 with 10.0.0.7 equal to the other one. You need to use 10.0.0.4 and 10.0.0.7 in If you can't figure it out from your azure control panel, you can presumably just try one combination and see what happens. |
I added listen 0.0.0.0:80 as 10.0.0.4:80 and now the secondary ip is showing "The connection to the server was reset while the page was loading". and if put it as 10.0.0.7:80 then it shows postal login page. |
Why are you listening on all ip interfaces when you have a primary ip assigned to redirect to your webui.
Change 0.0.0.0 to your primary ip for both ports 80 and 443. Let it listen on ipv6 instead. Replace you nginx conf with this
Make sure for an entry in /etc/hosts for Change the bind address for fast server to secondary public ip in postal.yml and make sure all dns records are configured properly. |
You can disable ipv6 forwarding by entering this to the end of
Run |
@zeeshanjamal16 That's the problem i Posted above that whenever i make nginx listen 52.237.75.66 or the secondary ip i get error saying
I have already posted that error in above post. & whenever i added private ip in listen, it didn't gave me any error. |
Reference of Ip http://res.cloudinary.com/cb1f716b3e979937/image/upload/v1511461264/Screen_Shot_2017-11-23_at_11.49.11_PM_mlml5z.png Nginx With all these configuration i showed you, Now the connection of tracking domain is being reset by server |
Your server is only aware of those two IP addresses so you can't use the other two in your configuration. Make nginx listen on 10.0.0.7 and set the |
Sorry I didn't see your screenshots, have you tried setting up some click tracking domains in Postal? |
Yeah check it here. http://res.cloudinary.com/cb1f716b3e979937/image/upload/v1511462050/Screen_Shot_2017-11-24_at_12.03.49_AM_mthcet.png The connection is being reset |
Can you share your nginx error logs? |
|
nginx isn't the problem, the issue is the click tracking server which doesn't use nginx. Can you do another netstat and |
It look like the problem with azure. On Amazon EC2/Azure, default they force for private ips. Can you please add following line in /etc/sysctl.conf. And after that listen on public ip instead of private and restart nginx. |
Can you also try by changing your smtp_server_hostname to mail.mozget.me instead of mozget.me after doing nonlocal_bind on ipv4. |
I have done everything you said, now the postal isn't working! |
Those changes aren't necessary so I would reverse them if I were you. The click tracking should appear on the netstat list but it doesn't look lilke 10.0.0.7 is on the list. Can you try undoing the above and restarting the server? |
Okay Done, I have reversed the settings we did |
Please reverse the changes. Let me match once it with my configuration. It is most likely DNS issue. |
If you want access to server you can have it |
Here is my dns settings according to your domain in postal.yml
In DNS panel, main settings are: rp.mail.mozget.me -> Primary IP |
Still No Luck., connection is being reset on track.mail.example.me and click.example.me |
I have kind of a same issue. I fixed nginx 0.0.0.0 problem. I am using a different IP for tracking. the web interface IP is the same as SMTP one. root@smtp-server ~ # sudo netstat -lnp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 78.47.223.2:443 0.0.0.0:* LISTEN 5863/nginx -g daemo
tcp 0 0 127.0.0.1:5000 0.0.0.0:* LISTEN 1984/[postal] web.1
tcp 0 0 0.0.0.0:25672 0.0.0.0:* LISTEN 1480/beam
tcp 0 0 127.0.0.1:3306 0.0.0.0:* LISTEN 1836/mysqld
tcp 0 0 127.0.0.1:783 0.0.0.0:* LISTEN 32206/spamassassin.
tcp 0 0 78.47.223.2:80 0.0.0.0:* LISTEN 5863/nginx -g daemo
tcp 0 0 0.0.0.0:4369 0.0.0.0:* LISTEN 1718/epmd
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1451/sshd
tcp6 0 0 :::25 :::* LISTEN 6113/[postal] smtp.
tcp6 0 0 :::5672 :::* LISTEN 1480/beam
tcp6 0 0 ::1:783 :::* LISTEN 32206/spamassassin.
tcp6 0 0 :::4369 :::* LISTEN 1718/epmd
tcp6 0 0 :::22 :::* LISTEN 1451/sshd
udp 0 0 138.201.116.6:60001 0.0.0.0:* 30690/mosh-server
udp 0 0 0.0.0.0:68 0.0.0.0:* 1166/dhclient
Active UNIX domain sockets (only servers)
Proto RefCnt Flags Type State I-Node PID/Program name Path
unix 2 [ ACC ] STREAM LISTENING 459868 30628/systemd /run/user/0/systemd/private
unix 2 [ ACC ] SEQPACKET LISTENING 8835 1/init /run/udev/control
unix 2 [ ACC ] STREAM LISTENING 8661 1/init /run/systemd/private
unix 2 [ ACC ] STREAM LISTENING 8669 1/init /run/lvm/lvmetad.socket
unix 2 [ ACC ] STREAM LISTENING 8670 1/init /run/systemd/journal/stdout
unix 2 [ ACC ] STREAM LISTENING 8833 1/init /run/lvm/lvmpolld.socket
unix 2 [ ACC ] STREAM LISTENING 9117 1/init /run/systemd/fsck.progress
unix 2 [ ACC ] STREAM LISTENING 12515 1/init /var/lib/lxd/unix.socket
unix 2 [ ACC ] STREAM LISTENING 12605 1404/iscsid @ISCSIADM_ABSTRACT_NAMESPACE
unix 2 [ ACC ] STREAM LISTENING 12511 1/init /run/uuidd/request
unix 2 [ ACC ] STREAM LISTENING 16041 1978/app) /tmp/postal/pids/procodile.sock
unix 2 [ ACC ] STREAM LISTENING 12512 1/init /run/snapd.socket
unix 2 [ ACC ] STREAM LISTENING 12506 1/init /run/acpid.socket
unix 2 [ ACC ] STREAM LISTENING 12513 1/init /run/snapd-snap.socket
unix 2 [ ACC ] STREAM LISTENING 12514 1/init /var/run/dbus/system_bus_socket
unix 2 [ ACC ] STREAM LISTENING 15744 1836/mysqld /var/run/mysqld/mysqld.sock
I did set tracking domain in UI. neither the tracking domain config in postal.yml nor the tracking domain I set in UI work. both of them fail to load. there is also no process running on port 5010 when I do try to setup ssl in UI, the fast process will fail after that and stays as failed. I have to restart postal to get it running again. that's probably another issue.
|
Can you run |
|
You'll see that the IPv6 address you're trying to use has been marked "deprecated" so I'd try taking it out of the Postal config file and see if that helps. If it does, you should troubleshoot with your server provider to verify that the IPv6 connection is fully working before trying to use Postal with it. |
@willpower232 I didn't have the IPv6 at first. Thought this might help fixing the issue. I removed it and still doesn't work |
In which case, I'd suggest going through the logs, locating an error message and opening a new issue with it. |
will do. can you tell me where would be logs for fast server? is this the only log I should check? |
I have installed Postal server on postal.mozget.me & i wanted to track postal emails but failed to do so.
Hosting provider - Microsoft Azure
RAM - 7GB
Server - Ubuntu
Ip - 52.237.75.66
Secondary Ip - 52.237.75.84 As you stated in the Documentation
I created an "A" Type with host track.mail.mozget.me and ip 52.237.75.84 but it doesn't seem to work.
I also created a CNAE with host click.mozget.me and ALIAS track.mail.mozget.me.
Maybe i'm not getting how to add that secondary ip to my Main Virtual Machine.
I'm aslo confused, Do i have to open PORT 5010 and 5011? as you stated "To facilitate the logging & redirection, Postal runs a separate web server process that listens on ports 5010 (for HTTP) and 5011 (for HTTPS). "
I even enabled the fast server with these detail
Now in the /etc/nginx/sites-enabled/default i added these details
Please Let me know where I'm Wrong, Or you can have access to my server and have a look
The text was updated successfully, but these errors were encountered: