Documentum Technical Information

This blog provides useful technical information about EMC Documentum. Moderated by Steve Garrison of Nerka IT, Inc.

How to Filter FAST Full-Text Index to Exclude Selected Object Types

clock December 10, 2008 02:57 by author Steve Garrison

Objective: wish to have two object types and subtypes indexed only. Do not want dm_sysobject indexed, nor dm_document type. So this process includes full-text indexing for just certain types in the object model.

Since out of the box dm_sysobject is registered for full-text indexing, all objects under that type and subtypes will get full-text indexed, including dm_application, dm_job, job reports, and all their attributes.  However, usually you don’t wish to full-text index everything, just documents from selected types. This process accomplishes the goal of filtering what is included in the full-text index.

Procedure

Note: this is my rewritten procedure. Originally the basic process was an EMC/Documentum support note which was very poorly worded and took me hours to decipher.

Remember to try this in a sandbox or dev environment first. This process was implemented in two systems and then successfully put into a final production system.

In this example we want to register only two types & all their subtypes and attributes: rtd_document and dm_message_archive. One of these types is a custom type

In order to re-index only the objects from the two selected types follow these steps:

 

1. Unregister and register the super type that you want to register

 

- In iapi.exe unregister the current events for the dm_fulltext_index_user  for  dm_sysobject. You can use Documentum Administrator or iapi.exe.

 

Fetch r_object_id of dm_sysobject.. This is “0319978f80000105”  in this example. You could fetch using this query: select r_object_id from dm_type where name = 'dm_sysobject'

 

API> unregister,c,0319978f80000105,dm_save,dm_fulltext_index_user

API> unregister,c,0319978f80000105,dm_destroy,dm_fulltext_index_user

API> unregister,c,0319978f80000105,dm_readonlysave,dm_fulltext_index_user

API> unregister,c,0319978f80000105,dm_checkin,dm_fulltext_index_user

API> unregister,c,0319978f80000105,dm_move_content,dm_fulltext_index_user

 

1a. Logon to server via Remote Desktop and use iapi.exe. Or use local iapi.exe if you have installed locally.

 

Connect as dm_fulltext_index_user

 

API> getlogin,c,dm_fulltext_index_user,

 

Returns a dm_ticket with many characters as shown below. This is an example ticket only.

 

DM_TICKET=T0JKIE5VTEwgMAoxMwp2ZXJzaW9uIElOVCBTIDAKMwpmbGFncyBJTlQgUyAwCjAKc2VxdWVuY2VfbnVtIElOVCBTID

AKMzE3OQpjcmVhdGVfdGltZSBJTlQgUyAwCjEyMjU5OTIzNTgKZXhwaXJlX3RpbWUgSU5UIFMgMAoxMjI1OTkyNjU4CmRvbWFpbi

BTVFJJTkcgUyAwCkEgNyBydGQuZG9tCnVzZXJfbmFtZSBTVFJJTkcgUyAwCkEgMjIgZG1fZnVsbHRleHRfaW5kZXhfdXNlcgpwYXN

zd29yZCBTVFJJTkcgUyAwCkEgNzcgRE1fRU5DUl9URVhUPXdPU0RBNm1pNTgxajdiSmQxalltVWxmdUUvN0RpUEdVSFA3c0Yz

SWhGTXZlcjB3RFJyRVZtQmZiS0h5Um5rYXIKZG9jYmFzZV9uYW1lIFNUUklORyBTIDAKQSA0IGNFQ00KaG9zdF9uYW1lIFNUUklO

RyBTIDAKQSA4IGNDT05URU5UCnNlcnZlcl9uYW1lIFNUUklORyBTIDAKQSA0IGNFQ00Kc2lnbmF0dXJlX2xlbiBJTlQgUyAwCjU2C

nNpZ25hdHVyZSBTVFJJTkcgUyAwCkEgNTYgVnVSSHVqbWlVSytpaFpXa2UzTDVmTTB3WXp0bTBoZTZVV2w1eHJoRmhXUzZYY

UYxeWxScGpRPT0K

 

Using the login ticket connect as dm_fulltext_index_user. Paste the login ticket as shown below. Note that USER below in blue is a superuser, typically dm_admin or similar.

 

 

API> connect,USER,dm_fulltext_index_user,DM_TICKET=T0JKIE5VTEwgMAoxMwp2ZXJzaW9uIElOVCBTIDAKMwpmbGFncyBJTl

QgUyAwCjAKc2VxdWVuY2VfbnVtIElOVCBTIDAKMzE3OQpjcmVhdGVfdGltZSBJTlQgUyAwCjEyMjU5OTIzNTgKZXhwaXJlX3RpbWU

gSU5UIFMgMAoxMjI1OTkyNjU4CmRvbWFpbiBTVFJJTkcgUyAwCkEgNyBydGQuZG9tCnVzZXJfbmFtZSBTVFJJTkcgUyAwCkEgMjI

gZG1fZnVsbHRleHRfaW5kZXhfdXNlcgpwYXNzd29yZCBTVFJJTkcgUyAwCkEgNzcgRE1fRU5DUl9URVhUPXdPU0RBNm1pNTgx

ajdiSmQxalltVWxmdUUvN0RpUEdVSFA3c0YzSWhGTXZlcjB3RFJyRVZtQmZiS0h5Um5rYXIKZG9jYmFzZV9uYW1lIFNUUklORyBT

IDAKQSA0IGNFQ00KaG9zdF9uYW1lIFNUUklORyBTIDAKQSA4IGNDT05URU5UCnNlcnZlcl9uYW1lIFNUUklORyBTIDAKQSA0IG

NFQ00Kc2lnbmF0dXJlX2xlbiBJTlQgUyAwCjU2CnNpZ25hdHVyZSBTVFJJTkcgUyAwCkEgNTYgVnVSSHVqbWlVSytpaFpXa2UzTD

VmTTB3WXp0bTBoZTZVV2w1eHJoRmhXUzZYYUYxeWxScGpRPT0K

 

... Result:

 

s1

 

- Register events for desired types. Remember- we are registering just two supertypes and all their subtypes and attributes.  Run these steps first for rtd_document and repeat for dm_message_archive. Only rtd_document is shown in example below.

 

Fetch r_object_id for rtd_document…it is 030000fb800001d7.

Fetch r_object_id for dm_message_archive…it is 030000fb80000169.

 

API> register,c, 030000fb800001d7,dm_save,,F

 

SET> F

...

Returns: OK

 

API> register,c, 030000fb800001d7,dm_destroy,,F

 

SET> F

...

Returns: OK

 

API> register,c, 030000fb800001d7,dm_readonlysave,,F

 

SET> F

...

Returns: OK

 

API>register,c, 030000fb800001d7,dm_checkin,,F

 

SET> F

...

Returns: OK

 

API>register,c, 030000fb800001d7,dm_move_content,,F

 

SET> F

...

Returns: OK

 

 

2. Stop Index Agent. Do one time after registering dm_message_archive & rtd_document above.

 

3. From Fast InStream Admin page http://<index server>:16000. Go to collections and under "Collection Overview" find the name of the collection associated to the repository in question.

 

4. Click on the trash icon "Delete collection "<name of the collection>".

 

5. Wait until the process of deleting the collection completes:

 

- First it will delete the index information

- Second it will delete the fixml information

 

6. Using the Index Agent configuration program delete the Index Agent associated to the repository.

 

7. If the dm_ftengine_config and dm_ftindex_agent_config objects are still present, get the r_object_id and using iapi destory both objects:

 

API> retrieve,c,dm_ftengine_config

 

API> destroy,c,l

 

API> retrieve,c,dm_ftindex_agent_config

 

API> destroy,c,l

 

 

8. Run the Index Agent configuration program and reconfigure the Index Agent in normal mode. In other words make a new index agent.

 

 

9. Create an output file with the r_object_id's of the custom type. If two types (rtd_document & dm_message_archive) run twice: 1st time run query for 1st type, add these to ids.txt file.  Then run again for 2nd type and append those to ids.txt file. Do this on Content Server.

 

idql -Uusername -Ppassword < dql_ statement_script > ids.txt

 

idql32 dev -Uuser -Ppassword -RsteveDQL.txt > c:\dqltest.txt

 

where dql_statement_script contains the select statement as follows:

 

dqltest.txt contains:

 

select r_object_id from rtd_document

 

go

 

- Open the output file and remove the headers and leave only the r_object_id values. Paste these id's into a file named ids.txt in directory listed below on cFast.

 

C:\Documentum\bea9.2\domains\DctmDomain\upload\IndexAgent1\IndexAgent1.war\WEB-INF\classes. 

 

File formerly called ids.txt is then change to ids.txt.done.  This is a good verification by FAST – it indicates object id’s were processed. The image below shows location of ids.txt after ids.txt is processed.

 

 

Currently rated 4.7 by 3 people

  • Currently 4.666667/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


How to Set Up Logging (log4j, DfLogger) in Documentum's Composer 6.5

clock December 1, 2008 09:36 by author Steve Garrison

When you want to set up and use local logging for Java DFC classes here is an easy procedure.  Not only will you have local logging but after your code is deployed to application server (Java Method Server, Tomcat, WebLogic, etc.) the same logging setup can be configured there, too. An advantage is that you needn't use System.out statements locally and then change to log4j logging for server deployment but just configure once for log4j type logging.

 

This applies to Composer 6.5 but is probably back-compatible to other versions of Composer plus Eclipse 3x.

 

On your local developer's PC:

 

1. edit log4j.properties in c:\documentum\config or similar path. This assumes you have c:\documentum\config as a Linked Folder in your Composer project. See my other entries on setting up Composer for DFC projects.

2. add these lines or similar to log4j.properties file. See documentation on log4j logging formats if you wish to customize beyond what is shown below.

 

#----------------Custom Logging for Application called application_delete_notify -------------------------------------------

log4j.logger.application_delete_notify=DEBUG,application_delete_notify

log4j.appender.application_delete_notify=org.apache.log4j.RollingFileAppender

log4j.appender.application_delete_notify.File=c\:/Documentum/logs/application_delete_notify.log

log4j.appender.application_delete_notify.MaxFileSize=100MB

log4j.appender.application_delete_notify.layout=org.apache.log4j.PatternLayout

log4j.appender.application_delete_notify.layout.ConversionPattern=%d{HH\:mm\:ss} %p %c %m  %n

 

3. in your java classes be sure to import Logger:

 

import com.documentum.fc.common.DfLogger;

 

4. In your dfc code make sure you reference the logger with a statement something like this:

 

DfLogger.info("application_delete_notify", "DCTMLogin.doSession...session object is..." + sess,null,null);

 

Where:

 DfLogger.info = the logging level (could have used other logging levels like "debug")

 application_delete_notify = name of custom logger created in log4j.properties file

 DCTMLogin.doSession...session object is... = this is an arbitrary debugging string. You may put anything here. I wrote name of class, name of method, and outputting the hex value for a session object.

 

 + sess,null,null = "sess" is the variable outputted, and the logging format indicates you must place two null at the statement's end as shown. You could output result of any variable that's in scope as long as it's before the comma as shown.

 

 

 

5.  After running code log file will appear in location you designated above on the third line of the log4j.properties file, in other words in this path:

 

c:/Documentum/logs/application_delete_notify.log

 

Currently rated 1.0 by 2 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


References to Other Documentum Blogs

clock November 4, 2008 09:19 by author Steve Garrison

Documentum bloggers


Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


When you really need to find a file or item inside a file

clock October 28, 2008 03:10 by author Steve Garrison

Hard to believe it has come to this but Windows GUI searcher interfaces miss files frequently. I noticed this so many times that now I do command line searching...kind of sounds like a giant step backward? Now I'm confident of never missing any files. Windows command line searching is very good in these cases:

a. you really need to find a keyword inside a file because you're troubleshooting, debugging

b. you're coding and must locate a term inside a source file (.java, .vb, etc.)

To prove this point.... here is a case (Fig. 1) in which the search criteria included a search location of "hard drive and all directories and subdirectories". Files were not found even though there were two copies of the file present: one deep within an Eclipse directory and a copy on the desktop. Fig. 2 shows the results... the target files clearly contained the search term and is of type .java but files weren't found. Computer OS: XP Professional, Version 2002, SP 2. 

One Solution: 

How does command line search work?  Let's take a simple case - you just want to locate a file.  Use the "dir" command with the "/s" switch.

For example...command below searches in all subdirectories, beginning from current directory. So, if you're at the "root" of the "c" drive it will search for all documents containing SAX in the name for file type of ".java".  Pretty straightforward and covered years ago.

dir /s *SAX*.java 

What if you want to search for a string inside a file?  Also very easy, using the venerable "findstr" command. The variation below uses switch "/s" to search inside subdirectories, plus uses the "/m" switch to only show file names. If you don't use the "/m" switch it will show text of result file and location of the string in that file (which could be useful but I don't want in this particular search). See here for lots of details.

findstr /s /m "SAXBuilder" *.java

Results from this search found about 40 .java source files including the 2 target files I was looking for.  

This technique also works well for locating a string inside a log file (text file, MS Word, etc.) or similar task.  There may be a logical reason why Windows GUI search for OS cited above doesn't work properly. Personally, I don't really care because command line searching is not only totally reliable but is as fast, if not faster and one doesn't have all the annoying dogs to "help" you search!  In addition, in Vista OS you have a different search GUI.  If you use command line search you will always find targets regardless of Windows OS.  

Two items worth knowing: 1) usually you will not want to search all file types at the "c" root level because findstr command will attempt to open files that cannot be opened like Windows systems files; an error will be thrown plus the process may be really slowed down by attempting to open certain systems files.  Secondly, if you decide to abort a search (dir or findstr) at the command line, press Ctrl C twice.

Figure 1. Search criteria through GUI: 

 Figure 2. Results of search

 

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


How to run a DQL query and write results to a file

clock October 24, 2008 05:40 by author Steve Garrison

Another item not explained very well.  Let's see if I can do better than others have done?   Applies to Windows servers.

Objective:  run a query or set of DQL commands contained in a file and have results from query or DQL commands written to a file.  

1. prepare a file containing your DQL commands...could be something like:

select r_object_id from dm_document;

go  

2. save these DQL commands to a text file. In our case I'll call it steveDQL.txt.

3. access server and locate idql32.exe.  This will probably be in a path similar to:  C:\Documentum\product\6.0\bin

4. move text file created in Step 2 above (steveDQL.txt) to the same directory as idql32.exe.

4. open  a DOS command prompt and navigate to that location where idql32.exe is located

5.  run this command:

idql32 dev -Uuser -Ppass -RsteveDQL.txt > c:\dqlresults.txt

Where:

idql32: is command to run idql32.exe

dev: repository name

user:  name of user

pass: password

steveDQL.txt: name of input file that contains DQL commands

>: this symbol tells it to output to a file

c:\dqlresults.txt:: arbitrary filename and path of file to write results of DQL command to 

 The file dqlresults.txt might contain:

EMC Documentum idql - Interactive document query interface

(c) Copyright EMC Corp., 1992 - 2007

All rights reserved.

Client Library Release 6.0.0.114SP1

Connecting to Server using docbase dev

Connected to Documentum Server running Release 6.0.0.116 SP1 Win32.Oracle

1> 2> r_object_id     

----------------

0900084680000992

0900084680000993

0900084680000994

0900084680000995

0900084680000996

0900084680000997 

DOT DOT DOT - CONTINUED

0900084680002872

0900084680002873

(1388582 rows affected)

1>  

 

Currently rated 2.3 by 3 people

  • Currently 2.333333/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


How to Access fast InStream Fulltext Web-Based Native Console

