Subject: ls works but dir doesn't

From: Douglas Stewart <[email-masked]>
Date: Mon, 3 Jun 1996 13:48:51 -0500 (CDT)

On Solaris 2.5...

axe:~ftp# ls -lR
.:
total 10
dr-xr-xr-x   2 root     other        512 Jun  3 12:56 bin
drwxr-xr-x   2 root     other        512 Jun  3 13:05 dev
dr-xr-xr-x   2 root     other        512 Jun  3 12:56 etc
drwxr-xr-x   2 root     other        512 Jun  3 13:02 lib
drwxrwxrwx   2 ftp      other        512 Jun  3 12:57 pub

./bin:
total 36
---x--x--x   1 root     other      17500 Jun  3 12:56 ls

./dev:
total 0
crw-rw-rw-   1 root     other     11, 42 Jun  3 13:03 tcp
crw-rw-rw-   1 root     other     13, 12 Jun  3 13:05 zero

./etc:
total 4
-r--r--r--   1 root     other        742 Jun  3 12:56 group
-r--r--r--   1 root     other        864 Jun  3 12:56 passwd

./lib:
total 1442
-rwxr-xr-x   1 root     other     664048 Jun  3 13:02 libc.so.1
-rwxr-xr-x   1 root     other       2568 Jun  3 13:02 libdl.so.1
-rwxr-xr-x   1 root     other      15304 Jun  3 13:01 libintl.so.1
-rwxr-xr-x   1 root     other      39340 Jun  3 13:01 libw.so.1

./pub:
total 0

Okay now when I connect:

axe:~ftp# ftp localhost
Connected to localhost.
220 axe FTP server (Version wu-2.4.2-academ[BETA-11](1) Mon Jun 3 11:56:52
CDT 1996) ready.
Name (localhost:douglas): ftp
331 Guest login ok, send your complete e-mail address as password.
Password:
230 Guest login ok, access restrictions apply.
ftp> ls
200 PORT command successful.
150 Opening ASCII mode data connection for file list.
bin
etc
pub
dev
lib
.message
226 Transfer complete.
35 bytes received in 0.067 seconds (0.51 Kbytes/s)
ftp> dir
200 PORT command successful.
150 Opening ASCII mode data connection for /bin/ls.
226 Transfer complete.
ftp>

Any ideas?

Douglas L. Stewart                               System Administrator
- * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * - * -
       [email-masked]          |   Pager:
  http://www2.netdoor.com/~douglas  |      [email-masked]

---

From: [email-masked] (Paul Fincher (CACI))
Date: Mon, 3 Jun 1996 15:05:16 -0400

--> 
--> Okay now when I connect:
--> 
--> axe:~ftp# ftp localhost
--> Connected to localhost.
--> 220 axe FTP server (Version wu-2.4.2-academ[BETA-11](1) Mon Jun 3 11:56:52
--> CDT 1996) ready.
--> Name (localhost:douglas): ftp
--> 331 Guest login ok, send your complete e-mail address as password.
--> Password:
--> 230 Guest login ok, access restrictions apply.
--> ftp> ls
--> 200 PORT command successful.
--> 150 Opening ASCII mode data connection for file list.
--> bin
--> etc
--> pub
--> dev
--> lib
--> .message
--> 226 Transfer complete.
--> 35 bytes received in 0.067 seconds (0.51 Kbytes/s)
--> ftp> dir
--> 200 PORT command successful.
--> 150 Opening ASCII mode data connection for /bin/ls.
--> 226 Transfer complete.
--> ftp>
--> 
--> Any ideas?

Douglas,

   I had this same problem util I linked ls statically. I pulled ftpd-ls off the net and built 
it using gcc -static. Now my dir works fine!
   
Paul Fincher
J-MASS Operational Support
[email-masked]