Looks like LTR is uninitialized or has been overwritten by earlier corruption. This does not have anything to do with PETSc.<br><br><div class="gmail_quote">On Sat, Jun 2, 2012 at 9:11 AM, w_ang_temp <span dir="ltr"><<a href="mailto:w_ang_temp@163.com" target="_blank">w_ang_temp@163.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="line-height:1.7;font-size:14px;font-family:arial"><div style="line-height:1.7;font-size:14px;font-family:arial">

<div>Hello, Jed</div>
<div>     I use gdb to debug it. </div>
<div>     (1)The source code(The line number is add by me.Line 125 and 127 are added right now for debugging ):</div>
<div>      ............</div>
<div>121       open(50,FILE='check.out')<br>122       open(LSS,FILE='select.dat')<br>123 C      open(LH,FILE='select1.dat',FORM='UNFORMATTED')<br>124       open(LR,FILE='initials.dat')<br>
125       write(*,*) 'test1'<br>126       open(LTR,FILE='trapdoor.dat')<br> 127      write(*,*) 'test2'</div>
<div>   (2) Debug information: </div>
<div>(gdb) break 124 <br>Breakpoint 1 at 0x804bb42: file ex4f.F, line 124.<br>(gdb) run<br>Starting program: /home/geo/project/temp/8-little-9-2716/tutorials/ex4f <br>[Thread debugging using libthread_db enabled]</div>
<div>Breakpoint 1, gleaves () at ex4f.F:124<br>124       open(LR,FILE='initials.dat')<br>(gdb) n<br>125       write(*,*) 'test1'<br>(gdb) n<br> test1<br>126       open(LTR,FILE='trapdoor.dat')<br>
(gdb) n<br>forrtl: severe (32): invalid logical unit number, unit -1208035944, file unknown<br>Image              PC        Routine            Line        Source             <br>libirc.so          00AC3470  Unknown               Unknown  Unknown<br>
libirc.so          00AC2011  Unknown               Unknown  Unknown<br>libifcore.so.5     00BD066B  Unknown               Unknown  Unknown<br>libifcore.so.5     00B5A178  Unknown               Unknown  Unknown<br>libifcore.so.5     00B70CF4  Unknown               Unknown  Unknown<br>
ex4f               0804BC6B  Unknown               Unknown  Unknown<br>ex4f               0804B904  Unknown               Unknown  Unknown<br>libc.so.6          00C48BD6  Unknown               Unknown  Unknown<br>ex4f               0804B811  Unknown               Unknown  Unknown</div>

<div>Program exited with code 040.<br>(gdb) </div>
<div>  (3)From the information above, it stops in 126 and can not go to line 127.</div>
<div> </div>
<div>                    Thanks.</div>
<div>                                                  Jim</div>
<div></div>
<div></div>
<div><br></div>>在 2012-06-02 21:11:05,"Jed Brown" <<a href="mailto:jedbrown@mcs.anl.gov" target="_blank">jedbrown@mcs.anl.gov</a>> 写道:<div class="im"><br>
<blockquote style="BORDER-LEFT:#ccc 1px solid;MARGIN:0px 0px 0px 0.8ex;PADDING-LEFT:1ex">
<div class="gmail_quote">>On Sat, Jun 2, 2012 at 7:02 AM, w_ang_temp <span dir="ltr"><<a href="mailto:w_ang_temp@163.com" target="_blank">w_ang_temp@163.com</a>></span> wrote:<br>
<blockquote style="BORDER-LEFT:#ccc 1px solid;MARGIN:0px 0px 0px 0.8ex;PADDING-LEFT:1ex" class="gmail_quote">
<div style="LINE-HEIGHT:1.7;FONT-FAMILY:arial;FONT-SIZE:14px">
<div>>Hello,<br>>    I reconfigure the mpi and petsc today. I want to use ifort as the compiler. <br>>And there is a problem.</div>
<div>>    Before I reconfigure them, both compiling and running are ok (1.make ex4f;<br>>2.mpiexec -n 2 ./ex4f;The name 'ex4f' is my project name, not the petsc <br>>example name).And I have done lots of work before.Since I think the project<br>
>is inefficient, I want to use ifort.<br>>   After the reconfiguration, the compiling seems ok(make ex4f) and I can get <br>>the executable file. But when I run it(mpiexec -n 2 ./ex4f), it does not work<br>>('forrtl: severe (32): invalid logical unit number, unit -1215421032, file unknown'). <br>
</div></div></blockquote>
<div><br></div>
<div>>Show us the full stack trace (the full PETSc error message is good, a gdb stack trace would be better). It's quite possible that that you have >some code that is not standards compliant, thus it behaves differently with different compilers.</div>

<div> </div>
<blockquote style="BORDER-LEFT:#ccc 1px solid;MARGIN:0px 0px 0px 0.8ex;PADDING-LEFT:1ex" class="gmail_quote">
<div style="LINE-HEIGHT:1.7;FONT-FAMILY:arial;FONT-SIZE:14px">
<div>>Besides, both compiling and running are ok when I test the petsc examples.</div>
<div>>   Before I reconfigure them, the configurations are as follows:<br>>     mpi:   ./configure --prefix=/home/geo/soft/mpich2<br>>     PETSc: ./configure --download-f-blas-lapack=1 <br>>   And now the configurations are the following:<br>
 </div></div></blockquote></div></blockquote></div></div></div><br><br><span title="neteasefooter"><span></span></span></blockquote></div><br>