clock October 24, 2008 03:13 by author Steve Garrison

What they don't tell you...  here's a way to find out about fast InStream administration, progress and processing using a web-based interface.  I sort of found this by accident. It wasn't mentioned in any Documentum documentation.  Note: be sure the correct service is started. By default this Administration panel is turned off as a Windows service. Service to start is FAST InStream Web Server.

Use this URL below. I ran from Remote Desktop login but it may not matter if you connect locally or not:

http://localhost:16000/admin/

This assumes a default setup with 16000 as port.  What you will see here is a great deal of information about the server to be used for monitoring and even configuration.  Areas include a Collection overview, System overview, quick log access and loads of other good stuff. Typically a Documentum administrator would not need to access this fast InStream Admin panel but if you have indexing problems (ha, ha) or have done custom configurations to fulltext indexes you may need to monitor/configure through this Admin acces point. 

The image in Fig. 1 gives some idea of what you see  

 

Currently rated 4.5 by 2 people

  • Currently 4.5/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


Welcome to this blog

clock October 21, 2008 06:03 by author Steve Garrison

Although Documentum (an EMC proprietary product) is considered mature, in terms of software, it is forever changing; so having an additional source of technical detail (this blog) may be useful to some developers, administrators. and others.

Having been involved with Documentum, from a technical point-of-view since about 2000 I've watched this product morph, expand, change directions, and adopt additional bolt-on technologies.

Stay tuned for helpful hints, from using Composer, to DFC tricks, administrative solutions,  and for some fill-in's in areas I think are lacking.  One has quite a few sources of information about Documentum, including at least one book but often Documentum's own technical documents miss the point, or one can't find a solution in forums or other sources.

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5


Some Oracle connection problems & fixes

clock October 21, 2008 05:18 by author Steve Garrison

This blog entry applies if you're building a new repository (docbase), with Oracle as the RDBMS and going through Documentum Server Configuration program on the Content Server.  (CS vers 6.0 SP1) This install is for Windows servers but same basic ideas apply to UNIX/Linux. The db user (repository owner) must be able to:

  • Connect to the database
  • Create tables, views, and indexes in the database
  • Insert records (rows) into the tables
  • Drop tables, views, and indexes 

This information is not new; however, it's often a problem connecting to the db.  Here are some items to check:
 
a. make sure you have an Oracle client installed on the server. For install using Content Server version 6.0, SP1, the 10g_win32_client works. 

Install as Administrator type. Not recommended to use Oracle "light" clients; I've had install problems with those.

b. once Oracle client is installed make sure you copy a tnsnames.ora file to the correct location.  Typically this is 

...\Oracle\product\10.1.0\Client_x\NETWORK\ADMIN

c. you may have multiple "Client_x" directories. Make sure you copy tnsnames.ora to the correct Client_x directory.

d. probably a good idea to verify that you can connect from Oracle SQL Plus. This small application will have been installed when you installed Oracle Client.  Access SQL Plus via

Start Menu, Oracle Version x, Application Development.  Run SQL Plus and make a connection, which verifies that from this server the repository owner can connect to Oracle. 

e. through SQL Plus create a table.  Here's a sample statement.  At the SQL prompt enter:  

create table TestTable(column1 varchar2(30));

f. next drop the table. This verifies Oracle user has rights to create and drop a table.   

drop table TestTable; 

Note of caution...sometimes tnsnames.ora becomes corrupt, because of stray characters or illegal entries.  If this is the case you may want to reduce the tnsnames.ora file to only theconnection entry (string) that pertains.  This may help to mitigate failures.  This seems like common sense but usually tnsnames.ora files contain many entries for different connections and usually there is not a problem. If you get odd connection errors removing all but the single connection entry may help.

 

For further info:

1. EMC® Documentum® Content Server Version 6 Installation Guide.  Available at EMC web site, support account required.

2.  see Oracle support forums or similar & you'll read many, many problems people have with tnsnames.ora files:  http://forums.oracle.com

Currently rated 1.0 by 1 people

  • Currently 1/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5