You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the tar file of ubuntu:18.04 base layer(sha256:6958ba61ef42a87f438b918c94a12af7a64a415a23dbed8e364eb6af9bb0845a), there is a hardlink:
hrwxr-xr-x 0/0 0 bin/uncompress ==> bin/gunzip
We can get the original file on CRFS:
$ cat /crfs/layers/gcr.io/reasonablek8s/ubuntu/18.04/0/bin/gunzip
#!/bin/sh
# Uncompress files. This is the inverse of gzip.
# Copyright (C) 2007 Free Software Foundation
...
But the link counts aren't correct.
$ stat --print="%h\n" /crfs/layers/gcr.io/reasonablek8s/ubuntu/18.04/0/bin/gunzip
1
$ stat --print="%h\n" /crfs/layers/gcr.io/reasonablek8s/ubuntu/18.04/0/bin/uncompress
1
Issue description
Currently we can't deal with hard-link.
Issue Reproduction
In the tar file of ubuntu:18.04 base layer(sha256:6958ba61ef42a87f438b918c94a12af7a64a415a23dbed8e364eb6af9bb0845a), there is a hardlink:
We can get the original file on CRFS:
But the link counts aren't correct.
And we get an empty file from the hardlink.
Additionally, when we
cat
it, we get EIO.The cause of issue
There are two causes:
TOCEntriy
s, link counts aren't recorded and the filesystem returns a static number1
as link counts.stargz.Reader.Lookup()
and(*stargz.TOCEntry).LookupChild()
), the hardlink isn't resolved.The text was updated successfully, but these errors were encountered: