Posts Tagged ‘tmp’

ITM TDW Schema

June 3rd, 2009

Not that there is a lot to the TDW layout, but knowing the schema assists in the documentation process and developing queries and procedures of the TDW (Tivoli Data Warehouse).

Make short work of this by using the opensource tools of SchemaSpy and Graphviz

SchemaSpy is a jar file that supports over 21 DBs, including the 3 supported by ITM TDW (Oracle, Sybase, MSSQL) and is run from the command line to generate a html directory of content about the interrogated schema.

jdsmedia@deant61p /usr/local/bin
$ java -jar ./schemaspy.jar -t ora -db testtdw -s ITMUSR -dp c:\\OraClient11g\\jdbc\\lib\\ojdbc5_g.jar -u XXX -p XXX -o c:/cygwin/tmp/tdw

Using database properties:
[./schemaspy.jar]/net/sourceforge/schemaspy/dbTypes/ora.properties

Connected to Oracle – Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 – 64bit Production

With the Partitioning, OLAP and Data Mining options

Gathering schema details………………………………………………..
……………………………….

  • Share/Bookmark

Tags: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Posted in ITM, TDW2.x | Comments (0)

Hosting : Why does every visit to my website have the same IP address?

September 4th, 2008

Reference: http://help.mosso.com/article.php?id=180

Your script is calling for the “REMOTE_ADDR” and receives the IP of a server in front of one of our back-end servers. The web facing server is then passing the scripts output without giving the expected REMOTE_ADDR of the visitor. In order for your scripts to recognize that they are on a cluster and log the correct IP of your visitors, you will need to replace and add the code below.

For PHP:
Locate any lines of code that are similar to this snippet of code,
$_SERVER['REMOTE_ADDR'];
And replace it with this snippet of code,
$_SERVER['HTTP_X_CLUSTER_CLIENT_IP'];

For ASP:
Locate any lines of code that are similar to this snipper of code,
Request.ServerVariables(“REMOTE_ADDR”)
And replace it with this snipper of code,
Request.ServerVariables(“HTTP_X_CLUSTER_CLIENT_IP”)

My fix for this required a unix shell (if you’re on a Windows look at installing cygwin on your system.

# Ftp your web content down to your local system

$ for file in `find <path_to_files> -exec grep -l REMOTE_ADDR {} \;`; do base=`basename $file`; sed ‘s/REMOTE_ADDR/HTTP_X_CLUSTER_CLIENT_IP/g’ $file > /tmp/$base; grep HTTP_X_CLUSTER_CLIENT_IP /tmp/$base >/dev/null 2>&1 && grep REMOTE_ADDR $file && echo “Updated $base” && mv
/tmp/$base $file; done

# Then simply upload the changed files to your system.

  • Share/Bookmark

Tags: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Posted in web_programming | Comments (0)

  • LinkedIn

    If you want to see my LinkedIn profile, click on this button:

    Jim Sander
  • Save MySQL

JDS Media is Digg proof thanks to caching by WP Super Cache