Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Oct 2018 15:13:36 +0200
From:      "Ronald Klop" <ronald@klop.ws>
To:        freebsd-arm@freebsd.org, "FreeBSD Current" <freebsd-current@freebsd.org>,  freebsd-fs@freebsd.org
Subject:   tmpfs corrupt file (aarch64/12.0-ALPHA5)
Message-ID:  <op.zrfy0yxceclrs1@sjakie>

next in thread | raw e-mail | index | archive | help
Hello,

I'm running this small script which generates changelog file in gzipped  
JSON format.

TMPDIR=/var/tmp
START=1
END=$(( $START + $STEP - 1 ))
while test $START -lt 300000
do
         svnlite log --xml -r $START:$END -v ~/src/freebsd-base >  
$TMPDIR/bla.xml
         bin/xml2json.py > $TMPDIR/commits.$START-$END.json
         gzip -f $TMPDIR/commits.$START-$END.json
         START=$(( $START + $STEP ))
         END=$(( $START + $STEP - 1 ))
done

So $TMPDIR/bla.xml is overwritten every iteration.
Well:
- If $TMPDIR=/var/tmp which is on UFS the script works.
- If %TMPDIR=/tmp which is tmpfs the xml2json.py script very often gives  
errors about the XML structure of bla.xml like if the file is truncated or  
empty.

So it looks like something is happening on tmpfs that the data is not yet  
'synced'. Can this be a threading/cpu-cache issue on aarch64?

This is on an RPI3B+.
FreeBSD rpi3 12.0-ALPHA5 FreeBSD 12.0-ALPHA5 #5 r338616: Wed Sep 12  
22:23:05 CEST 2018      
builder@rpi3:/data/src/obj-head/data/src/head/arm64.aarch64/sys/GENERIC-NODEBUG   
arm64

Can I do more testing or provide more information before creating a PR  
about this?

Regards,
Ronald.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?op.zrfy0yxceclrs1>