Forum OpenACS Q&A: 2 IPs, Apache, OpenACS/AolServer, 1 machine...?

Heya

I have a machine with two IPs assigned to it.  Is it possible (and
how do I) assign the second, newer IP to openacs and aolserver?  Is
there some force host entry I make somewhere?

Thanks
Dave

Collapse
Posted by Bryan Che on
Yes, you can specify in your AOLserver ini file to what IP address and port the server responds. In the section,

Take a look at http://aolserver.com/docs/config.adp

and pay attention to the section that specifies:

#
# Socket driver module (HTTP)  -- nssock
#
ns_section "ns/server/${servername}/module/nssock"
ns_param   port            $httpport ;# Port for HTTP (typically 80)
ns_param   hostname        $host     ;# This is not the same as your hostname
ns_param   address         $address  ;# This is not the same as your host addr
ns_param   location        "url"     ;# URL for auto-redirects (trailing slash)

You also need to make sure that you have both IP addresses setup on the box. ifconfig -a should tell you if they are.

Collapse
Posted by Mat Kovach on
You have to check the config for apache first, look for the line: Listen and put the ipaddr:port
[shagster@foobar mail]$ grep 'Listen [0-9].*:[0-9].*'
/etc/httpd/conf/httpd.conf 
#Listen 12.34.56.78:80
Listen 10.210.0.104:8000 
Note: You'll most likely use port 80. In your aolserver config, look for:
[shagster@foobar aolserver]# egrep '(http.*port|address)' 
/etc/aolserver/nsd.tcl 
# If httpport is set to 80, you'll have to start AOLserver as root and pass the user 
set httpport              8000
set httpsport             8443 
set address               "10.210.0.105"
That is what I do, and it works for me.