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.

change default port

Discussion in 'General Discussion' started by bt4, May 21, 2012.

  1. bt4

    bt4 Well-Known Member

    Joined:
    Jul 1, 2010
    Messages:
    69
    Likes Received:
    0
    Trophy Points:
    6
    Hello,
    i have change default port apache 80 to other port from
    WHM > Tweak Settings for this option Apache non-SSL IP/port
    and i have restart appach why all websites do not work now?
     
  2. minosjl

    minosjl Well-Known Member

    Joined:
    Jun 4, 2011
    Messages:
    168
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    India
    cPanel Access Level:
    Root Administrator
    Hi,

    Did you checked the cPanel config file (/var/cpanel/cpanel.config) and change port 80 in apache_port assignment to 81:
    apache_port=0.0.0.0:81

    In the mean time run the command "/usr/local/cpanel/whostmgr/bin/whostmgr2 --updatetweaksettings" and check is the domains are working or not.

    If its not check the apache conf file /usr/local/apache/conf/httpd.conf for any occurences of port 80, and run /scripts/rebuildhttpdconf to make sure httpd.conf is up to date.
     
  3. cPanelTristan

    cPanelTristan Quality Assurance Analyst
    Staff Member

    Joined:
    Oct 2, 2010
    Messages:
    7,623
    Likes Received:
    21
    Trophy Points:
    38
    Location:
    somewhere over the rainbow
    cPanel Access Level:
    Root Administrator
    Are you trying the new port number in the url when you try to hit the site(s)? If you change the port, unless you are using a proxied connection like nginx or litespeed or something along those lines, it will require the port to be in the url when accessing the site.

    I'm uncertain where 81 was mentioned on changing it, though. The actual port number used wasn't mentioned nor why the port was changed, both of which would be useful to have :)
     
Loading...

Share This Page