[#4435] romfs mucks up symlinks with similar name
Submitted By: Mike Frysinger
Open Date
2008-09-22 16:59:09
Priority:
Medium Assignee:
Nobody
Status:
Open Fixed In Release:
N/A
Found In Release:
N/A Release:
2.6.26.5 trunk 5323
Category:
N/A Board:
N/A
Processor:
N/A Silicon Revision:
Is this bug repeatable?:
Yes Resolution:
N/A
Uboot version or rev.:
Toolchain version or rev.:
App binary format:
N/A
Summary: romfs mucks up symlinks with similar name
Details:
if i boot a kernel with MTD_UCLINUX and a ROMFS root filesystem, symlinks that are shorter than a real file get translated into the real file instead of the symlink
for example, we have /bin/ls as a symlink to /bin/busybox. we also have zmodem utils installed as /bin/lsz:
$ ls -l romfs/bin/ls romfs/bin/lsz
lrwxrwxrwx 1 vapier users 7 2008-09-22 16:21 romfs/bin/ls -> busybox
-rwxr-xr-x 1 vapier users 66944 2008-09-22 16:21 romfs/bin/lsz
if we check the images/rootfs.romfs file by mounting it as loopback on the development host, things look fine:
$ mkdir loop
$ sudo mount -o loop images/rootfs.romfs loop/
$ ls -l loop/bin/ls loop/bin/lsz
lrwxrwxrwx 1 root root 7 1969-12-31 19:00 loop/bin/ls -> busybox
-rwxr-xr-x 1 root root 66944 1969-12-31 19:00 loop/bin/lsz
but when we boot the system, things are screwed up:
root:/> busybox ls -l /bin/ls /bin/lsz
-rwxr-xr-x 1 root root 66944 Jan 1 1970 /bin/ls
-rwxr-xr-x 1 root root 66944 Jan 1 1970 /bin/lsz
same behavior can be observed with other files ... by copying lsz to "lnz", the "ln" symlink becomes the same file as "lnz".
Follow-ups
No Messages Were Found
Files
Changes
Commits
Dependencies
Duplicates
Associations
Tags
File Name File Type File Size Posted By
No Files Were Found