I compiled the MPI program using -g -O2 options, but only disassembly view is available.
Warning MSG:-" Line number information is not available for the range."
what could be missing in the executable?
Is the name of the executable you created with -g (both compile and link) visible in the list of modules for which data was collected? If so, you should be able to open it up and get a window directing you to browse for the source (if it is not in the directory you specified to run in). You will be restricted to assembly view for the MPI, although running against one of the Intel Trace Analyzer/Collector versions of the MPI library could help with that.
I didn't say that. The mpi scripts and executables (except possibly for those which come with itac) don't have debug information. Your own application could have debug symbols if you build it that way, in which case you can click on it after running under MPI and access source, same as a non-MPI application.