find out subdomains

I am the new user
I want to find out sub domains in the URL using shell script.
e.g
http://abcd:8380/matcher

This is the URL. The suburl is given below

http://abcd:8380/matcher/servlet/viewnudatasource
http://abcd:8380/matcher/servlet/addnudatasource
http://abcd:8380/matcher/servlet/savenudatasource
http://abcd:8380/matcher/servlet/cancelnudatasource
http://abcd:8380/matcher/servlet/editnudatasource
http://abcd:8380/matcher/servlet/removenudatasource
http://abcd:8380/matcher/servlet/viewnumatcher
http://abcd:8380/matcher/servlet/addnumatcher
http://abcd:8380/matcher/servlet/savenumatcher

Please any one suggest how i will get this suburl through script?
It's urgent

  1. welcome to unix.com

  2. it's allways urgent

  3. you can't find this with shellscript unless you've access to the server and you know the directory structure...

yes i access the server and i know the directory structure

so where is your problem? the subdomains should be somewhere on your server. you'll only have to list them?!

our application is run on jboss in deploy we have matcher.war , actually there are some jsp, servlet and struts page and also some png, .js others. So we are not able to find subdomain URL in your way because lots of are invalid so is there any way.

From web we had perl -MFile::Find -e 'find(sub{@ARGV=($_);while(<>) {print "$File::Find::Dir : ",/((?:http\/\/\.)?www\..*)\s+/}},"/")'

but we are not able to use this one .