I have to find out the file system location of the script file inside script. for example a script "abc.sh" placed anywhere in the file system when executed shold tell by itself the location of it.
example
#pwd
/
#./abc
this is / #cd /root
#./abc
this is /root #cd /
#/root/abc
this is /root
What you actually need is the contents of /proc/pid/exe. But in your case since you need the actual path of script that is run, /proc/pid/exe it wouldnt help because, the shell i.e. /bin/sh or /bin/ksh or /bin/bash et al., picks up your script and runs it. So a /proc/pid/exe inside a script would give you /bin/sh or /bin/ksh likewise.
What you can do is analyze $0 and see if it is a path starting from / and gets its basename. Else use it along with pwd of the current directory.