Sponsored Content
Full Discussion: iptables - allow MySql
Top Forums UNIX for Advanced & Expert Users iptables - allow MySql Post 303015680 by damogallagher on Tuesday 10th of April 2018 06:38:19 AM
Old 04-10-2018
Quote:
Originally Posted by stomp
What do you mean by saying it is not working?

What exactly are doing(actually typed in commands)?
What is the exact error message you got?

What interfaces is your mysql server configured to listen to(netstat -ntlp)?
I mean I still cannot connect to mysql on my remote server.
The commands I am using are as follows
Code:
iptables -I INPUT -p tcp -m tcp --dport 3306 -j ACCEPT;
iptables-save > /etc/sysconfig/iptables
service iptables restart

I dont get any error message - just mysql cannot connect and appears to hang.

The result of netstat -ntlp is as follows
Code:
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name
tcp        0      0 0.0.0.0:48008           0.0.0.0:*               LISTEN      29057/perl
tcp        0      0 0.0.0.0:48009           0.0.0.0:*               LISTEN      29077/nimbus(cdm)
tcp        0      0 0.0.0.0:48010           0.0.0.0:*               LISTEN      29058/nimbus(snmptd
tcp        0      0 0.0.0.0:3306            0.0.0.0:*               LISTEN      6655/mysqld
tcp        0      0 0.0.0.0:48011           0.0.0.0:*               LISTEN      29059/nimbus(proces
tcp        0      0 0.0.0.0:48012           0.0.0.0:*               LISTEN      29060/nimbus(hdb)
tcp        0      0 127.0.0.1:38125         0.0.0.0:*               LISTEN      340/magent
tcp        0      0 127.0.0.1:46413         0.0.0.0:*               LISTEN      340/magent
tcp        0      0 0.0.0.0:48013           0.0.0.0:*               LISTEN      29266/nimbus(logmon
tcp        0      0 0.0.0.0:8400            0.0.0.0:*               LISTEN      23025/cvd
tcp        0      0 0.0.0.0:8402            0.0.0.0:*               LISTEN      23026/EvMgrC
tcp        0      0 127.0.0.1:42581         0.0.0.0:*               LISTEN      23025/cvd
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      5398/sshd
tcp        0      0 0.0.0.0:60056           0.0.0.0:*               LISTEN      23025/cvd
tcp        0      0 0.0.0.0:25              0.0.0.0:*               LISTEN      4899/master
tcp        0      0 127.0.0.1:8126          0.0.0.0:*               LISTEN      322/trace-agent
tcp        0      0 0.0.0.0:8192            0.0.0.0:*               LISTEN      339/mrouter
tcp        0      0 0.0.0.0:48000           0.0.0.0:*               LISTEN      12718/nimbus(contro
tcp        0      0 0.0.0.0:8193            0.0.0.0:*               LISTEN      339/mrouter
tcp        0      0 0.0.0.0:48001           0.0.0.0:*               LISTEN      12721/nimbus(spoole
tcp        0      0 127.0.0.1:7777          0.0.0.0:*               LISTEN      322/trace-agent
tcp        0      0 0.0.0.0:45249           0.0.0.0:*               LISTEN      23026/EvMgrC
tcp        0      0 0.0.0.0:8194            0.0.0.0:*               LISTEN      339/mrouter
tcp        0      0 127.0.0.1:17123         0.0.0.0:*               LISTEN      324/python
tcp        0      0 0.0.0.0:48007           0.0.0.0:*               LISTEN      12718/nimbus(contro
tcp        0      0 127.0.0.1:199           0.0.0.0:*               LISTEN      5648/snmpd
tcp6       0      0 :::80                   :::*                    LISTEN      1741/httpd
tcp6       0      0 :::52787                :::*                    LISTEN      1426/java
tcp6       0      0 :::22                   :::*                    LISTEN      5398/sshd
tcp6       0      0 :::3000                 :::*                    LISTEN      1426/java
tcp6       0      0 :::25                   :::*                    LISTEN      4899/master
tcp6       0      0 :::443                  :::*                    LISTEN      1741/httpd
tcp6       0      0 ::1:17123               :::*                    LISTEN      324/python

 

5 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

MySQL problem >> missing mysql.sock

MySQL on my server is down.... I figured out that the mysqld process isn't running. When I try to run it, it says it can't find mysql.sock Any suggestions? Here's what I can't do: can't be root don't have physical access (do stuff via SSH) reinstall MySQL (need to keep the current MySQL... (8 Replies)
Discussion started by: _hp_
8 Replies

2. UNIX for Advanced & Expert Users

mysql would not start: missing mysql.sock

I recently installed mysql-standard-5.0.21-solaris9-sparc-64bit.pkg on a Solaris 9 machine (SunOS 5.9 Generic_118558-19 sun4u sparc SUNW,Ultra-250). The package installation went very smooth, however, starting mysql is a different story. I get the message below everytime I try to start mysql: #... (2 Replies)
Discussion started by: xnightcrawl
2 Replies

3. Red Hat

MySQL conflicts with mysql-3.23.58-16.RHEL3.1

I am tring to install mysql 5.0 on redhat linux3. In this server mysql 3 is already installed and hence while I install mysql 5 it gives the following error. How I can install mysql 5 with out affect previous installation? bash-2.05b# rpm -i MySQL-server-community-5.0.41-0.rhel3.i386.rpm... (2 Replies)
Discussion started by: johnveslin
2 Replies

4. UNIX and Linux Applications

MySQL Daemon failed to start - no mysql.sock file

After doing a yum install mysql mysql-server on Fedora 14 I wasn't able to fully install the packages correctly. It installed MySQL 5.1. I was getting the following error when running the: mysql ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)... (3 Replies)
Discussion started by: jastanle84
3 Replies

5. IP Networking

Iptables Log in mysql

Hello all friends I am using ulogd with iptables to import iptables log into mysql but it is not working , Is there any way to log iptables log into mysql , i am using centos 6 Thanks (0 Replies)
Discussion started by: rink
0 Replies
All times are GMT -4. The time now is 09:23 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy