Forum OpenACS Development: Ideas for easier installation of OpenACS

Doesn't everyone love installing OpenACS? Of course, so this thread probably isn't for you. I'm only talking to those developer who would rather be doing something else besides installing, or debugging an installation, or figuring out how to add another socket or module, or reconfigure the installation.

Okay, now that I have narrowed down the field, here are some ideas:

1. File based signaling of configuration. This is the basis of all the following ideas.

2. Servers can be added without editing existing files.

3. Sockets can be added without editing existing files.

4. Database modules and pools can be added without editing existing files.

5. A single server startup error will not affect other servers.

6. A server can be removed from startup by touching 'down' in the server config area (no editing of files).

7. A server can be run 'once' by touching 'once' in the server config area.

8. A server can stay up by touching 'up' in the server config area. (= default with none of up/down/once).

9. Very simple administrative module for adding/testing database drivers and nssock modules, and with the ability to allow module writers to hook into this feature. (probably just a tcl/adp script/pageflow.) Module writers could probably use this during development as a debugging tool.

All of the above are mostly focused on speeding up the path to getting to the real goal: installing your application and keeping it running. In this case OpenACS, but really for anyone using modules from various origins.

Some of these features I have working, but the basic ideas (1-4 above) haven't been worked on. The biggest success is 5, where errors in one nsd server don't affect the startup of others. 6-8 were easy to add given the division of server configs into individual directories. But I haven't gotten to the point where module configuration becomes part of the module installation, and not something tacked on (copy, paste) to a long configuration file. In general there is no way for module developers and maintainers to store configuration, installation, testing and documentation files for AOLserver modules.

Individual module maintainers don't suffer, but their potential customers do suffer. And future changes to AOLserver modules or other API sometimes lack this critical information. With OpenACS, there are so many modules needing to be added that it becomes painful for even experienced developers to stop interesting work and install a new OpenACS site.

So two additional goals: new config directories/files for any code which uses configuration information and new installation methods which can be automated because they don't require editing existing files.

Whatever the result it has to be easily comparable with the current config setup.

One thing I noticed was that config sections look a lot like directories. It may be possible to apply a few conventions so that conversion from the current config to the new structure (and back, obviously) would be automatic. (I'm not sure exactly how much this applies, but something like the /proc filesystem seems applicable)

Collapse
Posted by Tom Jackson on
One thing I noticed was that config sections look a lot like directories. It may be possible to apply a few conventions so that conversion from the current config to the new structure (and back, obviously) would be automatic. (I'm not sure exactly how much this applies, but something like the /proc filesystem seems applicable)
For instance if map = {
  HOME /usr/local/aol/config 
  SECTION ns
  SERV1HOME /web/oacs/config
  SERV1SECTION ns/server/serv1
}

Then HOME + /parameters => /usr/local/aol/config/parameters
and SECTION + /parameters => ns/parameters

SERV1HOME + /modules => /web/oacs/config/modules
and SERV1SECTION + /modules => ns/server/serv1/modules   

Collapse
Posted by Brian Fenton on
Hi Tom,
I don't understand "File based signaling of configuration" - what does that mean?

thanks
Brian

Collapse
Posted by Tom Jackson on

The current situation is that to add a server, you first add a line to a central file:

ns_section ns/servers
 ns_param server1 "Original Server"
 ns_param myserver "New Server"

# then a config section
ns_section ns/server/myserver
 ns_pram ....

The same thing is repeated for each thing you add: ns_sock modules, database pools, etc.

With everything in one file, any typo (this is a tcl script), or even certain other errors can cause the entire startup to abort and loop over and over. So adding anything to a working file is error-prone, with the potential to bring down everything using the file.

Several years ago I started experimenting with a new idea, which was to have each virtual server (server1, myserver) keep their configuration in their own directory, next to pageroot, and the modules directory:

servers/
        server1/
                pages/
                modules/
                config/
                       server.tcl
                       nslog.tcl
                       nscgi.tcl
                       nscp.tcl
                       threadpool-default.tcl
                       ...
                       

When I add a new server, I simply copy this directory and make a few changes where needed, maybe comment out a few modules I don't need. But then I'm still stuck editing main server config file so that it knows about the new server.

This is okay, because I have scripts which source the above files, and if there is an error in sourcing, the server is not added to the system, the others come up normally. The scripts also log what didn't work so the error is easier to track down.

But I also did work on the main level scripts so that it was easier to determine what the configuration was without hunting through a bunch of files. This works but is awkward and still requires editing the main file a little, but somewhat more safely.

The next 'advance' was to include a few helper procs, so that my top-level file starts like this:

# Set Main Server Variables:
namespace eval ::config {

    variable Home      /web/nsd45
    variable ConfigDir [file join $Home config]

    source [file join $ConfigDir lib config-procs.tcl]

}

# Override default values in config:
namespace eval ::config {
    variable Debug 1
    variable StartupScript [file join $Home [info script]]
    variable ErrorFile "/tmp/errors-from-[string map {/ _} $StartupScript].txt"
}

# Virtual Server / Socket Config:
namespace eval ::config {

    addServer jnm "Junom Server"
    addServer tutos "Tutos tWSDL"
    addServer server1 "Simple Server"
    addServer openacs "OpenACS" "/web/openacs-5.2.3/config/server.tcl"
    addServer oacs "OpenACS 5.3.2" "/web/openacs-5-3-2/config/server.tcl"
    addSocket nssock1 192.168.1.102 8001
    addSocket nssock2 192.168.1.102 8005
    addSocket nssock3 192.168.1.102 8000
    addSocket nssock4 192.168.1.102 8002
    addSocket nssock5 192.168.1.102 8003
    mapHostsToSocket jnm nssock1 {maria junom}
    mapHostsToSocket tutos nssock2 tutos
    mapHostsToSocket server1 nssock3
    mapHostsToSocket openacs nssock4
    mapHostsToSocket oacs nssock5
    setDefaultServerForSock jnm nssock1
    setDefaultServerForSock tutos nssock2
    setDefaultServerForSock server1 nssock3
    setDefaultServerForSock openacs nssock4
    setDefaultServerForSock oacs nssock5
}

There are several catch-22s in server startup that I avoid. One is the defaultServer for a sock. If the default server for a sock doesn't come up, the entire process aborts! For some reason it is okay to have a sock that isn't used (AOLserver removes it automatically), but not having a default server for a sock is fatal.

The above script still requires creating files in correct places, but it is easier to put in variations. Notice that I have regular old AOLserver virtual servers, and two OpenACS installations. OpenACS uses a different path structure, so the default of where server.tcl exists, is overridden by the direct path. It is very hard to use a single file (with typical variables set at the top) in this situation, and most users would be left struggling to make a copy of what they need with a few small changes, put that in a new file and try again. Then all the upstream scripts have to change, developers no longer know where to even find the configuration file for a given server. Of course once they find it, it is just like reading a tcl script and trying to imagine the output. When your server is down, this is not fun. If everyone's server is down, you have a real problem.

Anyway, even the above setup is confusing to me and I wrote the code. Fortunately, the script does print out what it is trying to do and what fails to work, so I can always look at the server.log to track down what isn't working, that is, I can track down what I did wrong. Also, the real issue is that this process cannot be automated. You cannot automate adding a line to the middle of a generic file. You can patch source code, but you can't patch configuration files. This is a big gap in AOLserver, where installation and configuration are of secondary importance to code development, or maybe just not on the radar. It is typical to write C code which checks for a config section, and if it is missing, uses a default. There is no indication to the module user that these configurations settings even exist.

For example, recently I added a Ns_Log statement to the config lookup code. Now, every call to look for something stored in the server config structure is logged (even Tcl modules). Unfortunately I don't get information on who is calling the config API, but I do get a time ordered list of what is looked for. It is amazing how many undocumented config params exist in AOLserver, and a lot of the ones being passed around in current config files are no longer used.

File based signaling of configuration could accomplish a simplification and rationalization of the above ad-hoc process and it would provide a development framework for integration of code, installation and configuration (for instance, nobody would be happy if there wasn't a 'make install' target for modules, and nobody would be happy if you didn't have revision control over your source code. If module configuration becomes part of the source code, you get this benefit with very little extra work, and you can automate it more easily.

The details are not completely obvious, but the main principle should be simplicity in design and operation. The end result of sourcing a config is a static set of data. All of this is added _before_ AOLserver starts to act on the information. All the information is added, and errors potentially occur, before AOLserver has a log file to log errors! So config processing should be verbose and explicit, but the rules for processing should be generic enough, and few enough that a simple script could produce a static config that won't crash the startup and would report any config errors and the result: db driver not found, server config skipped because 'down' exists, ip address is invalid for sock. Probably the script, if run from nstclsh would produce logging information, diagnostics, and output a static script containing only ns_section and ns_param calls. Then you could test configurations independent of the server startup, or if you had a config problem, you could run the script on the problem area so you could ask for help in diagnosis.

Collapse
Posted by Dave Bauer on
Tom,

Can you explain the benefits to this setup as opposed to running seperate NSDs for each web site you wish to serve?

Right now, my clients each have a seperate virtual machine which contains the install environment. This suits clients who have seperate customizations and versions of supporting code that are not necessarily in sync.

Collapse
Posted by Tom Jackson on
I seem to always get off on a tangent and forget to talk about the main point: easier installation of modules (at least the configuration part). There are some additional complexities associated with using nsd virtual servers, but the general idea is the same for a single server installation. In fact, you might benefit more, because you have to do complete installs for each customer. The last openacs I installed this weekend took no more than 10 minutes to copy and edit a few files, create a new database and restart the nsd to pick up the new server.

If everything is in one file this process would become more error prone, especially for the new user.

What is intended is an installation process which is used by novice and expert because it is easier and faster for both.

I think I need to write a little bit of code to explore and explain the idea further. Of course none of this is intended to be a requirement, but more as an additional way to install modules so that configuration is included in the process.

Collapse
Posted by Robert Taylor on
tom, not to be a party pooper ...

... but, as i humbly understand it, aolserver really and trully isn't designed to be a virtual host because there is no guarantee of thread safety between virtual hosts cannot be guaranteed.

... i have read that a gentleman by the name of zoran has a patch for an older version of aolserver to allow for virtual hosting BUT it's never been maintained because no one has really ever used aolserver for virtual hosting.

while i would welcome this native capability, the initial goals generally put aolserver in the category of running large scale web based applications where one wouldn't generally see virtual hosting.

with that being said, as i'm digging more into code it self, i see the openacs framework as a fun and fast way to dev in comparison to others i have tooled around with, so its not as if it's inconceivable that by having virtual hosting we would attract a different kind of developer crowd as well.

appologies if i have mis-stated my understanding, but i had a good few conversations about this particular thing with Dossy ... can virtual hosting trully be supported under aolserver?

i understand there is a european group that has put oacs on an aolserver fork called naviserver (reverse fork perhaps?), maybe that has some of the features that would allow for this?

gladly looking forward to comments on this topic.

Robert,

First, this has nothing to do with commercial mass virtual hosting, as in an Apache style web farm.

As far as informing me on the subject as related to AOLserver, you might look back over my postings and software related to virtual hosting for the past eight or so years.

Since I wasn't in on your conversations with Dossy, it is hard to comment on it. Personally, I would ask your questions in a public forum so that any misconceptions can be caught. Just a few months ago I was stupidly claiming that AOLserver's static file performance wasn't that hot. Boy, was I wrong! Other than being beat on large file performance by lighttpd, AOLserver beat every other server.

One thing I agree with in your statement, and I have said it many times: AOLserver is not designed for _mass_ virtual hosting. But why? Because virtual hosts in AOLserver take up resources even if nobody is visiting the site! They are all up and running all the time. So if you do the math, just add up the memory footprint for each of your AOLserver instances if they were to run all alone, and that is pretty close to the combined total. You will save a little bit in overhead, but not enough to think about.

Another thing you would learn (about my opinion) from reading my previous posts on the virtual host/Apache envy front is that I strongly advocate against any attempt to emulate Apache. If Apache works for you, go for it. There are some on the AOLserver list which think that is where the software should go, but it only shows up when there is the periodic call for some direction for that community. Somehow there is a severe shortage of IP addresses, and folks can't figure out how to run AOLserver and Apache on the same machine. Basically it is not a software issue. AOLserver is an integrated application server for massive applications, not for serving masses of tiny toy websites.

The thread-safety thing needs to be addressed, because someone might think there is some issue. This is insane: AOLserver (actually the original commercial product NaviServer) made Tcl thread safe, at least in AOLserver. Apparently the channel code was not quite safe, but AOLserver used C based programming in this area, so it didn't matter. Now, Tcl channels are threadsafe and they are being used more in the AOLserver core.

But it is hard to tell exactly what the comment about thread safety between virtual hosts actually means. It probably means much less than what you think it means. Obviously, AOLserver can load shared libraries which are not fully thread safe, as can any C application, and what happens is a matter of chance.

Zoran has contributed much to AOLserver and Tcl, but I have no idea what the patch is since I don't know of any problem with virtual servers and multiple servers running in one AOLserver instance.

First we need some definitions on this subject. AOLserver can do several related things:

  1. One instance of AOLserver can listen on multiple IP/port combinations. Each of these listeners is a separate instance of nssock.so. But I believe you can also listen on all interfaces (0.0.0.0) with one nssock. This is typical of any server. But each instance of nssock uses a separate driver thread to handle incoming connections.
  2. One instance of AOLserver can load multiple servers (like an OpenACS instance). These servers are isolated, code-wise from each other. Two different instances of OpenACS will not interfere with each other, they can run side-by-side in the same process. However, due to the ability of any of these server instances to spy on other instances, or restart the process, I have never recommended combining multiple clients in one instance of AOLserver.
  3. Each loaded server can be a virtual host for incoming connections. That means that the driver threads look at the Host: header and figure out which server to use. In addition, the url is looked at to select a connection threadpool. It may seem weird at first, but drivers belong to the entire process. Each driver thread divides up the work based upon Host and url into threadpools. In addition, regardless of what threadpool is used, a server interp is placed in the thread based upon which server is used.

Naviserver is a fork of AOLserver 4.0.10 which as also ported some of 4.5 code. As others have pointed out, and I have confirmed with my testing, naviserver uses less resources. I only did static file serving, so it was a limited test. But AOLserver4.5 also outperformed naviserver by a good margin, at least 20%. AOLserver4.5 has improved driver code, and a few more threads, so that may account for the extra overhead and better performance.

If performance is critical for you, remember that it is easier and cheaper to add more ram than it is to add and maintain another machine. A product which delivers better performance with more ram is eventually going to be the better product, so the 'less resources' claim for naviserver has limited value.

On a shared machine (real virtual hosting!) you can run more naviserver instances and let those instances fight over the CPU and I/O. But as soon as you have a single application which might spill over to multiple machines, application performance becomes important, not the memory footprint.

So can AOLserver do virtual servers/multiple servers/etc.:

I decided to run an apache-bench on two servers in one instance of AOLserver. One server is running OpenACS-5-3-2 and I grabbed the home page. The other server is just a simple server. I grabbed a page which passes the request off to a worker thread, same as Gustaf uses for background delivery. It returns a 28k image file.

I hammered OACS with just 10 concurrent requests for 5000 total requests and hit the other server with 10000 request
with concurrencies of 20, 20 and 40. I've posted the logs at
http://junom.com/document/aolserver/apache-bench/

There is also the top of the startup log showing multiple servers being loaded and mapped to various Host headers.

In all cases, the concurrencies are above the number of threads in the pool.

I'll do another post today to hopefully better explain the config install proposal. In short it doesn't have too much to do with virtual servers or multiple servers in one nsd, it just has to do with distributing the configuration setup to multiple files so that the configuration can be added automatically during software installation.

Collapse
Posted by Robert Taylor on
oh and i swear, i will get someone to add post editing functionality in our forums!

sorry if a few sentences are poorly formed, posted at 12:35 am.

Collapse
Posted by Robert Taylor on
Tom appologies if I came accross that way!

😊

You are correct I should of checked posting history.

My intention was only to learn, I am out of my league on this topic.

Thank you for the input, I'm learning a lot.

Collapse
Posted by Robert Taylor on
Tom, also thank you for all the information you are posting here and other threads.

Lots if low level information to chew on for those of us that don't really get that close to the implementation.

Collapse
Posted by Vic May on
Can somebody PLEASE create an easy installation the way XAMPP does it at http://www.apachefriends.org/en/index.html ---
it is like this --- download, untar/unzip, start. AGAIN -- download, unpack, start!!! It runs right from the default installation directory. No configuration needed, no hunting for missing libraries, no chasing weird errors. If they could make it work that way, I think it's possible to do the same for OPENACS. This is my second attempt to install OPENACS and I am thoroughly disgusted. I spent hours on the first try -- compiling aolserver. On the second attempt I found out that I can just simply install aolserver by using "apt-get install" in Ubuntu. One headache gone. But not so with OPENACS. I have finally managed to to put everything in place, even aolserver starts with openacs config file. But now, there is a missing libnspostgres.so library. Why would it be missing beats me. Why isn't it there by default beat me. Why there is no info on the web about it beats me. And after spending hours and hours reading and researching I give up. I loved the idea, I love that TCL is being used as the programming language but now I see why no one is using OPENACS. Of course, if somebody has done the installation hundreds of times, the installation may seem easy. But I can't afford to spend hours, days and weeks on every applicatoin that I need to install. No one can.
Collapse
Posted by Dave Bauer on
This is a good suggestion,

For OpenACS I suppose it means
1) AOLserver + modules
2) PostgreSQL
3) Tcl
4) OpenACS or .LRN (or both...?)

Maybe a first step is just an AOLserver with all the appropriate modules included. It should be possible to distribute the source of AOLserver from OpenACS,org and keep it up to date, it doens't get released too often.

One fix for this particular problem is to make sure you have aolserver4-nspostgres package installed from ubuntu/debian.

Collapse
Posted by Tom Jackson on
I once had a working installer calle app-install. It was mostly for handling the problems with the stack Dave has just listed. I'll describe that in a second, but first a more general point:

OpenACS and the software it relies on are not Apache. The main difference is that you can install one version of Apache and everyone on a machine can use it. It is a system wide service like tar, less or whatever. AOLserver is not a system wide service. You can't build AOLserver with the standard Tcl distribution, you need to enable threads and other things. You may not want AOLserver to rummage around the entire system looking for Tcl packages which may also not have been compiled with the correct switches.

On the other hand, just try to install a new version of Apache on an old version of Linux. Forget it. If you have an older machine which still works very well, but has an old OS, you are totally screwed if you want a new Apache.

AOLserver has very specific, but easy to meet requirements. These requirements are not found in the standard installations. Beyond that, OpenACS and AOLserver are best considered as user applications. A single user installs and maintains all the components, and if another user wants to do the same, there is no problem. If software was installed to a central location, management would eventually, maybe quickly, become impossible.

Now, that was just a description of the basic problem, what is the solution?

App-install, although far from ready for general use, had a particular philosophy: hierarchical installation.

Each component has an associated installation file. The file contained more than just a script for installation. App-install would read the file and step through the instructions. It might prompt the user for data, displaying the default and allowing an override. The override could then affect additional defaults. Once these were set, a series of shell commands could be executed. A number of common operations were represented in the file at a higher level than simple shell commands, like creating and writing file content, changing file modes, sudo for certain operations.

Some installation files were higher up in the hierarchy. These files just contained links to other installation files, and/or the associated tar.gz file. App-install would then simply loop through these handling each in turn. In some cases the default variables in one install are reused, so you don't have to keep track of these details.

So the point was to have component maintainers create these relatively small files, and then a higher level maintainer would combine the parts they like into a new bundle. If one part of the bundle changes, the maintainer only have to change a few lines of one file and create a new version.

Once you create one of these files, you can install the sofware with the same information each time.

Then the maintainer just says which file to grab for a particular cases. When there are problems with an installation, the frustrated user can just post the entire output of the installation, because all of it was recorded to a single file. There is no mystery about what the user did or didn't do, or what failed to work as expected.

Examples of what these install file look like are here:

http://rmadilo.com/files/app-install/

Collapse
Posted by Vic May on
Tom,

It appears that Aolserver and Openacs can work either way -- centralized or user specific. Right now on my Ubuntu system it is installed as centralized but can be user specific by merely pointing the main nsd binary (/usr/bin/aolserver-nsd) to the custom config file.

Among many issues in Linux/Unix world I see two huge issues that could have/should have been solved a long time ago (in my opinion).

One is useless man pages, where every Unix admin I talked to agrees that man pages are mostly useless unless you already more or less know how the application works. Everyone spends enormous amounts of time just to figure out how to use an application, especially where application has a lot of command line options (like "mencoder", for example). It is by far more productive, often shorter and faster to provide a working example of each command line option or each set of options. Nevertheless, following the Unix tradition, programmers keep faithfully creating long, boring and useless man pages. We, the users, are forced to either waste hours upon hours trying to figure out how the application works or spend hours upon hours looking for help on the web. I usually go directly to the web.

Another issue, which is not an issue anymore for most of application but can sometimes be a huge issue at the most inconvenient times is having to compile applications. Imagine, there are millions of Ubuntu users worldwide. Somebody creates an application that has to be compiled. Each user compiles the source code on identical platform, using the same OS as millions of other users. What is the point of doing that when it can be compiled once by one person and others just install the binaries. I understand the intricacies of having different options compiled in etc. That's a stone age mentality. Optional functionality should be dynamically added without the need of recompilation. It is possible and it is being done all the time.

