All of lore.kernel.org
 help / color / mirror / Atom feed
* sstate cache SSTATE_PKG generation will silently fail, if hardlinking is not supported on the file system #bitbake
@ 2022-09-15 23:05 Arnis
  2022-09-16  9:26 ` [OE-core] " Richard Purdie
  0 siblings, 1 reply; 2+ messages in thread
From: Arnis @ 2022-09-15 23:05 UTC (permalink / raw)
  To: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 805 bytes --]

Hi,

I have faced a problem today that sstate-cache `${SSTATE_PKG}` generation will silently fail on the file systems no supporting hard linking.
I've faced this problem on cloud-based Kubernetes cluster, where persistent volume is mounted to Docker containers as shared sstate-cache location.

Because of https://git.openembedded.org/ openembedded-core/commit/?id= 552197a0c4c9f75a9177c00b197ea9 1296ed9fc4 ( https://git.openembedded.org/openembedded-core/commit/?id=552197a0c4c9f75a9177c00b197ea91296ed9fc4 ) change

+ ln $TFILE ${SSTATE_PKG} || true

this will leave sstate folder with only `*...tar.zst.siginfo` files generated, but no "*...tar.zst"

As a temporary solution, I have replaced it with

+ cp $TFILE ${SSTATE_PKG}

which obviously is not ideal.

What would you suggest?

[-- Attachment #2: Type: text/html, Size: 2188 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [OE-core] sstate cache SSTATE_PKG generation will silently fail, if hardlinking is not supported on the file system #bitbake
  2022-09-15 23:05 sstate cache SSTATE_PKG generation will silently fail, if hardlinking is not supported on the file system #bitbake Arnis
@ 2022-09-16  9:26 ` Richard Purdie
  0 siblings, 0 replies; 2+ messages in thread
From: Richard Purdie @ 2022-09-16  9:26 UTC (permalink / raw)
  To: Arnis, openembedded-core

On Thu, 2022-09-15 at 16:05 -0700, Arnis wrote:
> Hi, 
>  
> I have faced a problem today that sstate-cache `${SSTATE_PKG}`
> generation will silently fail on the file systems no supporting hard
> linking. 
> I've faced this problem on cloud-based Kubernetes cluster, where
> persistent volume is mounted to Docker containers as shared sstate-
> cache location.
>  
> Because of
> https://git.openembedded.org/openembedded-core/commit/?id=552197a0c4c9f75a9177c00b197ea91296ed9fc4
>  change 
>  
> + ln $TFILE ${SSTATE_PKG} || true
>  
> this will leave sstate folder with only `*...tar.zst.siginfo` files
> generated, but no "*...tar.zst" 
>  
> As a temporary solution, I have replaced it with
>  
> + cp $TFILE ${SSTATE_PKG}
>  
> which obviously is not ideal.
>  
> What would you suggest?

Unfortunately that code is rather critical as it is attempting to move
files into position atomically and not use lockfiles or hold locks.

Failing silently is bad, we should probably add a check the file exists
afterwards and error if it doens't.

That wouldn't solve your issue with that filesystem would make people
aware of it.

Cheers,

Richard



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-09-16  9:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-15 23:05 sstate cache SSTATE_PKG generation will silently fail, if hardlinking is not supported on the file system #bitbake Arnis
2022-09-16  9:26 ` [OE-core] " Richard Purdie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.