The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

apache listen [::]:80

Discussion in 'EasyApache' started by izghitu, Feb 8, 2014.

  1. izghitu

    izghitu Well-Known Member

    Joined:
    Aug 9, 2006
    Messages:
    45
    Likes Received:
    0
    Trophy Points:
    6
    Hi,

    I am trying to make apache listen on the main server IP only and I changed the listen address in tweak settings. After I rebuild the httpd conf and restart it does not work because there's always a Listen [::]:80 directive that conflicts with my IP:80 directive.

    Can you please tell me how do I remove that [::]:80 Listen directive?

    Thanks
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,675
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    Please use the following option to ensure Apache only listens on the IP addresses of you preference:

    "WHM Home » Service Configuration » Apache Configuration » Reserved IPs Editor"

    Thank you.
     
  3. speckados

    speckados Well-Known Member

    Joined:
    May 21, 2003
    Messages:
    291
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Acequias :: Granada :: España
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    Hi.

    I've several server and any has a Ip marked on "WHM Home » Service Configuration » Apache Configuration » Reserved IPs Editor"

    But one server are the same problem.

    Also after select IP form WHM, apache not work on any IP selected.

    Code:
    Listen [::]:80
    You can clarify?

    /https://dropbox.tamainut.net/owncloud/public.php?service=files&t=a0a40989f4c8e3bdbfce533cccced7db
     
  4. vanessa

    vanessa Well-Known Member
    PartnerNOC

    Joined:
    Sep 26, 2006
    Messages:
    817
    Likes Received:
    22
    Trophy Points:
    18
    Location:
    Virginia Beach, VA
    cPanel Access Level:
    DataCenter Provider
    Screenshot URL isn't working.

    Docs on the solution suggested by cPanelMichael:

    https://documentation.cpanel.net/display/ALD/Reserved+IPs+Editor

    There's a similar thread here:

    http://forums.cpanel.net/f5/apache-still-listens-reserved-ip-301602.html

    And here's an alternate solution:

    Code:
    cd /var/cpanel/templates/apache2
    cp main.default main.local
    
    The edit main.local to customize the Listen directive. Specifically, you're looking for this:

    Code:
    [% IF configured.ip_listen -%]
    [%- FOREACH ip IN configured.ip_listen -%]
    Listen [% ip %]:[% configured.main_port %]
    [% END -%]
    [% ELSE -%]
    # Defined in /var/cpanel/cpanel.config: apache_port
    Listen [% main.listen.item.listen %]
    [% END -%]
    
    Then rebuildhttpdconf and restart.
     
Loading...

Share This Page