Well, enough of that point. Back to Aolserver/Openacs. I am an end user, not a developer. I don't want to care how installation is done. I just want it to be 100% reliable. The main user base in split between Debian based and Red Hat based distributions. The majority uses x86 processor. Why not make binaries for the majority?

So, why not make a working, statically compiled, self reliant package consisting of Aolserver, Openacs, Postgress and !!!ALL!!! modules that are available. That package should not depend on the location where it is installed, but configured for one initial location (like /opt/aolserver). It is by far much easier to reconfigure and modify a working installation than try to make nonworking one work. If another user needs the package, just copy it to a different directory, modify the configuration to point to that directory and you are done.

Also, it is now easier to fit the OS to the application then the application to the OS by using a virtual machine. For example, if I want to use OpenACS for publishing some content and there is a complete set of binaries available for, lets say Ubuntu 7.10. I just create a virtual machine with the Ubuntu 7.10 and install the binaries. Or, even better, just download the virtual machine file and use it (virtual appliance). That would make it very convenient for many users and OpenACS would be adopted by much larger number of people.

It might be that I am too naive and underestimate the problem but nevertheless that's how I wish things were. :)

Collapse
Posted by Tom Jackson on
Most applications are nowhere nearly as complicated as AOLserver and OpenACS. It is very hard to compare it to other types of precompiled applications. Compiling is the easy part. If you can't get over that minor hump in the road, you will quickly run into the difficulty of providing a secure and useful application.

I cannot stress more that you will quickly run into major trouble if you try to shortcut the process of installing OpenACS. Please consider this: this project is filled with many very talented developers. Yet, even though there are continuous calls for an easier installation, they never get done. There is a reason for this, and it isn't laziness.

Consider one simple example. I decided to compile AOLserver in my home directory to test out some feature. I thought I had discovered a massive bug where the server would run for a few requests then crash with weird errors. I wasted a day tracking down the fact that the library loader was finding the wrong version of Tcl. It used the correct version for building, but found something else at runtime. This could easily happen to anyone.

But configuration is significantly more complicated for all parts of this system. Most software components we use on our servers require no configuration, or very little. Of course as soon as you want to tweak one of these you run into the exact same issues: little documentation, no examples, don't know what to ask for or search for unless you are already an expert.

This is why I gave the example of App-install. It boils down all these decisions into a single file for each installation. The file is supposed to be written by an expert and shared with others. But it is relatively realistic: real developers compile and install even more components than just the basics. The App-install concept is also a form of documentation and an aid to recovery, or more optimistically, to duplication.

I agree about the documentation. I try to write examples of using any code I write. I actually need to do this just to test my code, so it isn't a major problem to provide examples. In fact, I like to write working examples that provide something beyond dry technical usage.

For example, over the last week I wrote a tic-tac-toe game to demonstrate a few features of a tcl templating system, and another few pages to demonstrate the use of [format] in and [assign] in the same system:

http://junom.com/document/twt/view/www/

Each file in that directory can be viewed except the .tcl files. So I simply add on a ~ to the end so your browser will display it as plain text. Examples are nice, working examples are even better.

But when I hear users asking for a download of OpenACS that just runs from a static install, I wonder how much they actually value the product. I know you can go in to Office Depot and buy a bunch of canned contracts for a few dollars, but it isn't really the same as getting good advice from an attorney. Usually the more appealing this seems to a person, the more they need a real professional.

In case I wandered around this too much, I'll stay it briefly: compiling is easy compared to configuration. Configuration is a breeze compared to running or developing an application server. Better to have a few speed bumps along the way, but the process could still be a little easier.

You are still in good company with everyone here wishing that installation was easier (and faster).

Collapse
Posted by Vic May on
RE: ....But when I hear users asking for a download of OpenACS that just runs from a static install, I wonder how much they actually value the product....

Tom,

There is nothing to value if you don't know what it is. ;) I did pass by this project multiple times in the last 3 or so years but never got to the point of installing it. The reason it attracted me is that it is TCL based. I like TCL a lot and was looking for a web/application server that was using it. My options were tclhttpd, aolserver and recently, wub. I did use tclhttpd for a while and liked it for it's simplicity. Then I heard about the great performance of aolserver, so I started looking around and naturally, many links were pointing to openacs. BTW, your name is everywhere where there is talk about aolserver/openacs. I don't know how you find the time. :)
Anyway, I got close to installing several times. I was able to compile Aolserver in the past but it seems there was always something missing that I needed and when I tried to add the missing component, I either got a dead download link, or an empty web page or I can't compile something. I have been trucking and using Linux since it was distributed on floppies and do have some experience with compiling problems. In the past I did try to troubleshoot, try to find missing files, fix dependency problems etc. It is because of that experience that I am reluctant to do so anymore, especially because it is so easy to install applications now days. You never know if it will be 5 minutes or 5 days to compile the application, so, naturally, the excitement isn't there. Well, your remark above intrigued me so I decided to look around for a working installation and found this:
http://www.jsequeira.com/projects/oasisvm/
It's a virtual machine with a complete installation of OpenACS and .LRN. I played with it for several hours and found it to be absolutely amazing. I do sincerely wish I discovered it years ago. I would have known how to use it by now. But it looks like I am hooked. :) Thanks to all the developers for the great work. And thanks to everyone who tried to help. BTW, that virtual machine link should be somewhere on the front page of openacs.org

http://www.jsequeira.com/projects/oasisvm/

