umich-arc / gufi-archive Goto Github PK
View Code? Open in Web Editor NEWPublic Repo of documentation and scripts how to use GUFI to generate reports to identify data suitable for archive
Public Repo of documentation and scripts how to use GUFI to generate reports to identify data suitable for archive
gufi-archive/reports/dirsum.sh
Lines 34 to 48 in 56eb0f9
This can be changed to only use gufi_query
gufi_query \
-n ${THREADS} \
-I "CREATE TABLE sument (username text, name text, size int64, atime int64, oldsize int64);" \
-E "INSERT INTO sument SELECT uid, name, size, atime, \
CASE WHEN datetime(atime, 'unixepoch') < DATE('now', '-"$DAYS" day') THEN size ELSE 0 END \
FROM entries WHERE type='f';" \
-K "CREATE TABLE vsument(count int64, sizeGB int64, oldsize int64);" \
-J "INSERT INTO vsument SELECT COUNT(*), sum(size)/1024/1024/1024, sum(oldsize)/1024/1024/1024 FROM sument;" \
-G "SELECT count, sizeGB, oldsize, PRINTF('%02d%%', (100*oldsize/sizeGB)) FROM vsument;" \
"$1/${dir}"
No intermediate database files will be created. sument
and vsument
will be in memory. This also avoids the limit mentioned in the SQLite documentation that querydbs
suffers from.
list size and oldsize for each directory under a given starting point
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.