$Id: INSTALL 6 2006-03-03 23:10:38Z ggw $ --- Intended Audience Linux BASH users or similar. Postfix admins. People that want to learn the last two mentioned areas. mySQL fanatics. And of course: ISP owners, admins, and managers. --- New See CHANGES file for details. --- Prerequisites mySQL server and client libs installed and running on same server as the application. You must know the root password. (Paranoids: Check the install script in mainfunc.h) Use find . -name mysql.h and find / -name libmysqlclient.a to get paths. Edit makefile and mysqlrad.h for these if needed. If using FreeBSD (or other that needs gmake defines in makefile) make sure that FreeBSD=1 is in makefile at top. You can change useradd/userdel and usermod commands to customize for your system see relevant mysqlPostfix.tConfiguration entries for details. Must have a running Apache server on the same server with cgi capabilities. Should be SSL enabled if possible (see below for intranet or other just "testing" non-SSL setup.) Typical setup involves user openisp httpd daemon on some random port number like 9023 for non SSL and 8045 for SSL connections. ~openisp should have everything mysqlISP related in it (More on this below.) Note that MD5 support requires at least glibc2. --- Example BASH Install Instructions (Must edit makefile and use GNU make on FreeBSD builds. Usually gmake) shell>tar xzf mysqlPostfixN.M.tar.gz (Where N.M (Ex 1.43) is the latest Major.Minor version available at openisp.net/mysqlPostfix) shell>cd mysqlPostfix shell>export CGIDIR=/apache/cgi-bin/ (or whatever your Apache cgi-bin dir is) shell>vi local.h shell>vi makefile shell>make (or "# SSL=1 make" if you are using mysql libraries compiled with OpenSSL) shell>make install shell>export ISMROOT=/home/joe (or whatever directory the mysql application project folder/dir is in) shell>chown mysql data shell>chmod o+x $ISMROOT (make sure mysql daemon owner can access the initial data files. If this fails you need to drop database mysqlpostfix via mysql command line) shell>/cgi-bin/mysqlPostfix.cgi Initialize This will setup application and allow you to login as user "Root" password "wsxedc" --- Upgrade from 1.5n /mysqlPostfix.cgi UpgradeSchema --- Non-SSL Setup If you have an SSL server handy edit local.h and remove comments: //#define SSLONLY like so... #define SSLONLY Then shell>rm *.o shell>make --- Read tutorial.html very short docs/tutorial.html copy this file somewhere browser accessible. Or even just 'more/less' it etc. --- Mail-Gateway Configuration Postfix non amavis anti-spam and anti-virus setup files and a script provided. --- Standard OpenISP setup backup operations (Loose instructions adjust to fit for your particular setup) shell>useradd -d openisp shell>mkdir -p ~openisp/mysqlPostfix/data shell>chown mysql ~openisp/mysqlPostfix/data shell>crontab -e Adding the following: Where mysqlpasswd is replaced by YOUR real mysql root passwd. # #mysqlPostfix # ##backup 20 3 * * * ISMROOT=~openisp;export ISMROOT;/cgi-bin/mysqlPostfix.cgi Backup mysqlpasswd > /dev/null --- Other backup ideas You should probably cross server backup all your OpenISP module data like so. Note that this involves using GRANT ALL mysql statements and a very secure internal ISP LAN. See mysql manual. Think about ISP organization with edge servers with 2 NICs and an ISP admin firewall zone with the mysql database server or replication cluster servers. Smaller ISP ideas: All servers should have internal mirror backup drives or other cheap fast and reliable backup system (NFS and cpio in ISP admin firewall zone?) shell>crontab -e Add something like the following after setting up mysql for remote access from ONLY the IP in question in a VERY secure LAN (non routable IP's...switched hubs...behind firewall...etc) #Extra backup of mysqlPostfix data only even days, using mysqldump from 192.168.100.23 20 4 * * */2 /usr/local/mysql/bin/mysqldump -e -h 192.168.0.43 -u mysqlpostfix -pwsxedc --all mysqlpostfix > ~openisp/mysqlPostfix/data/dumpall.txt -- Lose your data and your fired Don't be lazy backup and re-backup and database warehouse your mission critical data ALWAYS! If you need help ask us. --- Legalese This doc is GPL. Don't forget to give us credit when you quote this stuff. Copyright 2003-2006 Gary Wallis. --- tConfiguration name/value pair cLabels optionally used. Will expand this section with more info. Widely used configuration name/value pairs are documented and shown in provided tConfiguration. cAccessFile cAliasFile cAnnounceList cCryptMethod cESMTPServer cExtJobQueueDbIp cExtJobQueueDbLogin cExtJobQueueDbName cExtJobQueueDbPort cExtJobQueueDbPwd cExtJobQueueDbSocket cGID cHomeDir cHomeDirPreFix cHostmaster cISPContactEmail cISPFromEmail cISPParameter cImapMail cLocalFile cMTA cMailGID cMakeAccess cMakeLocal cMakeVUT cMbox cMySQLRootPwd cNewaliases cNoAliasIfInUser cOnlyClearText cPopShell cUserAdd cUserAddWithHomeDir cUserDelCommand cUserModForHomeDir cUserModForUIDError cVUTFile cuAPop cuHDQuota cuMailFilter cuTrafficQuota --- Many Thanks To www.sendmail.org www.postfix.org