Collapse
Posted by Tom Jackson on
Get into the habit of bugging folks here. I started out about the same with AOLserver/ACS/OpenACS: Linux on a stack of floppies. That was kicked off when I decided Windows NT and SQL Server were too expensive and difficult to manage (and too expensive!, did I mention that?)

The 5 minutes or 5 days thing can still occur. It took me a week to find a Linux distribution which enabled most of my laptop features. But x86_64 is new and free software takes time. Interesting thing is that the distribution I found had a semi-full-featured boot cd, so could try before installing the whole thing.

Collapse
Posted by Chris Douce on
Hi Vic,
Yesterday I discovered something similar to what your last post described. For the last couple of days I've been trying to get a native Windows installation of dotLRN up and running (to make a long story short: I had no end of trouble). There was a whole bunch of tips in the fora that I found but I kept getting presented with various flavour of difficulty.

In the end I thought, 'okay, so it's going to be Linux', so I went about finding a virtual machine for my home PC. After a false start, I settled on VMware and on a hunch I Googled (I think) VMWare and dotLRN in the same query which took me to here: http://media.wu-wien.ac.at/download/vdotlrn

Installation and figuring out how to drive the download was dead easy, just as easy as installing some of the other open source environments. If this was linked to on the main install page it could have saved a couple of days of head scratching. This said, I'm happy where I've got to so far in my dotLRN adventure.

Chris

Collapse
Posted by Tom Jackson on
I just installed VMware on Linux. Installation looks very similar to what I had for app-install. It asks a bunch of questions about where to install stuff, and then it compiles and installs, then asks more questions, etc.

But once that is installed, it is easy to startup the Oasis/Linux.vmw and login. I'm sure that on Windows all this works much faster since they seldom give you any choices there.

Overall, pretty cool way to check out stuff, but then what?

It would be interesting to hear what users do once they decide this stuff is cool. Does this provide the motivation to figure out the typical install?

Can you really do an easy native install on Windows?

Collapse
Posted by Malte Sussdorff on
I wrote some scripts which run through on most systems that will give you OpenACS, AOLserver without interfering with your local setup. I did not add PostgreSQL to the mix as this is probably installed already (albeit I have to pray the settings are right and the version works with OpenACS 😊).

Judging from this experience and the fact that I did over 100 installations in the last six months, here is what might work:

Create a script which does the downloading and compiling. It should check if it is able to connect to PG on 5432 and if yes, check that the version works with OpenACS (otherwise stop and return an error). If no, install PG on it's own. I am not a friend of letting the user make decisions in the install process so I would make some default assumptions based on the experience collected so far (e.g. install in /usr/local instead of /opt, use /var/lib/aolserver instead of /opt or /web), openacs as the service name, localhost using the first available port above 8000.

If this would help I can ask my sysadmins to write such a script based on the scripts that I have written so far. Sadly, I am not sure how much support we can guarantee for the script to work on all kinds of platforms, though we would try to make as many "if" statements into it to enable it on even more platforms.

This being said, I totally agree with Tom about the configuration and running part. If all you want is to try out OpenACS and add some more modules using the installer then you should be fine. But it starts with the basic question of "Do you want to install .LRN" which has a significant implication on the install. Furthermore, having the modules installed without and data in them is nice, yet you will wish for more so you can play around with it.

Project/Open ]po[ has gone a nice way here in providing a prefilled dump file with the ability to delete all demo data. That is their way of installing and at the moment they do not have a configuration file which does all the configurations necessary for a normally running system. Same way is what Quest did with their AIMS application. So the next question (assuming you got OpenACS installed), which dumpfile to use. And who is going to provide such a dumpfile for the installation, what should be included? We could probably provide a dump with the minimal components installed, all empty. But will this be enough for the user to get an experience out of OpenACS. And who is the user anyway? Is it the end user evaluating the product for his website like a canned product? Or is it the developer who wants to install this for one of their clients?

The app-install approach works perfect for the developer. As for the end user like Vic says he is, we should probably provide dump files for simple OpenACS, .LRN and maybe whatever combination people are willing to provide dump files for.

Either way, the codebase should be a full checkout of the latest release branch.

Collapse
Posted by Tom Jackson on
The app-install approach works perfect for the developer. As for the end user like Vic says he is, we should probably provide dump files for simple OpenACS, .LRN and maybe whatever combination people are willing to provide dump files for.

Yes, app-install is or was not even good for a single install, multiple ones made it useful. But the basic ideas follow along with Malte's comment: provide the needed files in a known location and let the installer download them. That is a big part of the frustration is just locating the right file, then discovering I need CVS access. Try to locate the cvs instructions, etc.

When it comes to installation scripts, my interest is in developing a hierarchical system for very obvious reasons: divide and conquer. Each tiny piece is relatively easy to install, but if you have to coordinate it with other components, do it for multiple systems and maintain it over time, a mega-script becomes a liability. The hierarchical division of scripts should allow the script maintainers to copy the component scripts, make minor variations as needed for new versions and system differences, and provide expert chosen defaults. And as suggested, record the process so the process can be quickly reviewed by the community instead of needing to ask a bunch of questions or make assumptions about what might have happened.

Malte: does a full checkout of the latest release...you mean the CVS version, not a tar.gz file somewhere? This is a good point, a trap I fell into a month ago. Since then I started using git-cvsimport to maintain an easier to browse repository. One very nice feature of this is the 'snapshot'. It is a tar.gz file of whatever sub-directory you want, minus the CVS directories. It is what I would call 'instant publication.'

Collapse
Posted by Vic May on
Well, I've spent a lot of time playing with different ways of installaing the combination of postgresql/aolserver/openacs. I have been able to install them multiple times including the "Project Open" distribution. I think I got some feel now how things work.
What bugs me now is that not a sigle installation is a fully working bugfree installation. Not counting the apm package links that point to nonexistant repository on openacs.org, there is always a problem with several software packages that either refuse to install or bomb out with SQL/TCL errors when I try to use them. Even the default installation of vmware version of Project Open is broken right from the start.

Question then -- is there a good known way to install packages that works error free? Is there a way to install a bare bones version of OpenACS that I can start adding packages to and test each one if it works?
Is there anything that just works? ;)

