SVN 5221 failing to install on FOG server using proxy server


  • Moderator

    The 5221 trunk is failing to install on a centos 6.7 box. It worked for 5201 (I think)

    * Setting up SSL FOG Server...................................OK
     * Restarting Apache2 for fog vhost............................OK
     * Changing permissions on apache log files....................OK
     * Backing up database.........................................Failed!
    

    Digging into the install script code a bit, the issue is the sql backup script, wget and my FOG systems being behind a proxy server.

    The issue is the wget command that calls the sql dump page. With my fog servers behind a proxy server, to make the install script work I had to add the proxy settings to /etc/wgetrc file as well as the bash environment variables. I guess that wget is not smart enough to know that the ip address for the fog server is local and tries to access the poxy server for the page and gets a failed connection refused. Even tweaking the IP address in the command to 127.0.0.1 gives the same results. I need to have the proxy settings in place for wget or the rest of the install script will fail.


  • Moderator

    @Tom-Elliott

    That is pretty much what I have with the bashrc settings. The issue is that the no_proxy points to localhost and the script calls the fog server IP address [from my memory].

    BUT I could use bits of what you posted with something like this. (understand I already have the exports for the http_proxy… in my bash rc)

    no_proxy="<ip_add_fog_server>" ./installfog.sh -y

    That would allow the installer script to run unaltered and still tell wget to no proxy for the fog server IP address. I don’t know how big an issue this is or how many fog servers are behind proxy servers. I just wanted to get it documented for others that may find this post.


  • Senior Developer

    you could simplify the script for yourself.

    run:

    http_proxy=http://<proxy_server_ip>:<proxy_port> https_proxy=$http_proxy ftp_proxy=$http_proxy no_proxy="localhost" ./installfog.sh -y



  • I am having issues with the upgrade and I get the same error

    Backing up database…Failed! error

    Where do you get the export no_proxy=“localhost”… where is the bashrc file located and do I just add that in, or should that export no_proxy already be in the file?

    I see where to change the info needed in installfog.sh, but not the info mentioned above.

    Thanks for any help!


  • Moderator

    For clarity my bashrc file now has these settings in it because my fog installs are behind a proxy server. If your FOG server has internet access then these settings are not required.

    export http_proxy=http://<proxy_server_ip>:<proxy_server_port>
    export https_proxy=http://<proxy_server_ip>:<proxy_server_port>
    export ftp_proxy=http://<proxy_server_ip>:<proxy_server_port>
    export no_proxy="localhost"
    

  • Moderator

    Well I found a work around, but its not very elegant.

    If I update my bashrc file to export this env variable.

    export no_proxy="localhost"
    

    … and then change the wget command in the installfog.sh script from $ipaddress to locahost the backup script works as intended.

     wget --no-check-certificate -O $backupPath/fogDBbackups/fog_sql_${version}_$(date +"%Y%m%d_%I%M%S").sql "http://localhost/$webroot/management/export.php?type=sqldump"
    
    

Log in to reply
 

473
Online

38916
Users

10688
Topics

101382
Posts

Looks like your connection to FOG Project was lost, please wait while we try to reconnect.