From usenet.ucs.indiana.edu!ux1.cso.uiuc.edu!howland.reston.ans.net!agate!overload.lbl.gov!lll-winken.llnl.gov!iggy.GW.Vitalink.COM!wetware!spunky.RedBrick.COM!psinntp!psinntp!laidbak!tellab5!ruth.wheaton.edu!jcfowler Fri Jun 25 14:44:22 EST 1993 Article: 1303 of comp.infosystems.wais Newsgroups: comp.infosystems.wais Path: usenet.ucs.indiana.edu!ux1.cso.uiuc.edu!howland.reston.ans.net!agate!overload.lbl.gov!lll-winken.llnl.gov!iggy.GW.Vitalink.COM!wetware!spunky.RedBrick.COM!psinntp!psinntp!laidbak!tellab5!ruth.wheaton.edu!jcfowler From: jcfowler@david.wheaton.edu (John C Fowler) Subject: Installing WAIS on a gopher server Message-ID: <1993Jun24.144016.9805@wheaton.wheaton.edu> Summary: Instructions that hopefully everyone can follow. Sender: news@wheaton.wheaton.edu (USENET News System) Organization: Wheaton College, IL Date: Thu, 24 Jun 1993 14:40:16 GMT Lines: 209 I little while ago, I sent out a post requesting an easy to read "how to" procedure on installing WAIS within Gopher. Several people have emailed me, and with their help, installing WAIS was a breeze... All it took was getting past the initial confusion, and then everything seemed to clear up. Recently, I have had a few people email me requesting that I send a post with the answers that I received via email. This would be quite a large post if I included all, so I chose the one which I found easiest to understand. My recomendation for any who choose to set up a WAIS indexer within their gopher, is to fully read this document before starting, and everything will run smoothly. (not a guarantee, however) The following is sent by Eric Celeste from MIT, and it explains the two part procedure to installing WAIS. The first part is making the index, and the second is putting a menu item in your gopher to use the index. For the second part of the procedure, he used a symbolic link explaining that he was unable to get a .Links entry to work. After his article, I have included instructions on how to make the .Links entry work. >From efc%wonder@WONDER.MIT.EDU Mon Jun 14 06:00:11 1993 >Received: from wonder (WONDER.MIT.EDU) by david.wheaton.edu with SMTP id AA11394 > (5.65c+/IDA-1.4.4 for ); Mon, 14 Jun 1993 09:12:27 -0500 >Message-Id: <199306141412.AA11394@david.wheaton.edu> >Received: by wonder id AA01574g; Mon, 14 Jun 93 10:00:11 -0400 >Date: Mon, 14 Jun 93 10:00:11 -0400 >From: Eric Celeste >Received: by NeXT.Mailer (1.87.1) >Received: by NeXT Mailer (1.87.1) >To: jcfowler@david.wheaton.edu (John C Fowler) >Subject: Re: Installing a Wais Server on Gopher >Reply-To: efc@mit.edu >Status: OR > >In comp.infosystems.wais article ><1993Jun10.142555.2959@wheaton.wheaton.edu> you wrote: >> I am looking for easy-to-understand-and-follow directions on installing >> the server on Gopher. > >I don't think these easy directions exist! I just went through this last >week and it was quite complicated with the instructions included in the >WAIS and Gopher distributions. I'll pass along some brief hints in this >message, but I am making some assumptions: you've already been able to >compile Gopher and WAIS distributions successfully and you are using a >Unix system. > >The Gopher distribution does come with clear instructions on how to >compile Gopher with the WAIS searching capability enabled. Follow these >instructions. (They involve compiling the WAIS distribution and then >linking some directories to your Gopher source code directory. Finally, >you must recompile Gopher's gopherd deamon.) > >Once this is done, you have to index the files you want searchable and >link a Gopher menu choice to that index. This turned out being more >complicated than the documentation implies. What I present below is just >one approach. I think its the simplest. It turns out that there are many >other ways to reach the same objective. Good luck! > >Let's say you have a Gopher with the following structure... > >/server/gopher/gopher-data > About-this-gopher > Interesting-Stuff > Poems > [lots of poems here] > Stories > [lots of stories here] > Documentation > [lots of documentation here] > Testing-place > My-junk > >Now let's say that you want to index the stories inside the Stories >directory so that your users can keyword search them. Your gopherd has >been compiled with WAIS searching turned on, so you are ready to begin the >task of linking WAIS and Gopher together. For the purposes of this example >I will assume the gopher source code is in /server/gopher/code. > >Create a directory in your gopher-data directory to hold the indexes you >will create... > > % cd /server/gopher/gopher-data > % mkdir wais-indexes.dev > >Note that the ".dev" on this file makes it invisible to gopher clients >using your server. Now we want to make the index... > > % /server/gopher/code/bin/waisindex -r -t filename \ > -d /server/gopher/gopher-data/wais-indexes.dev/stories-index \ > /server/gopher/gopher-data/Interesting-Stuff/Stories > >Note that the "\" at the end of the first two lines just mean the line is >continued on the next line, you could type all this on one line without >the "\" characters. Read the man page on waisindex to see what the various >switches I use above are there for. > > >What you now have is a bunch of WAIS-created files in the wais-indexes.dev >directory that all begin with the name stories-index. I've found the >easiest way to include this item on the menu is to use a Unix symbolic >link in my menu structure, I had trouble using the .links file method >described in the documentation with gopher+1.2b4. So I then do the >following... > > % cd /server/gopher/gopher-data/Interesting-Stuff > % ln -s /server/gopher/gopher-data/wais-indexes.dev/stories-index.src \ > Keyword-Search-Stories.src > >So now I have an item in the Interesting-Stuff directory that actually >does the WAIS search for the user. > >Yike! Not so simple! And certainly not the only (or even recommended by >Gopher-folk) way of doing this stuff. But I hope it helps, I know I spent >a long time agonizing. > >...Eric > >P.S. I found that if I used spaces in my gopher-data directory names my >WAIS search would work but the documents WAIS found could not be displayed >by gopherd. I worked around this by linking the directory with the text >into an invisible no-spaces-in-the-name directory at the top level of my >gopher-data hierarchy. If you need details on this, let me know! > >-------------------------------------------------------------------- >Eric Celeste / MIT Libraries / 14E-210A / 617-253-0633 / efc@mit.edu >-------------------------------------------------------------------- > Now, there are some down sides to the symbolic link aproach (ln -s ...). The main one deals with the return of the keyword search when you use it. It will return the actual file names that are found in the directory, and not the names given to them in the .cap directory or the .Links file. To solve this, we use an entry in the .Links file instead of making a symbolic link to the stories-index.src file. Here's how: After you have done this command (as instructed by Eric): > > % /server/gopher/code/bin/waisindex -r -t filename \ > -d /server/gopher/gopher-data/wais-indexes.dev/stories-index \ > /server/gopher/gopher-data/Interesting-Stuff/Stories > you have made the index. Now all you need to do is edit the .Links file within the directory which you would like the keyword search option to be in. To do this, you must first change to that directory. In Eric's example, this is done by, > % cd /server/gopher/gopher-data/Interesting-Stuff Next, you edit the .Links file within this directory. If there is no .Links file, it is alright to go ahead and create one. Nothing will be hurt by it. Using your favorite editor, mine is vi (no flames please), enter the following data within the file: # Name=Keyword Search of Stories Type=7 Path=7/wais-indexes.dev/stories-index Host=+ Port=+ # The "Name=" Portion will be what shows up in the gopher server as the menu option to do the keyword search. You can change this to be whatever you would like it to be. The "Type=" must be set to "7". This tells the gopher server that indeed, you do want this to be a WAIS keyword search. The "Path=" as well must start with a "7" and then have the path relative to the gopher-data directory. This is a result of the gopher server automaticly recognizing the gopher-data directory as being it's root directory whenever it is run. You will want to change the "stories-index" to whatever index name you chose when you initially ran the waisindex program. Other than that, the "Path=" will remain the same. As for the "Host=+" and "Port=+", these do not need to be changed at all. And, Walla! You've got a nifty ole WAIS indexer within your gopher server. However, if you are having a couple problems, here are two problems with some suggestions on how to fix them: First, if you have followed all of the directions, and no entry to do a WAIS keyword search has shown up in your gopher server, it may mean that you need the .cache renewed. To do this, you must first change to the directory that has the .Links file or the symbolic link via the 'cd' command. Next, to renew the .cache, simply remove it by typing 'rm .cache'. It is ok to remove the .cache file, you don't have to worry about it messying anything up. As soon as the gopher server detects that it is gone, it simply remakes it according to what is in the directory. If the option still doesn't show up, ask the nearest gopher guru, or spend a couple hours in the documents. Unfortunately, that is the only advice that can be given. The second problem that may arise comes with the actual implementation of the WAIS index after it has been placed in the server. If you choose the option, then type in a word to search for, and this error comes back: ERROR: No wais stuff in the server!! you didn't compile the gopher option into your gopher server. Don't worry, this too can be fixed. What it takes, is recompiling your gopher server with the WAISSEARCH variable defined. This procedure is found in the gopher documents that explain how to compile a gopher server. Well, there it is. A little long, but hopefully readable enough for anyone to follow. If you do have question, comments, flames, or just general gossip, I'd be glad to hear from you. :-) All standard disclaimers apply. my email address is: jcfowler@david.wheaton.edu john... _ \__ /( __> //| \ ///___) Shadowfax...