Collapse
Posted by Vic May on
Unfortunately aolserver4-nspostgres package does not contain that library file.
Collapse
Posted by Emmanuelle Raffenne on
Hi Vic,

I ran into that missing library problem in Ubuntu too. Ubuntu installs version 4.5 of aolserver and version 4.0-4 of aolserver4-nspostgres (i386). I solved it using the packages from debian/stable instead, that are aolserver 4.0 and nspostgres 4.0-3 (not sure what the difference is for that last one).

I know that it won't solve the main problem (i.e. an easy installation) but that might solve your current one.

Collapse
Posted by Dave Bauer on
There's not much reason to install on Windows with VMWare. The performance hit is negligible on modern hardware. VMWare Server is free and supports up to two processors (or cores) per VM.

This is more than sufficient for many production installs of OpenACS or .LRN.

So basically you can run it that way all you want. Of course once you determine OpenACS or .LRN is the right choice, you will be more inclined to spend some extra time doing a custom install if you need it.

Collapse
Posted by Tom Jackson on
Dave,

I'm not sure I understand what you said here. I think you said that using the VMWare install is okay for most purposes, not just testing. My experience today can't dispute that. It was relatively easy to install VMWare and the Linux.vmw is just a click to start. The documentation actually had more warnings (about the ip address, etc.) than what seemed necessary.

How difficult is it to produce these virtual installations? The one I loaded was over a year old, but it shouldn't be difficult to build this with a simple script unless the VMWare folks complicate things.

In some ways the VMWare approach is what I would suggest for OpenACS, that is an installation which is not global. I wish we had more descriptions from users that cover this area.

Collapse
Posted by Stefan Sobernig on
Tom,

How difficult is it to produce these virtual installations?

I refer to my experiences in creating http://media.wu-wien.ac.at/download/vdotlrn. The difficulty is well limited, as you have options at hand:

  • Create your own guest os appliance? The overall time factor is negligable, last time I did it, it was an effort of 30+ minutes. Of course, it depends, as you might consider some tweakings that should help keeping the disk footprint of the vbox as small as possible. Tweakings include:
    • Special-purpose *nix distributions: Conservative approaches are bare-bone or server installations of recent distributions (Ubuntu server is 300mb+ unpacked). Once, I also used the Debian mini flavour which reduces storage needs to 100mb+). Lately, I came across JeOS, an Ubuntu flavour, that includes some kernel (and footprint) optimisations for the use as guest os. I don't have any experiences on the latter, but it might be worth a try (especially as they are optimised for the use in vmware environments).
    • Manual clean-up after the vbox has been populated: Clear for temporary and cached data, installation and source files etc. One might also go for the manual removal of unneeded distribution elements.
    • Archiving the entire vbox for delivery: Using 7z, I managed to reduce one of my Ubuntu/OACS vboxes to ~68mb (~500mb unpacked). This gives a quite impressive compression ratio ... (and makes even unoptimised vboxes suitable for delivery)
  • Take a ready-made gues-os "appliance" and built on that: some examples are available from http://www.vmware.com/appliances/.

The installation of OACS/.LRN is not that an issue, time needs correpond to an ordinary installation. With the help of Malte's installation scripts (which could be tweaked a bit) it usually takes me another 30min+ on my machine to populate my vbox. After having done so, I came up with some extras which should turn the OACS/.LRN environment (and non-*nix users):

  • Some pre-configured samba shares (e.g. packages directory of OACS, home dir etc.)
  • A basic shell script to localise the vbox (keyboard settings, region and language, ...) in a guided manner

Overall, once the basic environment is established, tweaks are figured out, the efforts needed are really limited for the somewhat experienced OACS/.LRN geek to come up with up-to-date releases.

[...] but it shouldn't be difficult to build this with a simple script unless the VMWare folks complicate things.

to the best of my knowledge, there is no scripting environment for production/deployment of vboxes availabe (i.e. in the sense of the vmware authoring environments). this does not mean that the overall effort can not be substantially automated but not beyond what is done by e.g. Malte's script suite, I fear ... some remains handicraft.

Btw., you find a pointer to create your own images without any vmware authoring environment (as the server console, workstation etc.) at http://media.wu-wien.ac.at/download/vdotlrn.

Hope I could shed some light on the perceived complexity ...

Collapse
Posted by Tom Jackson on
Can these vboxes run without a console? That is something I didn't think about until you mentioned the keyboard. I noticed that it grabs the pointing device and keyboard.

Seems pretty cool, even better if someone already has VMWare installed.

Collapse
Posted by Stefan Sobernig on
Can these vboxes run without a console?

