Jboss AS – Access static files from external folder

Environment
Linux, jboss-4.2.2.GA

1. Open
/opt/jboss/server//deploy/jboss-web.deployer/server.xml

2. Define new context under tag for external folder:

3. Restart Jboss

This means static files under /home/data/reports folder will be available by using following URL syntax:

http://server:port/myreports/filename

Note : When I type http://server:port/myreports in address bar of browser I see 404 error. I am still looking into how to allow directory listing of external folder. If you know, please share.

Add comment December 2, 2009

An error has occurred in this dialog. Error:30 unspecified error

//

Couple of days back I tried to upgrade IE6 to IE8 on my XP machine. It did not work as expected, instead started giving kernel32.dll errors. To revert back I uninstalled IE8 and went back to IE6. But today when I started my computer there were strange problems, some of which are:

1. Oracle 11g won’t come up. When I went to services, clicking any service name will show error dialogs (“An error has occurred in this dialog. Error:30 unspecified error” )

2. I was unable to type anything into textboxes in IE6. They were kind of disabled.

3. IE6>Help>About showed a similar error message

After much research I found the reason of this to be some missing entries from registry on my system.

Here’s the solution that worked for me:

  • Open cmd
  • Type following one by one and press Enter:

regsvr32 mshtmled.dll

regsvr32 jscript.dll

regsvr32 /i mshtml.dll

It works now Good Luck!!

Add comment September 23, 2009

Host Credentials ERROR Invalid username and or password Oracle 11g

On Windows XP do following:

Go to Control Panel > Administrative Tools > Local Security Policy > Local Policies > User Rights Assignment

Search “Log on as batch job”, double click it, click Add User or Group and add the userid you are trying to use under Oracle 11g. Once you do so, you should be able to login under Oracle 11g using this user’s credentials.

Add comment August 5, 2009

Linux “grep and copy”

Suppose I have a folder hierarchy as below:

f1 > f2

f2 > f3

f2 > f4

f4 > f5

I want to find all files in f1 or any of its descendant folder that contain text “I am a match” and copy them into f1’s parent folder (whatever that is).

To accomplish above, run any of following commands from within f1 folder:

i) cp `grep -rl “i am a match” *` ..

ii) grep -rl “i am a match” * | xargs -i cp {} ..

Add comment May 18, 2009

Linux – Get full path of a running process

2 ways that I know to get the full path of a process in linux:

1. /proc/<pid>/exe is a symlink to the actual exe. Here’s what I get for a program eclipse running on my machine under pid 4825 with this command:

localhost:/home/Office # ls -la /proc/4825/exe

lrwxrwxrwx 1 Office users 0 May 15 11:30 /proc/4825/exe -> /opt/eclipse/eclipse

2. with ps command we can get the full path:

localhost:/home/Office # ps -u -p 4825

Warning: bad ps syntax, perhaps a bogus ‘-’? See http://procps.sf.net/faq.html

USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND

Office 4825 0.0 0.1 81452 2872 ? S 11:07 0:00 /opt/eclipse/eclipse

localhost:/home/Office # ps agx | grep 4825

4825 ? S 0:00 /opt/eclipse/eclipse

Add comment May 15, 2009

Previous Posts


RSS Quote of the day


View Varun Chopra's profile on LinkedIn

Categories

Recent Comments

suresh kumar on Polls
Vijay Sood on Polls
CasTex on install CUPS-PDF on SuSE …
Pryaranjan Heer on Polls
Varun on install CUPS-PDF on SuSE …

Feeds

Blog Stats