Installation Steps

A. Install PHP

  1. Download the PHP MSI installer from a mirror here: (5.2.2 is the latest version as of 10.05.2007, I am using 5.2.0).
    You can check for newer versions on this page:, follow the link to Windows Binaries, PHP <version> installer.
  2. Install the package by double-clicking it. It doesn't matter where you install it to. To keep file paths simple I suggest you install it to the root of a partition, though, and not under Program Files. I installed it to "E:\php-5.2.0" and that's what I will be using in this guide. So, if you use a different path, use that instead of "E:\php-5.2.0".
  3. Options you have to set in the setup wizard:
    • Web server setup: do not setup a web server
    • Choose items to install:
      • Program: install the whole feature (this will enable "script executable" and "Register PHP")
      • Extensions: you can install all if you want ("entire feature"), or just what we need: Mcrypt and Curl
      • Web Server Setup: none
      • Extras: you can install "entire feature" or just "PEAR Install" (recommended) or nothing.
        So, you can install "entire feature" for all options except for "Web Server Setup" which we don't need at all. Do not enable all extensions by default if it asks you to do that as it only adds higher ressource usage.
  4. Install the right php.ini: move the php.ini from our vaos-feeder pack to your PHP directory.
    Adapt the path in the first two lines to your setup:
    • include_path = ".;<your PHP PATH here>\PEAR"
    • extension_dir = "<your PHP PATH here>\ext"

PHP Setup is done. Now let's setup the Feedservice.

B. Install the Feedservice

  1. Close VA.
  2. Unpack the and copy the content to the destinations:
    • copy the "Feeds" directory to your VA messagebase directory
    • copy the "Feedservice" directory to your VA messagebase directory
      "Feeds" is the service directory that will contain the folders and messages
      "Feedservice" contains the program and configuration data.
  3. Check if "Feeds" is recognized as a service: open VA and then open File, Comms Setup and check if "Feeds" appears in the service list. (You have to close VA and reopen it if you added these directories while it was open!)
  4. Set the VA path: open Feedservice\config\config.ini in your messagebase directory and edit this path to fit your setup: vamessagepath = "P:\VirtualAccess".
  5. Copy the downloaded new import32.exe over the existing import32.exe (keep a backup of the old file!)

C. Test PHP

Open a command window in the Feedservice directory and type php phpinfo.php. This should produce an output of your PHP configuration that quickly runs thru. If you get an error instead, something is wrong. If you want to get a readable output for debugging redirect the output to a file: php phpinfo.php > phpinfo.txt.

D. Test the Feedservice

Type php feeder.php. This will test-fetch the preconfigured feeds and put them in the Feeds directory. You will also get some debug information depending on the debuglevel set in config.ini. The default it is set to in the beginning is 2. That lists the feed names and the articles. You should see the feeds and articles running thru (depending on the speed of your connection and response time of the remote site) and at the end a list that lists the "NEW ARTICLES".

If that is what happens the Feedservice seems to be working fine. You can now open config.ini again and change testing = 1 to testing = 0. This tells the Feedservice to operate in normal mode. Now run php feeder.php again. It should now fetch the articles and put them in the temporary queue directory for import.

If something different happens and you don't get a breakdown of the articles something is wrong. If it affects only one feed it may be temporary, otherwise something's probably not correctly installed. Go to the Troubleshooting and Testing pages for more information how you can troubleshoot the Feedservice. You may also discuss the problem in

You can rerun the command above each time you want to refresh your feeds. However, before you do it again you have to run import. If you don't run import before fetching another set you'll loose the first one, because each run resets the import database. So, go to the next step now before you fetch again.

E. Import the feeds

  1. If everything went okay you should have some "feednnnn.dat" files in your temp\feeds directory.
  2. Now run import. We need the new import with feeds support that is on the "Downloads" page for the Feedservice. Open a command window in the VA directory and type import32 /feeds. This will launch an import window that quickly imports your first feed.
  3. In case VA is open: close it. Then reopen VA and look if you have a new service folder in the messagebase pane called "Feeds". If so you should also find a few nodes with the freshly imported feeds in it.
  4. actions.information for the Feeds service should show you a list of the imported feed messages.
  5. Rerunning php feeder.php and then import32 /feeds will update the feeds. (Note, that one command has to be issued in the Feedservice directory and the other in the VA directory.)

F. Making it all automatic

Once you are at this step and everything seems to work fine you can automate the import process. Open config.ini (in the Feedservice\config directory) and change auto_import = 0 to auto_import = 1. This will do the import automatically for you immediately after feeds have been fetched. Note that an import will take place even when no new messages arrived. That is because we create an actions.informations file for each run of the feeder.

For non-developers here's the finish line at the moment as you need a newer version of va32.exe for the next step to work. However, if you want to fetch feeds on a schedule you can still do this without that newer va32.exe. You can use the Windows Task Scheduler service. The Windows Task Scheduler service can only run executables and not files associated with an executable. Therefore, you have to use a command file that contains the necessary command line. Such a file is provided as feeder.cmd in the contrib directory. It will do the same as if you ran the Feeder manually. There is only one difference: it uses php-win.exe instead of php.exe. php-win.exe is a special version of php.exe that creates no output, which means that the scheduled run will almost not be noticable. You will only see the command window for feeder.cmd open and close after a while and then for a short time the import dialog. The time for fetching the feeds is dependant on your connection speed and the response time of the sites, so be patient if the empty command window seems to stay "forever" - it will eventually close.

G. Doing it all in VAOS

For this to work you need a new version of va32.exe that recognizes the new Feedservice and the differences to other services. At the moment this is only available from CVS. You can run Feeds from Connect like any other service and you can also use the scheduler to schedule the connects for the feeds service. As feeds do not change that often I suggest refreshing the feeds only once per hour. A run will always refresh all feeds. When run this way you won't see the familiar inet32 window, you will see nothing as php-win.exe doesn't produce any noticable output. Once the feed fetch is done you will see import32 being run very shortly (unless there are lots of messages to import ...). When run via scheduler you will see the scheduler appear on the taskbar and apparently be stuck since no other action is noticable. Don't kill it! After a while it will finish and run import.

vaosfeeds/installation.txt · Last modified: 29.06.2007 00:09 by kai
Recent changes RSS feed Driven by DokuWiki