Quickstart
Prerequisites
You will need:
- Java 21+
- Database credentials with read access
- Network access to the database
Verify Java:
java -version
Step 1 — Download and Unzip
Download the trial kit from the Download page.
Then unzip:
unzip scrim-trial-<version>.zip
cd scrim
Step 2 — Set Database Credentials
Scrim reads database credentials from environment variables.
Set them before running:
export DB_URL="jdbc:postgresql://HOST:5432/DB"
export DB_USER="USER"
export DB_PASSWORD="PASSWORD"
Notes:
- Credentials are never logged
- You may alternatively edit the config files directly
Step 3 — Update Configuration for Your Tables
Before running Scrim, update the sample configuration to match your database.
Open the default table-mode config:
nano sample-configs/table.yml
# or use your preferred editor
At minimum, update:
- Table names to match your database
- Schema name (if applicable)
- Row limits or sampling percentages
- Column-level masking rules (if configured)
Example:
tables:
- name: users
- name: orders
- name: payments
Save the file after making changes.
Step 4 — Validate Configuration
Validate your setup:
./bin/scrim validate --config sample-configs/table.yml
Expected output:
✔ Config valid
✔ Database reachable
✔ No write operations detected
Fix any reported errors before proceeding.
Step 5 — Preview Execution
Preview what Scrim will do:
./bin/scrim plan --config sample-configs/table.yml
This shows the tables, limits, and masking rules that will be applied.
Step 6 — Run Scrim
Run the extraction and masking process:
./bin/scrim run --config sample-configs/table.yml
Expected output:
✔ Run completed
✔ No writes made
Outputs written to ./out/
Step 7 — View Outputs
By default, Scrim writes outputs to:
out/
├── csv/ # Masked CSV samples
├── sql/ # Masked SQL inserts
└── audit/ # Execution audit trail
Output Types
- CSV — masked sample data
- SQL — masked insert statements
- Audit — traceability and validation metadata
Query Mode (Optional)
To extract data using custom SQL queries:
./bin/scrim run --config sample-configs/query.yml
This uses:
queries/example.sql
Edit this file to customise extraction logic.
Troubleshooting
Java Not Found
command not found: java
Install Java 21+ and retry.
Credentials Not Set
Database credentials not configured
Ensure all three variables are set:
- DB_URL
- DB_USER
- DB_PASSWORD
Permission Denied
permission denied: ./bin/scrim
Fix with:
chmod +x bin/scrim
Connection Refused
Connection refused
Check:
- Database host and port
- Firewall rules
- Network connectivity
Giving Feedback
Your feedback helps improve Scrim.
-
👍 Feature requests and feedback: https://github.com/hinge-on/scrim-releases/discussions/new
-
🐞 Bug reports: https://github.com/hinge-on/scrim-releases/issues/new
Next Steps
- Review advanced configuration options
- Try query mode
- Run Scrim in your CI or test environment