Installing TWiki-4 On Windows 2003 and Apache
| Setup Type / Module |
Actual State |
Comment |
| Apache and Cygwin RCS |
Not working |
Permission issues ? But does not work at all |
| Apache and RCSLite |
Working |
Revision are incremented by +1 instead of +0.1. IS it normal ? |
| Registration |
Not working |
.htpasswd problem ? |
Introduction
This is a
detailed walkthrough for the installation of TWiki-4 on Windows 2003 and Apache as web server. It covers all the gory details that are not detailed by the documentation shipped with TWiki.
Note: If you are installing on a existing "raw" Windows PC i.e. one with no existing Apache or Perl installations, you might want to consider following the
IndigoPerlCookbook instead.
We first going to assume that you have a server where you can install Windows 2003, or that a Windows 2003 box is available.
Also we are going to assume that TWiki is for internal use only, so that there are no security concerns.
Also, for now, IIS6 will not be installed. Even if you find some reference to it in the following sections, I will not install it for now. I gave some hints to install Apache and IIS on the same machine because I will use the same box for the 2 topics.
Server Specs
For me, I don't have a free box, so I will use a virtual PC instead.
Here are the specs:
Virtual PC :
- Windows 2003 Standard
- Formated as NTFS
- Not part of the Domain (workgroup)
- Fixed IP address
NOTE : We are going to use 2 ip , one for IIS and the other for Apache)
we could make apache bind with the same ip address but on another port. It's your choice. I prefer Apache runs on its own IP instead.
Hint on Apache and IIS6 installed on the same box.
The problem is that, by default, IIS listen on every IP address that it could. But even if you try to bind your web site on some specific IP addresses, that does not help. A tool like
ActivePort can show you that the server is still listening on 0.0.0.0:80. So you can use the guide below to resolve this issue.
Do that only if IIS is already installed and that you want to have Apache listen on a specific IP address.
IF you have no plan to use IIS, then forget about that. Go directly to the next step.
REMEMBER: Do that
IF YOU HAVE ALREADY IIS Installed, you have to modify some settings of IIS
IIS 5
The following steps are required for IIS5 (Windows 2000). If you're running Windows 2003, and have IIS installed, head to the next section covering IIS6.
- First make sure that all web sites listed in the IIS Admin Console listen on a specific IP (do a right clik on each of them and change the IP address, from 'All unasigned' to the one your want)
- Warning Do that on a test server and be sure what are you doing !!!
- Then, do a cmd, them go to the foler where the admin scripts are located ex: cd c:\inetpub\Adminscripts
- Then cscript adsutil.vbs set w3svc/disablesocketpooling true
- Reference : From Microsoft web site, article id 238131
IIS 6
- Install the Windows 2003 Support tools from the Windows 2003 CD (SUPTOOLS.MSI under the tools folder).
- Open a command prompt.
- Run 'httpcfg set iplisten xxx.xxx.xxx.xxx' to change the IIS 6 bindings. xxx.xxx.xxx.xxx is the IP Address you want to bind IIS to.
- Run 'httpcfg query iplisten' and check that you are now binding IIS to the new IP Address you entered.
- Run 'net stop http /y' and when services have completed shutdown, run 'net start w3svc'.
- You should now be able to install Apache and configure it to bind to the additional ip address on the server.
- Reference : From Microsoft web site, article ID : 813368
Security concerns
NOTE : Security is not a concern here, that could ne important for the next steps. For now, I simply don't care about security.
- We are going to uninstall the internet explorer enhanced security configuration( Add remove programs, windows components)
- Make all the updates of the OS (windowsupdate.com), .NET framwork 2 included
We will also disable this stupid logoff prompt, where the OS ask you Why we want to shutdown or restart : I know what I am doing, so leave me alone !
- Run a
gpedit.msc Then, / Local computer policy / Computer Configuration / Administrative Templates / System / Display shutdown event tracker : disable
Software used
| Component |
Name, version |
Comment |
| Operating System |
Windows 2003 |
Maybe work on other Windows OS |
| Web Server |
Apache 1.3.34 |
Apache 2.0 will not be used because I don't know if it is officially supported by Twiki-Dakar |
| Unix tools |
Cygwin 1.5.14 |
I am going to install them because it seems to be the way we should use RCS but in my case, it does not work yet |
| Perl |
ActiveState-ActivePerl-5.8.7.815 |
I use this because on the production server, my bugzilla setup use it, so why not Twiki ? |
| RCS |
Cygwin rcs-5.7-3 |
Comes with Cygwin |
| Text Editing |
Programmer's File Editor 1.01 (PFE) |
A cool Windows editor that can open safely UNIX files, no longer supported but works fine |
We first going to
_assume_ that IIS is not installed.
The twiki documentation needs to recommend what web servers are 'supported'.
So let's go with the Apache installation
Apache 1.3.34 installation
1. Download and Install
- Just go on the Apache web site and download this specific version.
- Runs the installer and reply for some question (domain name. web server name and email address)
NOTE The server will be used as a service, so the option 'for eveyrbody' will be used
- For the patch to install Apache, several comments around says that it is better to have it installed in the folder C:\Apache, so we will use this one also, so just choose the C:\ root folder, because Apache will install itself in the C:\Apache folder
- During the setup Apache will install itself and wil runs the service (remember that IIS6 is not installed so it should work pretty easily, for those who have IIS installed, read above.
- The setup for apache is done.
2. Testing Apache installation
- To know if Apache is working, just open your browser and type http://
and should have the Apache test page displayed.
So far so good, then let's proceed with the next steps.
ActivePerl-5.8.7.815 installation
Just download from Activestate web site the MSI package for Windows.
There are no special steps for the setup. You will notice that some options are greyed out, it is because they are related to IIS.
NOTE : Because the setup adds the path of perl in the PATH env variables at the SYSTEM level, it is recommanded to
reboot the server to complete the setup.
Cygwin installation
1. Download and Install
- Create a folder like c:\cyg_download
- Download from the cygwin website at this location
- Execute the setup program
- Select 'Install from Internet' option
- The root directory will be c:\cygwin
- We will choose also the options 'All users' and 'Default text file type = UNIX/binary'
- Local package directory will be C:\cyg_download (same location has the setup.exe)
- Select your connection settings
- Choose your FTP server in the list (ex : ftp://ftp.gwdg.de
)
- Change de view for FULL (click several times on the View button
- Select the different items as follow :
-
bash
-
binutils
-
coreutils
-
diffutils
-
gcc
-
grep
-
gzip
-
make
-
ncftp
-
rcs (5.7-3 or higher)
-
tar
-
unzip
-
w32api
-
wget
- NOTE You will notice that PCRE and Perl has been removed, we are using ActivePerl here. Also, we have not added 'nano' because we are using PFE as text editor.
- NOTE To install some items, just click on 'Skip' on the fron of the selected items to see what version will be installed.
- Hit Next to do the installation.
- NOTE: The mandatory packages require a download of about 12 MB - about half of this is Perl, which would be necessary even without Cygwin, and most of the rest is
gcc, which is required for simple installation of Perl modules that use the C language. A default installation of Cygwin 1.5.10, plus required packages, needs around 150 MB of free disk space - if you are tight on disk space or Internet bandwidth, de-select all but the mandatory packages, but if not, there is no harm in downloading more.
- NOTE: The installer keeps a local copy of downloaded files, so it's easy to re-install without re-downloading.
- Let the installer create the shortcuts suggested
- You can always come back and re-run the installer again later if you missed anything.
2. Environment setup
- Official documentation says : Set the
HOME environment variable to c:\cygwin\home\YOURUSER, where YOURUSER is your userid, e.g. jsmith or administrator.
- So, Administrator will be used.
- Go into Control Panel, double-click the System icon, and select Advanced, then click Environment Variables. Under User Variables, click _New.... Now type
HOME (must be upper case) as the variable name, and c:\cygwin\home\YOURUSER as the value, and hit OK._ So for me, it will be HOME=C:\cygwin\home\Administrator.
- Official documentation says : You can also set
TEMP to c:\temp at this point, if you prefer this to editing the Cygwin ~/.profile file. (HOME can't be set in the ~/.profile file.).
- Create the
c:\cygwin\home\YOURUSER directory. You can do it in Windows Explorer
3. Test Cygwin
- Launch the desktop icon - this runs the
bash shell, which has command line editing features
- Use the cursor up key to recall previous commands - normal PC editing keys can then be used to edit a command
- TIP: When typing a directory or file name, hit the TAB key after the first few letters of the name -
bash will 'complete' the name. If bash beeps at you, hit TAB again to see the files/directories that match the name so far, and type a bit more before hitting TAB. This saves a lot of time!
- Type
rcs -V - you should see the RCS version, 5.7
- Type
perl -v - you should see cygwin mentioned in the first line, and the Perl version, 5.6.1
- Type
grep home /etc/passwd - you should see some output.
4. Configure Cygwin for binary mode _Dumped from official documentation_
- This is very important - omitting this step leads to a partially working system that corrupts RCS files - without this, Cygwin tools (including Perl and RCS) will add unwanted carriage returns (Ctrl/M, '\r') to files in an attempt to translate between the Windows and Unix text file formats (Unix text files only use line feeds ('\n').
- Stay in the Cygwin (bash) shell, and type the following (use only forward slashes, i.e. '/'):
$ mkdir /twiki /c c:/twiki
$ mount -b -s c:/twiki /twiki
$ mount -b -s c:/ /c
$ mount -b -c /cygdrive
$ mount
C:\cygwin\bin on /usr/bin type system (binmode)
C:\cygwin\lib on /usr/lib type system (binmode)
C:\cygwin on / type system (binmode)
c:\twiki on /twiki type system (binmode)
c: on /c type system (binmode)
- This configures
/twiki (known as a 'mount point') to map onto c:/twiki and for that directory tree to always be in binary mode, and does the same for /c, mapping it onto c:/. The last-but-one command sets binary as the default for any unmounted drives (e.g. z:/, aka /cygdrive/z).
- It is very important that all lines in the output of
mount say '(binmode)' at the end of each line
- If the lines for
C:\cygwin directories do not, you should uninstall and then re-install Cygwin to ensure that binary attachment uploads will work.
- You can now refer to files using Unix paths, e.g.
/twiki/bin/view or /c/apache/Announcement - see the Cygwin documentation
for more details on this.
- Now test this, still using the Cygwin shell:
- Type
cd /twiki
- Type
echo hi >t
- Type
cat -v t - you should see hi as the output
- If you see filename errors, your mounts did not work for some reason - check your typing
- If you see
hi^M as output, your /twiki directory is not in binary mode
- Clean up by doing
rm t
This setup is written to the Windows registry, so there's no need to put these commands into a
.profile file. For more information on binary vs text mode, see this
User Guide section
and this
FAQ entry
.
NOTE I will assume that
cygwin use the
ntsec security system by default. I don't want to change anything here for now with my personal speculations. I will assume that cygwin with the above settings should works the way we want.
NOTE If you have any errors or problems when creating the directories in cygwin
be sure the the twiki directory is not present on C: before do that. in doubt, do an
umount with the correct mount point, and use Windows Explorer to delete any folders listed in c:\cygwin AND c:\ (related to twiki of course).
5. Download TWiki
Download the latest TWiki release from
http://twiki.org/
and save it in the
c:/twiki directory.
6. Install TWiki
If you have downloaded the twiki zip file in another folder that c:/twiki, just move the file here with Windows Explorer.
Unzip the downloaded ZIP file under
c:/twiki using
WinZip
, or by going into Cygwin and doing the following - you can hit the
TAB key to complete filenames after you've typed the first part:
$ cd /twiki
$ unzip <release package>.zip
Configuring components
Now that all the components are installed, you need to configure them.
Configuring Apache Dumped from Official documentaiton
The setup given here is fairly simple, in that it allows only TWiki to be served by the web server. For more complex setups, you can investigate the Alias and ScriptAlias commands that are left commented out in this configuration.
- NOTE: This needs reviewing for security holes and to ensure nothing is missed, though this config does work.
1. Configure Apache (part 1)
Before going further, make a backup of the file =c:/apache/conf/httpd.conf=
Using a suitable text editor (see #TextEditing, above) edit
c:/apache/conf/httpd.conf as follows - this tells Apache where TWiki lives, and removes the need to tinker with the Windows environment settings.
- Note the trailing '/' characters in various places - they are important!
- Create the
c:\tmp directory, by typing mkdir c:\tmp in a DOS command line window
- Edit the following lines, some of which already exist in the file:
# Change this to point to the Apache administrator (e.g. you)
ServerAdmin you@yourdomain.com
- I my
httpd.conf, there is no fModule mod_env.c section, I do a copy paste of the lines below and place them at the end of the http.conf file.
# Environment setup required to run Apache as service or as a
# standalone process.
# Adjust TZ for your server timezone, e.g. EST5EDT - put the non-daylight-savings
# timezone code first (e.g. EST or GMT), followed by the number of hours that it's behind GMT
# during non-daylight-savings time (use '-5' for timezones in advance of GMT).
SetEnv TZ GMT0BST
SetEnv RCSINIT -x,v/
# Adjust TEMP and TMP for your server and create directories if necessary
SetEnv TEMP c:/tmp
SetEnv TMP c:/tmp
SetEnv LOGNAME system
SetEnv HOME c:/twiki
SetEnv PERL5SHELL "c:/cygwin/bin/bash.exe -c"
NOTE I have seen that Dakar comes in the root of its directories with an include file. I have installed it this way :
- Make a copy of the file
c:/twiki/twiki_httpd_conf.txt to c:/twiki/twiki_httpd.conf
- Edit the file with PFE and change the settings as follow :
ScriptAlias /twiki/bin/ "C:/twiki/bin/"
Alias /twiki/ "c:/twiki/"
<Directory "c:/twiki/bin">
Options +ExecCGI FollowSymLinks
SetHandler cgi-script
Allow from all
</Directory>
<Directory "c:/twiki/pub">
Options FollowSymLinks +Includes
AllowOverride None
Allow from all
</Directory>
<Directory "c:/twiki/data">
deny from all
</Directory>
<Directory "c:/twiki/templates">
deny from all
</Directory>
<Directory "c:/twiki/lib">
deny from all
</Directory>
- Then, edit your
c:/Apache/conf/httpd.conf file and add at the end the following line :
-
include "c:/twiki/twiki_httpd.conf"
- Restart the Apache service to be sure that all is correct for the server.
- If the service runs ok, then try again the http://
to be sure that you have something.
2. Configure Apache (part 2)
Add an AddHandler line to the
<IfModule mod_mime.c> section of
httpd.conf - this removes the need to rename all the TWiki
CGI scripts later in the installation.
- Note the trailing '.' on the AddHandler line.
#
# Document types
#
<IfModule mod_mime.c>
# TWiki setup - avoid renaming scripts. Don't forget the dot !!
AddHandler cgi-script .
...
Remember to restart Apache after the configuration.
If the Apache Service does not start then, delete the actuall httpd.conf file and restore the original one. Proceed step by step when adding some configuration. Like add first, the twiki directory directive, restart Apache, ddd the line for the cgi script, restart and so on.
Below this point, I have change the order of the official documentation to reflect my actual walktrough.
Configuring Cygwin
3. Configure Cygwin
Open the windows explorer, right click your cygwin directory (c:/path/to/cygwin) and choose "Properties".
Select the "Security" and set the permissions as follows:
- Select the Advanced tab.
- uncheck 'inherit permissions', slap the 'copy existing' button when prompted
- for the 'Everyone' or 'Users' group, uncheck Write access and Full Control NOTE I have given the group users full control, there is no every one group listed for me here.
- Add the groups CREATOR OWNER, SYSTEM and give them Full Control
- Add the users Administrator, Your_Name and give them Full Control
Configuring TWiki
4. Configure TWiki PART 1
NOTE By default, all twiki files in Dakar are read only. We will have to change that later.
- Make a copy of the file
c:/twiki/bin/locallib.cfg.txt to c:/twiki/bin/LocalLib.cfg
- Change the permission on the file so it can be writable (right click on the file and uncheck the read only flag)
- open it by double clicking on it (Windows will prompt you for a suitable editor).
- Change the value of
$twikiLibPath = "/absolute/path/to/your/lib"; to $twikiLibPath = "c:/twiki/lib";
- Save the file.
Editing the CGI scripts
4. Setup for ActivePerl
The official documentation talk about some speciphic setup for Active Perl.
I will add the line
SetEnv PERL5SHELL "C:/cygwin/bin/bash.exe -c" to the
httpd.conf file, in the
IfModule mod_env.c section of the Apache configuration file.
NOTE The only way to make the Apache Service accept the
PERL5SHELL Env variable has to add spme quotes to the command itself. Don't know if it is the best way but it works. I will investigate that later.
5. Editing the Shebang lines
Now to edit the curiously named 'shebang lines' at the top of the TWiki
CGI scripts. This is required so the Apache server knows what interpreter (perl) to use with the scripts.
- You must use the Cygwin shell to do this (unless you are a Perl expert) - don't use the Windows command shell, cmd.exe (aka DOS Prompt)
- Then do the following, which quickly edits the 19 or so files, using a Perl script.
$ cd /twiki/bin
$ ls
attach geturl oops rdiff save testenv viewfile
changes installpasswd passwd register search upload
edit mailnotify preview rename statistics view
$ mkdir .backup
$ cp * .backup
$ head -1 view
#!/usr/bin/perl -wT
$ perl ../tools/rewriteshebang.pl
Change the "shebang" lines of all perl scripts found in the current
directory.
"shebang" lines tell the shell what interpreter to use for running
scripts. By default the TWiki bin scripts are set to user the
"/usr/bin/perl" interpreter, which is where perl lives on most
UNIX-like platforms. On some platforms you will need to change this line
to run a different interpreter e.g. "D:\indigoperl\bin\perl"
or "/usr/bin/speedy"
This script will change the "shebang" lines of all scripts found in
the directory where the script is run from.
Note: the path to the interpreter *must not* contain any spaces.
Enter path to interpreter [hit enter to choose 'perl']:
$ head -1 view
#!perl -wT
If for some reason the edit goes wrong, just type
cp .backup/* . (while within the
bin directory) to restore the original distribution files. Use
ls -a to see the
.backup directory, and
ls -a .backup to view its contents.
6. Installing required Perl modules
Because we are using
ActiveState Perl, I have not used the Official Doc here. Installing some mods to the perl setup is quite easy with
ActivePerl.
- Start a dos prompt and go to the perl folder
c:\Perl
- type
ppm
- Note if you have an error with a strange bash stuff, it is because the env variable is set to
C:/cygwin/bin/bash -c at the system level. Prefer the Apache level if possible.
- Then to know what is it installed, type
query 1 or query *
- You should have those :
ppm> query 1 >result
Query Results Set 1 (*):
1. ActivePerl-Config [0.1] Override the ActivePerl configuration
2. ActivePerl-DocTools [1.0] Maintain HTML documentation
3. ActiveState-Utils [1.23] ActiveState's utility modules
4. Archive-Tar [1.26.0.1] Manipulates TAR archives
5. Archive-Zip [1.16] Provide an interface to ZIP archive files.
6. Compress-Zlib [1.41] Interface to zlib compression library
7. Data-Dump [1.6] Stringified Perl data structures
8. Digest-HMAC [1.1] Keyed-Hashing for Message Authentication
9. Digest-MD2 [2.3] Perl interface to the MD2 algorithm
10. Digest-MD4 [1.5.0.1] Perl interface to the MD4 algorithm
11. Digest-SHA1 [2.10] Perl interface to the SHA-1 algorithm
12. File-CounterFile [1.4] Persistent counters
13. Font-AFM [1.19] Interface to Adobe Font Metrics files
14. HTML-Parser [3.46] Parsing of HTML documents
15. HTML-Tagset [3.4] Data tables useful in parsing HTML
16. HTML-Tree [3.18] Build and scan parse-trees of HTML
17. IO-String [1.7] Emulate file interface for in-core strings
18. IO-Zlib [1.4] IO:: style interface to Compress::Zlib
19. libwww-perl [5.803.0.1] Web API for Perl
20. MD5 [2.3] Deprecated. Use Digest::MD5 instead.
21. MIME-Base64-Scripts [1.0] Scripts to encode/decode base64 and quoted-printable
22. SOAP-Lite [0.55.0.1] Interface to the Simple Object Access Protocol (SOAP)
23. Term-ReadLine-Perl [1.2.3.2] Readline implementation in Perl
24. TermReadKey [2.30] Change terminal modes and perform non-blocking reads
25. Text-Autoformat [1.13] Automatic text wrapping and reformatting
26. Text-Reform [1.11] Manual text wrapping and reformatting
27. Tk [804.27.0.4] Tk - a Graphical User Interface Toolkit
28. Unicode-String [2.9] Unicode abstraction based on UTF-16
29. URI [1.35] Uniform Resource Identifier references (RFC 2396)
30. XML-Parser [2.34.0.1] Parsing of XML documents
31. XML-Simple [2.14] Easy API to maintain XML (esp config files)
- Then
install libnet. When I google Net:SMTP, I found that it is related to the libnet library. So I guess that installing it will be enough. We will confirm that later when running configure. Don't do it yet because we still need to confifure permissions on twiki folders and files.
- And
install cgi-session
- Then
exit to exit ppm and exit again to close the dos prompt.
Unlocking RCS files
7: Unlock existing RCS files
If you want to use existing TWiki data files with TWiki-4, you will have to unlock them. Earlier versions of TWiki kept files permanently locked by the webserver user, which meant that no other user could edit them, so we have to unlock them.
If you do not have any existing TWiki data files, skip this step.
$ cd /twiki/data
$ # Make sure rcs is on the path; print the version number
$ rcs -V
$ # Make a backup of all files in data and pub
$ tar czvf all-files.tar.gz data pub
$ # Unlock the rcs files in data and pub directories from the old installation
$ # This is done by running the command rcs -u -M on each ,v file under pub and data
$ find data pub -name '*,v' -exec rcs -u -M '{}' \;
Edit Configuration Files and Set File Permissions
8. Edit 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.
- 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 deny from all there (this is recommended by Apache.org)
9. Set File Permissions
For now, we have two choices, one is to use the Windows system to apply security permissions on folders and files, The other is to use cygwin to do that.
I will use the cygwin part to be as close as possible with the official doc.
In the bash shell, go to the
twiki folder
$ cd /twiki
$ # Set all files to be owned by use 'system'
$ chown -R system *
$ # Set all files to be writable by 'system' but only readable by everyone else.
$ chmod -R 755 *
If you trust all users with shell access on the server, you can use 777 instead.
For your information, I will give the output of what windows sees now in terms of permissions. Again If I am wrong in this procedure, please comment !
- With Windows Explorer, do a right click on the
data folder,
- On the permissions tab, you have :
- SYSTEM = special
- CREATOR GROUP = special
- CREATOR OWNER = special
- Everone = special
- None = special --> it appears here because when you look at the
/etc/password and etc/group this group is also listed.
- When you click on the Advanced tab, you should have this :
| Type |
Name |
Permission |
Inherited from |
Apply to |
| Allow |
SYSTEM |
Full |
Not inherited |
This folder only |
| Allow |
None |
Special |
Not inherited |
This folder only |
| Allow |
Everyone |
Special |
Not inherited |
This folder only |
| Allow |
CREATOR OWNER |
Full |
Not inherited |
Subfodlers and files only |
| Allow |
CREATOR GROUP |
Read & Execute |
Not inherited |
Subfodlers and files only |
| Allow |
Everyone |
Read & Execute |
Not inherited |
Subfodlers and files only |
- Look for the same for the file
index.html for example
- On the permissions tab, you have :
- SYSTEM = Modify, Read & Execute, Read, Write, Special permissions
- Everone = Read & Execute, Read, Write
- None = Read & Execute, Read, Write
- When you click on the Advanced tab, you should have this :
| Type |
Name |
Permission |
Inherited from |
| Allow |
SYSTEM |
Special |
Not inherited |
| Allow |
None |
Read, Write & Execute |
Not inherited |
| Allow |
Everyone |
Read, Write & Execute |
Not inherited |
- Now for the
cygwin point of view, the output looks like :
Administrator@testserver /twiki
$ ls -al
total 4972
drwxr-xr-x+ 9 Administrator None 0 Feb 27 15:25 .
drwxrwx---+ 11 Administrator Users 0 Feb 28 09:57 ..
-rwxrwxrwx 1 SYSTEM None 5533 Feb 7 10:08 AUTHORS
-rwxrwxrwx 1 SYSTEM None 328 Feb 7 10:08 COPYING
-rwxrwxrwx 1 SYSTEM None 355 Feb 7 10:08 COPYRIGHT
-rwxrwxrwx 1 SYSTEM None 2262 Feb 7 10:08 Copy of twiki_httpd_conf.txt
-rwxrwxrwx 1 SYSTEM None 34158 Feb 7 10:08 INSTALL.html
-rwxrwxrwx 1 SYSTEM None 19190 Feb 7 10:08 LICENSE
-rwxrwxrwx 1 SYSTEM None 4754079 Feb 27 09:48 TWiki-4.0.1.zip
-rwxrwxrwx 1 SYSTEM None 159905 Feb 7 10:09 TWikiHistory.html
-rwxrwxrwx 1 SYSTEM None 60586 Feb 7 10:09 TWikiReleaseNotes04x00x00.html
-rwxrwxrwx 1 SYSTEM None 7352 Feb 7 10:08 UpgradeTwiki
drwxrwxrwx+ 3 SYSTEM None 0 Feb 27 16:03 bin
drwxrwxrwx+ 8 SYSTEM None 0 Feb 7 10:09 data
-rwxrwxrwx 1 SYSTEM None 3287 Feb 7 10:08 index.html
drwxrwxrwx+ 4 SYSTEM None 0 Feb 27 15:06 lib
drwxrwxrwx+ 2 SYSTEM None 0 Feb 7 10:08 locale
drwxrwxrwx+ 8 SYSTEM None 0 Feb 7 10:09 pub
-rwxrwxrwx 1 SYSTEM None 817 Feb 7 10:08 pub-htaccess.txt
-rwxrwxrwx 1 SYSTEM None 3143 Feb 7 10:08 readme.txt
-rwxrwxrwx 1 SYSTEM None 589 Feb 7 10:08 robots.txt
-rwxrwxrwx 1 SYSTEM None 554 Feb 7 10:08 root-htaccess.txt
-rwxrwxrwx 1 SYSTEM None 526 Feb 7 10:08 subdir-htaccess.txt
drwxrwxrwx+ 2 SYSTEM None 0 Feb 7 10:09 templates
drwxrwxrwx+ 2 SYSTEM None 0 Feb 7 10:09 tools
-rwxrwxrwx 1 SYSTEM None 2199 Feb 27 15:25 twiki_httpd.conf
-rwxrwxrwx 1 SYSTEM None 2262 Feb 7 10:08 twiki_httpd.conf.$$$
-rwxrwxrwx 1 SYSTEM None 2262 Feb 7 10:08 twiki_httpd_conf.txt
Email setup
10. Email setup for notification and registration
This section from the official doc is not relevant here because, the email setup is done with the
configure script.
Note that for me, I have some registration problems, that I will explain later.
Testing your TWiki installation
Now this is the really here where we can check that twiki is working or not.
- configure - use
http://yourdomain.com or yourip/twiki/bin/configure and tada ! The configure script should allow you to to the setup
- if not tada, then,
- You may have not modify the
/twiki/bin/LocaLib.cfg to point to the lib configuration file and folder, see above
- Icons are not displayed or you have some errors, maybe because of permissions problems
- Double-check if you have a
/bin/LocalLib.cfg and /lib/LocalSite.cfg files and re-run the configure script until you have a tada !
- The fun part now, we will try to complete the twiki setup and apply correct information where needed. I will use my own setup here.
First, let's have a look at what it missings. The initial
configure execution gives me some errors and warnings. Let's fix them for now, we will customize other stuffs later.
I will put in attachment a file called
initial_configure_output.txt because I don't want to copy all the output lines here. I have added some comments on the file itself. I will only describe here what need to be changed. An attachement called.
final_configure_output.txt will show you then my final configuration.
WARNING Like I said before, it is maybe not a 100% working config.
11. Customization - Step 1
We will now customize TWiki-4 the way we want it to work. In the following table, you will find in the comments section, why I am doing such modification
| Parameter |
Initial Value |
Change to |
Comment |
| {DefaultUrlHost} |
http://your.domain.com |
http://200.200.200.11/twiki |
I know ... quite dirty for now |
| {PubDir} |
/home/httpd/twiki/pub |
c:/twiki/pub |
Notice the path notation here |
| {TemplateDir} |
/home/httpd/twiki/templates |
c:/twiki/templates |
Idem |
| {DataDir} |
/home/httpd/twiki/data |
c:/twiki/data |
Idem |
| {Sessions}{Dir} |
/tmp |
c:/tmp |
We will try that. Maybe we are going to have some permissions issues with SYSTEM |
| {LoginManager} |
none |
none (!) |
Yes nothing has changed here, we just want to have twiki working but later we will change that |
| {Htpasswd}{FileName} |
/home/httpd/twiki/data/.htpasswd |
c:/twiki/data/.htpasswd |
We will assume that Twiki will create the file for us. If not, then we have to create it manually, that's one of my issue here |
| {Htpasswd}{Encoding} |
crypt |
sha1 |
Like recommanded by Twiki when it runs on Windows |
| {SafeEnvPath} |
/bin:/usr/bin |
/cygdrive/c/cygwin/bin;/cygdrive/c/Windows/system32 |
As recommanded by the official docs because I have the PERL5SHELL env. |
| {ConfigurationLogName} |
/home/httpd/twiki/data/configurationlog.txt |
c:/twiki/data/configurationlog.txt |
|
| {DebugFileName} |
/home/httpd/twiki/data/debug.txt |
c:/twiki/data/debug.txt |
|
| {WarningFileName} |
/home/httpd/twiki/data/warn2026-02-02.txt |
c:/twiki/data/warn2026-02-02.txt |
|
| {LogFileName} |
/home/httpd/twiki/data/log2026-02-02.txt |
c:/twiki/data/log2026-02-02.txt |
|
NOTE
- I have not listed here all the paths in the
Store Settings section where all cygwin executables are listed. By default, Twiki place a /bin/ or a /usr/bin/ string in front of each commands and Twiki seems to detect them well (no errors and it also gives me the version of the exe). I have replace all the /bin/ and /usr/bin/ by nothing ('') and still works well. Seems better like this because we are using a safeenvpath different from the unix world.
- May be I am wrong here ... I don't know ... Place a comment if you have something functional (please !!!)
- When its done, click
Next and give a password.
- Twiki will show you what have been changed
- Return to
configure to be sure that you have no more (or only known) errors and warnings
It this specific setup, I have 3 known warnings left. Nothing really important here.
pfew ... So far so good.
Now, we will test with some basic tests
12. Testing - Step 1
- Try to access the main twiki web site with
http://200.200.200.11/twiki/bin/view
- If you see the twiki welcome page then tada ! Else, then maybe you have some path wrong settings. As always, check your Apache Logs and Twiki logs in the folder
/twiki/data
My bugs (unresolved yet)
Romain - please get answers to these in Support web
13. Bugs in RcsWrap (meaning using RCS in Cygwin) REF:BUG#1
Ok, now we start the part where we have questions but no answers. In fact, I have some problems and I guess that some other twiki users around have exactly the same as me.
I will describe here the issues that I have
- On the left menu, click on
Statistics
- Click on the
Force Link to update the stats
- The update of statistics end with a very horrible error message on the web page :
TWiki detected an internal error - please check your TWiki logs and webserver logs for more information. RCS: rlog -x,v -h %FILENAME|F% of c:path,v failed:
- The Apache logs gives me :
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] ********************************\n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] RCS: rlog -x,v -h %FILENAME|F% of c:/twiki/data/Main/WebStatistics.txt,v failed: at c:/twiki/lib/TWiki/Store/RcsWrap.pm line 245.\n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] \n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] ********************************\n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] ********************************\n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] RCS: rlog -x,v -h %FILENAME|F% of c:/twiki/data/Main/WebStatistics.txt,v failed: at c:/twiki/lib/TWiki/Store/RcsWrap.pm line 245.\n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] \n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] ********************************\n
[Wed Mar 01 17:13:20 2006] [error] [client 205.205.247.11] RCS: rlog -x,v -h %FILENAME|F% of c:/twiki/data/Main/WebStatistics.txt,v failed: at c:/twiki/lib/TWiki/Store/RcsWrap.pm line 245.\n
- Twiki logs are like this :
| 02 Mar 2006 - 03:13 | RCS: rlog -x,v -h %FILENAME|F% of c:/twiki/data/Main/WebStatistics.txt,v failed: at c:/twiki/lib/TWiki/Store/RcsWrap.pm line 245.
- And the
RCS process is never shown in the process list in Windows.
hmmm ... At this point I don't know what to do to make
RCS work with cygwin. Some users says that it could be some permissions issues but if you see the permissions section below, you can see that
system is the owner of all files and can do
read, execute and write everywhere in Twiki.
My Guess
- Bad settings in the
configure script
- Bad settings in the
httpd.conf file
14. Bugs in RcsLite (meaning NOT using RCS in Cygwin) REF:BUG#2
Ok then, if
RCS in
cygwin is not working, why not trying to use
RCSLite ? Let's do that.
Question I have never clearly see in twiki what is the real difference between using
RCSlite and
RCS with
Cygwin. Maybe it could be nice that the devellopper give us some infos about that. The only things that I saw are :
-
RCSLite can be used if RCS with Cygwin is not working.
- Perfect, but in this case, why they still mention
RCS with Cygwin everywhere ??
-
RCSLite is used for some sort of cross platform portability
- Cool ! But what is the best practice for Windows ? Apache ?. I can understand that with Linux it is working perfectly but in Windows it is a different story
Let's activate
RCSLite for now.
- Go again in
http://200.200.200.11/twiki/bin/configure
- In the
Store Settings section, change RcsWarp to RcsLite
- Save as usual.
- Go to
http://200.200.200.11/twiki/bin/view
- then on the left, select the
Statistics
- Do a
force to update
It's working !
You can test to add some texts in other topics, just to be sure.
Question It seems that when I choose
RcsLite, the versions are incremented by +1 instead of +.1. I say that because just have a look at the bottom of this page. For mw, all increments are done by adding 1 to the current version. Don't know if it is a bug but I prefere to consider this as a bug.
- Other RcsLite users, please give your opinion and knowledge !
15. Bugs in registration REF:BUG#3
Now, I want to just the inside plug-in template to handle the registration.
To do that, I need :
- To change the login system in the
configure script, so go to http://200.200.200.11/twiki/bin/configure again
- In the
Security section there is a Authentication part.
- Here, change the
{LoginManager} value from none to = TemplateLogin
- Save as usual
- You will notice that in the
Miscellaneous settings section, there is a {RegistrationApprovals} field with the value c:/twiki/data/RegistrationApprovals
- This folder is not created by default but it seems that twiki create it as needed.
- Unfortunatly, it is created (for me) with the wrong permission (SYSTEM is missing)
- I have went into
cygwin and do a quick chmod 777 RegistrationApporvals -R = in =C:/twiki/data, just to be sure
- I think that you need also some valid email settings, so I have entered my SMTP server like
emailserver.mydomain.com in the Mail and Proxy section, in the {SMTP}{MAILHOST} field.
- In the
Security section there is a Authentication part, you will notice also that it is mentioned in the {PasswordManager} that we are going to use the Htpasswd method, meaning that each users will have its account created and crypted in a file .htpasswd located at {Htpasswd}{FileName} = =c:/twiki/data/.htpasswd
- This file is not present after a
save, that's strange ...
not really, it's not a TWiki file. Create a blank file using: $ touch data/.htpasswd
Anyway, I have made those changes and save. Now :
- Back in
http://200.200.200.11/twiki/bin/view there is now a login or register part in the menu
- I need now to register myself and went into the procedure (name, password, etc.)
- Just after, a page is displayed to confirm the registration and at the same time I have an email in my inbox that gives me my registration code, cool !
- I have copied/pasted this info (RomainPelissier.111111111 for ex) en
confirm
- Twiki seems to do something and then ... crash (I have a page not found)
- I have checked : there is no
.htpasswd file in /twiki/data ?
- why not creating one with the
htpasswd apache utility ? (Don't try to create it under Window Explorer, it will not work !)
- The file is created (=htpasswd.exe -c -s c:\twiki\data\.htpasswd RomainPelissier
- Give the password and confirm it
- The user is created in the file !
- I have checked the permissions : they are wrong in the twiki point of view, so go back with
cygwin, use chmod 664 .htpasswd and chown system .htpasswd, just to be sure
- Go again in Twiki and the registration process
- Having the confirmation page and the email, good !
- Check in Apache log and have this :
[Wed Mar 01 18:18:42 2006] [error] [client 205.205.247.11] OopsException(attention/confirm web=>Main topic=>TWikiRegistration params=>romainp@nianiania.com)\n
- Checked in the
/data/RegistrationAppovals that I have an item : RomainPelissier.1667175292, yes !
- Copy/Paste then
submit
- Twiki is working for a while ...
-
The page cannot be displayed , damned !
- User is not created, the file in
/data/RegistrationAppovals has disapeared
note: the error below is due to your not setting a valid email address for the WIKIWEBMASTER. the default is webmaster@examplePLEASENOSPAM.com, which is what is causing your error.
- Apache have some errors :
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] ERROR: Can't send mail using Net::SMTP. 5.7.1 Unable to relay for webmaster@example.com\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] at c:/Perl/lib/CGI/Carp.pm line 314\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tCGI::Carp::realdie('ERROR: Can\\'t send mail using Net::SMTP. 5.7.1 Unable to rela...') called at c:/Perl/lib/CGI/Carp.pm line 389\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tCGI::Carp::die('ERROR: Can\\'t send mail using Net::SMTP. 5.7.1 Unable to rela...') called at c:/twiki/lib/TWiki/Net.pm line 301\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::Net::_sendEmailByNetSMTP('TWiki::Net=HASH(0x1ce8080)', 'Date: Thu, 02 Mar 2006 04:29:44 Local\\x{a}From: TWiki Administrat...') called at c:/twiki/lib/TWiki/Net.pm line 192\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::Net::__ANON__() called at c:/twiki/lib/CPAN/lib///Error.pm line 387\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \teval {...} called at c:/twiki/lib/CPAN/lib///Error.pm line 379\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tError::subs::try('CODE(0x1b21d3c)', 'HASH(0x21df7bc)') called at c:/twiki/lib/TWiki/Net.pm line 208\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::Net::sendEmail('TWiki::Net=HASH(0x1ce8080)', 'From: TWiki Administrator \\x{a}To: TWiki A...') called at c:/twiki/lib/TWiki/UI/Register.pm line 959\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::Register::_emailRegistrationConfirmations('TWiki=HASH(0x1ce7d50)', 'HASH(0x2053b24)') called at c:/twiki/lib/TWiki/UI/Register.pm line 751\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::Register::finish('TWiki=HASH(0x1ce7d50)', 'c:/twiki/data/RegistrationApprovals') called at c:/twiki/lib/TWiki/UI/Register.pm line 89\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::Register::register_cgi('TWiki=HASH(0x1ce7d50)') called at c:/twiki/lib/TWiki/UI.pm line 97\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::__ANON__() called at c:/twiki/lib/CPAN/lib///Error.pm line 387\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \teval {...} called at c:/twiki/lib/CPAN/lib///Error.pm line 379\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tError::subs::try('CODE(0x208ab58)', 'HASH(0x165879c)') called at c:/twiki/lib/TWiki/UI.pm line 146\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::run('CODE(0x1725628)') called at c:\\twiki\\bin\\register line 31\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] ********************************\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] ********************************\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] OopsException(attention/send_mail_error web=>Main topic=>RomainPelissier params=>ERROR: Can't send mail using Net::SMTP. 5.7.1 Unable to relay for webmaster@example.com\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] at c:/Perl/lib/CGI/Carp.pm line 314\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tCGI::Carp::realdie('ERROR: Can\\'t send mail using Net::SMTP. 5.7.1 Unable to rela...') called at c:/Perl/lib/CGI/Carp.pm line 389\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tCGI::Carp::die('ERROR: Can\\'t send mail using Net::SMTP. 5.7.1 Unable to rela...') called at c:/twiki/lib/TWiki/Net.pm line 301\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::Net::_sendEmailByNetSMTP('TWiki::Net=HASH(0x1ce8080)', 'Date: Thu, 02 Mar 2006 04:29:44 Local\\x{a}From: TWiki Administrat...') called at c:/twiki/lib/TWiki/Net.pm line 192\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::Net::__ANON__() called at c:/twiki/lib/CPAN/lib///Error.pm line 387\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \teval {...} called at c:/twiki/lib/CPAN/lib///Error.pm line 379\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tError::subs::try('CODE(0x1b21d3c)', 'HASH(0x21df7bc)') called at c:/twiki/lib/TWiki/Net.pm line 208\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::Net::sendEmail('TWiki::Net=HASH(0x1ce8080)', 'From: TWiki Administrator \\x{a}To: TWiki A...') called at c:/twiki/lib/TWiki/UI/Register.pm line 959\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::Register::_emailRegistrationConfirmations('TWiki=HASH(0x1ce7d50)', 'HASH(0x2053b24)') called at c:/twiki/lib/TWiki/UI/Register.pm line 751\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::Register::finish('TWiki=HASH(0x1ce7d50)', 'c:/twiki/data/RegistrationApprovals') called at c:/twiki/lib/TWiki/UI/Register.pm line 89\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::Register::register_cgi('TWiki=HASH(0x1ce7d50)') called at c:/twiki/lib/TWiki/UI.pm line 97\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::__ANON__() called at c:/twiki/lib/CPAN/lib///Error.pm line 387\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \teval {...} called at c:/twiki/lib/CPAN/lib///Error.pm line 379\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tError::subs::try('CODE(0x208ab58)', 'HASH(0x165879c)') called at c:/twiki/lib/TWiki/UI.pm line 146\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \tTWiki::UI::run('CODE(0x1725628)') called\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] \n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] Too many failures sending mail)\n
[Wed Mar 01 18:29:57 2006] [error] [client 205.205.247.11] ********************************\n
And that's all ...
Investigations
I have seen that :
- The mail handling is buggy with the Dakar 4.01 but it can be updated with SVN (
http://svn.twiki.org:8181/svn/twiki/trunk/). Unfortunatly for me, my firewall does not all any 8181 port connections. Maybe it can be more easy for everybody if some diff files can be provided also
- The
.htpasswd problem has been noticed ny other users and they say that it is a permission problem. Not sure for me because I have changed this permissions on the file ...
Conclusion
So as you can see, I have done my work with this doc. Like I said I hope that it could be used as the official
DakarDocumentation when it will be completed, tested and make twiki functional.
My only hope if that other users can help me. I will create a general support topic called
DakarNotWorkingAsExpected that will reference to this topic.
I am pretty sure that the remaining problems could be solved with the help of everybody. Believe me when I say that creating this walkthrough was really hard to do and very long to create. But it worth it I think.
I will update it as soon as I have other news or updates.
I will also create a table below to gives the list of the contributors and the status of the bugs. It will not be a replacement of the
SupportWeb, but only an easy way to maintain this topic.
Update
REF:BUG#1
For the problem with
RcsWarp, it seems to be a
path problem. If I change the
SafeEnvPath to
c:\cygwin\bin;c:\windows\system32 then the following appear :
- When updating the stats, if works once, cool !
- Why not trying that again ? So I update the stats another time and ... I've got a permission issue
- Lookin at
data/Main/WebStatistics.txt and data/Main/WebStatistics.txt,v the permissions have changed and the .txt.v file is now only read only.... and always stay like this.
- I have read a little about the
ci program and it seems that it is normal that the file does not have the write permission anymore but for always like this seems to be a bug for me ....
- Tried also for
{SafeEnvPath} with c:/cygwin/bin;c:/windows/system32 gives me the same error.
REF:BUG#3
For the registration, I have try to change the setting for the password to
none but still have the same issue :
- Go through the registration process
- Enter my registration number when prompted
- Then an ugly
page not found appear
- The user itself is never created ...
GNUWIN32
I have tested this version to find if it is working better than
cygwin but even if Twiki can find the version of
rcs, it still not working for me ...
Discussion
--
RomainPelissier - 27 Feb 2006
Looks comprehensive - thanks Romain.
I'd suggest you use
GnuWin32 rather than
CygWin.
Try
IndigoPerl rather than plain Apache
TWikiInstallerWindowsContrib has an approach to automate an installer - this is the best way to ensure longevity and continuous improvement to your efforts.
--
MartinCleaver - 03 Mar 2006
Good work, Romain. Corrected a lot.
For my information, why didn't you use/update
TWikiOnWindows or
WindowsInstallCookbook? I'm concerned that old, inaccurate cookbooks are being left around and not updated for TWiki-4.
From -- RomainPelissier - 28 Mar 2006
Simply because I always feel that the WindowsInstallCookbook topic was more related to the Cairo release. So I have decided to create a specific one for Dakar. In my opinion, having different version require different documentation, even if for the most part you only need to do a copy/paste. Another remark is because when a user google 'Dakar Windows Twiki' the chances that he can go there directly a more important than goign to the WindowsInstallCookbook'
--
CrawfordCurrie - 10 Mar 2006
concering rcs errors with Apache/Cygwin/RCS/ActivePerl configuration: it's a command line quoting problem. In httpd.conf I have set
PERL5SHELL to "c:/cygwin/bin/bash.exe -c". After i changed in function sysCommand of file Sandbox.pm the lines
my $cq = $this->{CMDQUOTE};
my $cmd = $path.' '.$cq.join($cq.' '.$cq, @args).$cq;
to
my $cq = '\\"';
my $cmd = '"'.$path.' '.$cq.join($cq.' '.$cq, @args).$cq.'"';
I can at least save wiki edits without rcs errors.
--
BrankoBange - 10 Mar 2006
Thanks for that, Branko. Note that quotes are only a problem on platforms that do
not support safe pipes. At this point, the only platform that does not is cygwin perl. If you use
ActiveStatePerl or
IndigoPerl, which support safe pipes, this is not an issue.
You can control what quotes are used without having to change code. Here's how TWiki determines what quotes to use:
if ({OS} == 'UNIX' OR ({OS} == 'WINDOWS' AND {DetailedOS} == 'cygwin'))
CMDQUOTE = '
else
CMDQUOTE = "
Where
{OS} and
{DetailedOS} are the settings in the "Operating System" section of the
configure interface. So you can see that by modifying these settings you can control quote selection
without changing any code. However I am surprised that the cygwin shell command line doesn't like single quotes; it probably has to do with the -c on the
PERL5SHELL setting (I don't run cygwin any more myself; I use
IndigoPerl, which is
much easier to set up).
BTW the reason it tries to use single quotes is that double-quotes do not prevent interpolation of arguments by the shell. This is a major security risk, so we have tried to
minimise the number of cases in which double quotes might be used.
--
CrawfordCurrie - 11 Mar 2006
"Apache 2.0 will not be used because I don't know if it is officially supported by Twiki-Dakar".
Why does people still have the impression that TWiki does not support Apache2? It has been working fine on Apache 2 for years. There was an issue with a
CGI related bug in some specific versions of Apache2. Round 2.0.4X. Apache 2.0.5X does not have this problem.
From -- RomainPelissier - 28 Mar 2006
In the initial cookbook of twiki, for tha caero release if I remember well, it is said that Apache 1.3.4.xx is highly recommanded instead of Apache 2 because of some bugs. So for this documentation I have started with what if officially supported by the twiki team. I have tested with Apache 2 and make it work the same as Apache 1.3.4.xx so I know that it could be made. Remember that for the moment the cookbook is only to try to make Dakar working perfectly. I you or someone tell me that he have the solution to make twiki running perfectly with apache 2 then be sure that I will update this documentation and forget about Apache 1.3.4.xx
--
KennethLavrsen - 11 Mar 2006
Thanks Crawford. Actually double quotes caused the trouble. Changing
DetailedOS to cygwin solved the problem. I AM using
ActiveStatePerl, but safe pipes are not used. Looking at sub new in Sandbox.pm (Dakar 4.0.1) it seems that safe pipes are never used on windows. Setting REAL_SAFE_PIPE_OPEN and/or EMULATED_SAFE_PIPE_OPEN to 1 causes errors.
--
BrankoBange - 15 Mar 2006
I followed this cookbook and install twiki on win2k server.
Here are my notes when I installed it.
I followed the guide until I reached:
configuring twiki
in /twiki/bin
chmod 755 *
if I don't do "chmod", the privilege will not allow me to modify the script files by
running rewriteshbang.pl, I give "d:/perl/bin/perl" for the perl path.
Now you can see
http://localhost/twiki/bin/configure
fix error when run configure:
create
LocalSite.cfg in twiki/lib
* don't need modify /twiki/lib/TWiki.cfg because
LocalSite.cfg will override the settings in twiki.cfg
* not sure about
$cfg{SafeEnvPath} = '/bin';
$cfg{RCS}{BinDir} ||= 'd:/cygwin/bin';
They are in Twiki.cfg with original values, but every thing looks fine right now.
after I changed it, it looks same.
No registration email send out, so I modified following by using configure:
{SMTP}{MAILHOST} mymailserver.anywhere.com
I can receive registration email now, but can not active
using configure, modify:
{Htpasswd}{Encoding} sha1
{SafeEnvPath} /cygdrive/d/cygwin/bin;/cygdrive/c/winnt/system32
{SMTP}{SENDERHOST} myserver
Attention: modify setting using configure will modify the
LocalSite.cfg only, not Twiki.cfg
But I can not register new user. I check the log file. Then, I modify the D:\twiki\data\TWiki\TWikiPreferences.txt
to change
webmaster@examplePLEASENOSPAM.com to
myemail@anywherePLEASENOSPAM.com
it works now: I can register a new user and it is listed on the Users list
But I still got the issue about registration. Please see "CanNotRegisterNewUser" in support page.
--
EdwinMa - 23 Mar 2006
Wow ! I am so glad that several great people have read and make addition to that documentation! Thanks for you all ! I am sorry if I was quite not very active on my own documentation those last weeks but the twiki project make me late at work for several other projects. Anyway, I will post more news and comments soon and also try to finish the IIS6 part of the documentation.
--
RomainPelissier - 24 Mar 2006
Did you look also at
TWikiInstallerWindowsContrib?
--
MartinCleaver - 28 Mar 2008
Just updated the sections on running IIS and Apache on the same box. The section on using ADSUtil was only for IIS5 (noted in the MS Doc). You need to use the httpcfg util for IIS6.
--
NathanReeves - 09 May 2006
Once this is fully debugged, this should replace
WindowsInstallCookbook, with that page being renamed to WindowsInstallCookbookForCairo or whatever. However, I think the real future of
TWikiOnWindows is mostly to use
TWikiVMDebianStable - you can have a working TWiki just 5 minutes after download completes. The trouble with a full 'cookbook' installation is that it takes a very long time for most people, and it's too easy to make mistakes.
Since this page is heavily based on the
WindowsInstallCookbook, it should have a prominent acknowledgement pointing to that page.
--
RichardDonkin - 07 Aug 2006
Managed to install and get operational OK, but
RCS doesnt seem to work so cant do edits. Get the error:
During save of
Main an error was found by the version control system. Please notify your TWiki administrator.
=RCS: /usr/bin/rlog -x,v -h %FILENAME|F% of .../Main/WebHome.txt,v failed: =
Im using Apache/ActivePerl/cygwin
RCS
Any ideas?
--
QuentinNorth - 09 Aug 2006
Richard, let's be careful with all these windows cookbooks. The
IndigoPerlCookbook is another perfectly valid way to install on Windows; there isn't "just one way" to install TWiki. The
WindowsInstallCookbook should be refactored as a gateway for topics covering all these different configurations, and weighing the pros and cons of the different approaches.
Quentin, does
RCS work from the command line? In a shell, cd to
data/Main and
/usr/bin/rlog -x,v -h WebHome.txt,v
--
CrawfordCurrie - 09 Aug 2006
Crawford - you're right, but for a newbie it's good if the
TWikiCommunity points to one out of various approaches so it's easy to see that 'most people think this is the best way to install on Windows'. It's fine to link to various other approaches including
TWikiVMDebianStable and
IndigoPerlCookbook, as long as we say one or other is a good approach (which might well be Indigo).
--
RichardDonkin - 09 Aug 2006
I followed this cookbook and finally I got it working on 2003 with Apache 2.0 and
RcsLite. I was stuck with some errors on editing (cannot open X for write). It was solved replacing all dirs in General Path Settings. So if you find such problems, try to use /twiki/X instead of c:/twiki/X
everywhere.
--
DanielCardenas - 22 Nov 2006