archive_me1Add my vote for this tag windows1Add my vote for this tag create new tag
, view all tags

Documentation Proposal: some more ingredients for the windows install cookbook


Adding some paragraphs to the windows cookbook might be helpfull. Especially since one might not get as far as to read the recommendation to "See the TWiki Installation Guide for other setup" in the "Next Steps" section, if the testing of the Twiki installation leads to problems.

I experienced some problems with my windows installation and I worked myself through several support topics as well as asking own support questions, and in the end solved the problem by using the TWiki Installation Guide.

To save time for other new TWiki Admins it could be usefull to include these things into the cookbook.


Target Audience would be people who are going to install TWiki on Windows.

Some more parts from the Twiki Installation Guide should be adapted for the Windows Install Cookbook.

There are two main points that should be integrated:

  1. the advice given by MattWilkie in InsecureDirectory and AnotherInsecureDirectory
  2. some parts of the solution described by me in EditAndSaveAnyPage


insert a new paragraph into the windows install cookbook under "Configuring components":

Configuring Cygwin

Open the windows explorer, right click your cygwin directory (c:/path/to/cygwin) and choose "Properties". Select the "Security" flag and set the permissions as follows:

  1. uncheck 'inherit permissions', slap the 'copy existing' button when prompted
  2. for the 'Everyone' group, uncheck Write access and Full Control
  3. Add the groups CREATOR OWNER, SYSTEM and give them Full Control
  4. Add the users Administrator, Your_Name and give them Full Control

insert a new paragraph into thw windows install cookbook between "Re-locking RCS files" and "Email setup". I took this paragraph from the Twiki Installation Guide and adapted it for windows, using help given in TWikiCfgFileNotFound2 by PeterThoeny :

Edit the Configuration Files

Note - you may need to change the permissions on the configuration files so that you can edit them. Do that in the most convenient way: we're going to set their permissions correctly for operation in a subsequent step, so don't worry about exactly what permissions you give them just for editing purposes.

  • Edit the file /twiki/bin/setlib.cfg
    • Set $twikiLibPath to the absolute file path of your /twiki/lib as seen by the web server. This means: change the '../lib' entry to 'c:/path/to/twiki/lib'.
    • ALERT! Attention: Do not leave it as a relative "../lib" path or Plugins might fail to initialize properly
    • You can also edit $localPerlLibPath if you are not root and need to install additional CPAN modules, but can't update the main Perl installation files on the server. Just set this variable to the full pathname to your local lib directory, typically under your home directory.

  • Security setup: Secure your TWiki data, lib and templates directories.
    • Directories twiki/data, twiki/lib, twiki/templates and all their subdirectories should be configured in your Apache server so that they are *not* visible through URLs.
    • There is subdir-htaccess.txt under twiki installation directory. Copy it into the data, lib and templates subdirectories, naming it .htaccess to have Apache recognize it. Or you may edit the Apache http.conf file to set the deny from all there (this is recommended by Apache.org)
    • Alternatively, move the directories to a place where they are not visible, and change the variables in twiki/lib/TWiki.cfg accordingly.

Set File Permissions

For the following configuration use the cygwin shell.

  • Set the file permission of all Perl scripts in the twiki/bin directory as executable to -rwxr-xr-x (755). Use the chmod command.
  • To be able to edit the Perl scripts and .tmpl files it is necessary to chown and chgrp -R twiki so all the files have the owner you want.
  • HELP This Guide assumes user SYSTEM ownership for all files manipulated by the CGI scripts (executed by the Web server), and user twiki for all other files. You can:
    • replace SYSTEM with another user if your web server executes scripts under a different name (for example, the default for Debian is www-data).
    • TIP HINT: Run the testenv script from your browser: http://yourdomain.com/twiki/bin/testenv. It will show you the user name of the CGI scripts ("LOGNAME: ..."), a table listing all CGI environment variables, and a test of your twiki/lib/TWiki.cfg configuration file.
    • replace user twiki with your own username

  • Set permissions manually.
    • Set the permission of all files below twiki/data so that they are writable by user SYSTEM. A simple way is to chmod them to -rw-rw-r-- (664) and to chown them to SYSTEM.
    • Set the permission of the twiki/data directory and its subdirectories so that files in there are writable by user SYSTEM. A simple way is to chmod them to drwxrwxr-x (775) and to chown them to SYSTEM.
    • Set the permission of the twiki/pub directory and all its subdirectories so that files in there are writable by user SYSTEM. A simple way is to chmod them to drwxrwxr-x (775) and to chown them to SYSTEM.


This is the first time I write something like this, so please feel free to change anything that is not written or designed as it should be.

-- JuditMays - 21 Feb 2005

Nice job Judit!

Please edit the WindowsInstallCookbook directly and put your changes in. Wait a few days for other responses if that makes you more comfortable. They look good to me, and we can always back them out if an error is found.

For the record, the primary Windows Install author to date is Richard Donkin.

-- MattWilkie - 21 Feb 2005

Just to say can you add the neccesarry command for the chmod and chown for changing the ownership? This should help first time perl user like me to install twiki

-- GilbertAliwarga - 28 Feb 2005

I added the contents of this topic to the cookbook.

I also added a short explanation for the unix / linux command lines. I hope this helps already. But you should check the man page for linux commands, if you are not sure, how to use them. In the cygwin shell this is: man command in this case it would be: man chown or man chmod. But you can also get the information on linux shell commands anywhere in the internet (try google). (BTW, these are no perl commands. I don't know any of them, either wink )

-- JuditMays - 04 Mar 2005

TopicClassification DocRequest
TopicSummary Adding some more ingredients to the windows install cookbook
CurrentState MergedToCore



ProposedFor DakarRelease
TWikiContributors PeterThoeny, MattWilkie, RichardDonkin and everybody else who wrote Windows Install Cookbook and Twiki Installation Guide
Edit | Attach | Watch | Print version | History: r7 < r6 < r5 < r4 < r3 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r7 - 2008-08-28 - TWikiJanitor
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.