Subject: pwd returning duplicate directory in path
To: None <tech-kern@netbsd.org>
From: Manuel Bouyer <bouyer@antioche.lip6.fr>
List: tech-kern
Date: 02/13/2004 13:40:54
Hi,
has anyone else seen this, or has an idea about this bug ?
disco:/#pwd
/
disco:/#cd /root/
disco:/root#pwd
/root
disco:/root#cd .ssh/
disco:/root/.ssh#pwd
/root/.ssh.ssh
disco:/root/.ssh#cd /root/.ssh.ssh
/root/.ssh.ssh: No such file or directory.

More strange:
disco:/root#mv .ssh .ssh.bug
disco:/root#cd .ssh.bug/
disco:/root/.ssh.bug#pwd
/root/.ssh.bug.ssh.bug
disco:/root/.ssh.bug#cd ..
disco:/root#cp -rp .ssh.bug .ssh
disco:/root#cd .ssh
disco:/root/.ssh#pwd
/root/.ssh.ssh

disco:/#mv root root.bug
disco:/#cd root.bug/
disco:/root#pwd
/root.bug
disco:/root#cd .ssh
disco:/root/.ssh#pwd
/root.bug/.ssh.ssh
disco:/root/.ssh#cd /
disco:/#cp -rp root.bug root
disco:/#cd root
disco:/root#pwd
/root
disco:/root#cd .ssh
disco:/root/.ssh#pwd
/root/.ssh.ssh

This is:
disco:/#uname -a
NetBSD disco 1.6.1_STABLE NetBSD 1.6.1_STABLE (DISCO) #3: Sun Aug 24 16:17:28 MEST 2003     bouyer@disco:/home/src/sys/arch/alpha/compile/DISCO alpha

This is the only directory that seems affected. Other users's .ssh directory
behaves the expected way, as well as other 2-level paths.
This worked properly up to yesterday evening (I noticed because ssh's
/root/.ssh/authorized_keys is now rejected by the server, which also means
the problem isn't in /bin/pwd but somewhere else) and as far as
I know nothing changed on this server.

-- 
Manuel Bouyer <bouyer@antioche.eu.org>
     NetBSD: 26 ans d'experience feront toujours la difference
--