Yep, just get a local installation of the vmware server which will be the "ghost" run time environment for your images. The role of the admin ui (which is a tty terminal to the vbox) , as taken by the VMWARE player, is then played by the VMWare server console. You, then, can arbitrarily attach to and detach from vboxes. The vmware player is admin console and rte in one. The rte will take care of running vboxes whenever your host system fires up or the other way around. It comes with some advanced features and is definitely the way to go in your case ...

Collapse
Posted by Vic May on
Are you talking about the same thing here? "vbox" is a VirtuBox term http://virtualbox.org/ , not to be confused with "virtual machine" of vmware http://www.vmware.com .
Collapse
Posted by Vic May on
I meant "VirtualBox"
Collapse
Posted by Stefan Sobernig on
Vic,

vbox is just my personal flavour of referring to "virtual machine" in general (without any links to concrete products). But everything said above applies to the virtual machine/vbox I realised for the VMware line of products (and not virtualbox as product and brand) ...

Collapse
Posted by Vic May on
Stefan,

I just installed vdotlrn and like it a lot because of it clean interface, no errors so far and I like the "Profiling Information" on each page. That helps to learn how it all works. The only shortcoming is the the installation is outdated. How difficult is it to update it to the latest version?

Collapse
Posted by Stefan Sobernig on
Vic

How difficult is it to update it to the latest version?

I assume you mean how to difficult/ time-consuming would it be for me to update the vbox to the most recent release. in fact, I've already started to provide a new one (and somehow promised it to chris douce, see above). I've just finished giving my last lecture today, so there will be some time to round it up at the beginning of next week. Expect it around tuesday ...

Collapse
Posted by Dave Bauer on
You haven't desscribed which packages you tried to use, what version of OpenACS you installed on or how you tried to install them.

We fully admit there are problems. One problem of course, is that most of use who regularly use OpenACS have intuitive knowledge of how to install it, and don't see these issues.

I applaud your perseverance!

You might try http://oacsrocks.org which provides a preinstalled demo that you can use.

Collapse
Posted by Vic May on
Dave,

My goal was to install the latest everything --- Postgres 8.25, Apache 4.5, OpenACS 5.3.2. I have been able to do it using a mix of installation sources, unfortunetly I did not keep track of it. I will keep trying. It could also be that "latest everything" is not a good idea. Also, I should probalby read the documentation first to figure out how things work underneath. I have never used CVS before so I did not try CVS installation, don't know how stable/easy it is.

Collapse
Posted by Vic May on
BTW, I am subscribed to oacsrocks but that does not help me much with figuring out my own installation but I do spend time browsing around just to see how things work.
Collapse
Posted by Malte Sussdorff on
After getting frustrated of being unable to compile AOLserver under Ubuntu due to glibc problems I stumbled upon the fact that Ubuntu 6.06 LTS has AOLserver packages (thanks to DaveB for his blog posting).

Based on this I wrote a new installation instruction for AOLserver which includes tdom, xotcl and tcllib (as they all are required now by OpenACS).

http://cognovis.de/developer/en/aolserver_ubuntu

Collapse
Posted by Iuri Sampaio on
Hi all,
I'm working with Robert Taylor on this field and i finished some scripts to easily install oacs in debian.

It's an adaptation of cognovis and old oacs scripts.
Plus tutorials published on oacs website by Vinod and some others good guys from oacs community.

It's just a few confirmation steps to get your oacs box ready to browse.(apt-get Y/N questions and postfix setup)

The troubles i faced: repos are constantly down, plus aplications such as tdom, tcllib,... version updates without publishing

Also, there are settings such as ip address and homedir, service user, in case you would like to change the defaults.

Please check it out at:
http://69.67.174.135:8000/file-storage/index?folder%5fid=2572

Collapse
Posted by Tom Jackson on
Please check it out at:
http://69.67.174.135:8000/file-storage/index?folder%5fid=2572

Ugggg! Who is ever going to believe that OACS developers know what they are doing, especially with regard to installation and configuration streamlining, if they post stuff on the web using IP address and an unprivileged port? The link above doesn't work, but the dnsname associated with it is hanyb174135.smarttadsl.com, so it will likely be a short lived address under any circumstances.

It's okay to post a log file or something similar to an IP, but not your solution to installation problems. Probably the biggest sources of frustration for new developers of any project are dead-links, half-done guides, just-get-it-installed guides and discovering the over-hype of the polished intro-documentation. (Fortunately, OACS doesn't suffer from the last of these.) But I-solved-a-big-problem promises to dead-links is pretty high up on the frustration index.

If you can't find a place to put this right now, why not send me a copy. I'll post it, and further updates, so others can find it.

Collapse
Posted by Dave Bauer on
OpenACS.org provides a handy location for stuff like this!

https://openacs.org/storage/

Collapse
Posted by Tom Jackson on
Thanks Dave, that is a 1000 times better than my kludge, and even gives a great example to potential developers.
Collapse
Posted by Iuri Sampaio on
Sorry Tom,
I have the best intentions publishing stuff and contributting to OpenACS community.
Although i don't have the best expertise and money YET, in order to provide the best structure to all.

Here it is the link
https://openacs.org/storage/?folder%5fid=492324

Thanks for the link Dave.

Collapse
Posted by Gustaf Neumann on
another option (esp. for single files) is to store content directly in the wiki instance, see e.g. http://www.openacs.org/xowiki/save-file-in-wiki
Hi!

Another idea for easier installation of OpenACS maybe to make an ubuntu install cd/dvd with openacs installed. I've been playing with Remastersys and it's easy and fast create distributable cd's. I've done an iso dvd http://www.davidam.com/ubuntu-oacs.iso.

Just for fun!