realrolfje/anonimatron

Installation does not work or is wrongly described

Closed this issue · 2 comments

Anonimatron version: 1.11
Operating system and version: Debian GNU/Linux 10.1
Java runtime (java -version):

openjdk 11.0.4 2019-07-16
OpenJDK Runtime Environment (build 11.0.4+11-post-Debian-1deb10u1)
OpenJDK 64-Bit Server VM (build 11.0.4+11-post-Debian-1deb10u1, mixed mode, sharing)

Executed commands or actions:

  1. cd /home/www/dev/bin/anonimatron
  2. andrius@buster:/home/www/dev/bin/anonimatron$ ./resources/scripts/anonimatron.sh
  3. cd ./resources
  4. andrius@buster:/home/www/dev/bin/anonimatron/resources$ ./scripts/anonimatron.sh
  5. cd ./scripts
  6. andrius@buster:/home/www/dev/bin/anonimatron/resources/scripts$ ./anonimatron.sh

Expected outcome or behavior:

To anonymize your data, download Anonimatron and unzip it in a directory of your choice. You should find an “anonimatron.sh” and “anonimatron.bat” file there. Depending on your system, run it without arguments. If you have java installed on your system you should see something like this:

$ ./anonimatron.sh
 
This is Anonimatron 1.10, a command line tool to consistently
replace live data in your database with data data which
can not be traced back to the original data.
You can use this tool to transform a dump from a production
database into a large representative dataset you can
share with your development and test team.
Use the -configexample command line option to get an idea of
what your configuration file needs to look like.
 
usage: java -jar anonimatron.jar
 -config      The XML Configuration file describing what to
                   anonymize.
 -configexample    Prints out a demo/template configuration file.
 -dryrun           Do not make changes to the database.
 -jdbcurl          The JDBC URL to connect to. If provided, overrides the
                   value in the config file.
 -userid           The user id for the database connection. If provided,
                   overrides the value in the config file.
 -password         The password for the database connection. If provided,
                   overrides the value in the config file.
 -synonyms <arg>   The XML file to read/write synonyms to. If the file
                   does not exist it will be created.

Victory! You’ve installed Anonimatron. Yes, life can really be that easy.

Actual outcome or behavior:

Error: Could not find or load main class com.rolfje.anonimatron.Anonimatron
Caused by: java.lang.ClassNotFoundException: com.rolfje.anonimatron.Anonimatron
/home/www/dev/bin/anonimatron
Error: Could not find or load main class com.rolfje.anonimatron.Anonimatron
Caused by: java.lang.ClassNotFoundException: com.rolfje.anonimatron.Anonimatron
/home/www/dev/bin/anonimatron/resources
Error: Could not find or load main class com.rolfje.anonimatron.Anonimatron
Caused by: java.lang.ClassNotFoundException: com.rolfje.anonimatron.Anonimatron
/home/www/dev/bin/anonimatron/resources/scripts

Additional information:

Tree:

andrius@buster:/home/www/dev/bin$ tree anonimatron/
anonimatron/
├── create_release.sh
├── docs
│   ├── CODE_OF_CONDUCT.md
│   ├── CONTRIBUTING.md
│   ├── issue_template.md
│   └── PULL_REQUEST_TEMPLATE.md
├── LICENSE.md
├── pom.xml
├── README.images
│   ├── 1-dataindb.png
│   ├── 2-anonimatron.png
│   └── 3-datainsynonims.png
├── README.md
├── resources
│   ├── anonymizers
│   │   └── README.md
│   ├── documentation
│   │   ├── README.md
│   │   └── VERSION_INFO.TXT
│   ├── images
│   │   ├── anonimatron-logo-a.png
│   │   ├── anonimatron-logo-a.pxm
│   │   ├── anonimatron-logo-a.xcf
│   │   ├── anonimatron-logo-full.png
│   │   ├── download-now.png
│   │   ├── github-social-preview.png
│   │   └── github-social-preview.pxm
│   ├── integration
│   │   └── mssql
│   │       ├── config.xml
│   │       └── README.md
│   ├── libraries
│   │   ├── classes12-0.0.jar
│   │   ├── jtds-1.3.1.jar
│   │   ├── mssql-jdbc-7.2.2.jre8.jar
│   │   ├── mysql-connector-java-5.1.13-bin.jar
│   │   └── postgresql-9.0-801.jdbc4.jar
│   └── scripts
│       ├── anonimatron.bat
│       └── anonimatron.sh
└── src
    ├── javadoc
    │   └── stylesheet.css
    ├── main
    │   ├── assembly
    │   │   └── anonimatronbin.xml
    │   └── java
    │       ├── castor.properties
    │       ├── com
    │       │   └── rolfje
    │       │       └── anonimatron
    │       │           ├── Anonimatron.java
    │       │           ├── anonymizer
    │       │           │   ├── AbstractElevenProofAnonymizer.java
    │       │           │   ├── AbstractNameGenerator.java
    │       │           │   ├── Anonymizer.java
    │       │           │   ├── AnonymizerService.java
    │       │           │   ├── BankAccountAnonymizer.java
    │       │           │   ├── CharacterStringAnonymizer.java
    │       │           │   ├── CharacterStringPrefetchAnonymizer.java
    │       │           │   ├── CountryCodeAnonymizer.java
    │       │           │   ├── DateAnonymizer.java
    │       │           │   ├── DigitStringAnonymizer.java
    │       │           │   ├── DutchBankAccountAnononymizer.java
    │       │           │   ├── DutchBSNAnononymizer.java
    │       │           │   ├── DutchZipCodeAnonymizer.java
    │       │           │   ├── ElvenNameGenerator.java
    │       │           │   ├── elven-names.syl
    │       │           │   ├── EmailAddressAnonymizer.java
    │       │           │   ├── Hasher.java
    │       │           │   ├── IbanAnonymizer.java
    │       │           │   ├── Prefetcher.java
    │       │           │   ├── RomanNameGenerator.java
    │       │           │   ├── roman-names.syl
    │       │           │   ├── StringAnonymizer.java
    │       │           │   ├── SynonymCache.java
    │       │           │   └── UUIDAnonymizer.java
    │       │           ├── commandline
    │       │           │   └── CommandLine.java
    │       │           ├── configuration
    │       │           │   ├── castor-config-mapping.xml
    │       │           │   ├── Column.java
    │       │           │   ├── ColumnShortLivedFieldHandler.java
    │       │           │   ├── Configuration.java
    │       │           │   ├── DataFile.java
    │       │           │   ├── Discriminator.java
    │       │           │   └── Table.java
    │       │           ├── file
    │       │           │   ├── CsvFileReader.java
    │       │           │   ├── CsvFileWriter.java
    │       │           │   ├── FileAnonymizerService.java
    │       │           │   ├── Record.java
    │       │           │   ├── RecordReader.java
    │       │           │   └── RecordWriter.java
    │       │           ├── jdbc
    │       │           │   ├── ColumnWorker.java
    │       │           │   └── JdbcAnonymizerService.java
    │       │           ├── progress
    │       │           │   ├── Progress.java
    │       │           │   └── ProgressPrinter.java
    │       │           ├── synonyms
    │       │           │   ├── Base64StringFieldHandler.java
    │       │           │   ├── castor-synonym-mapping.xml
    │       │           │   ├── DateSynonym.java
    │       │           │   ├── HashedFromSynonym.java
    │       │           │   ├── NullSynonym.java
    │       │           │   ├── NumberSynonym.java
    │       │           │   ├── StringDateFieldHandler.java
    │       │           │   ├── StringSynonym.java
    │       │           │   ├── Synonym.java
    │       │           │   └── SynonymMapper.java
    │       │           └── version.txt
    │       └── log4j.xml
    └── test
        └── java
            └── com
                └── rolfje
                    └── anonimatron
                        ├── AnonimatronTest.java
                        ├── anonymizer
                        │   ├── AnonymizerServiceTest.java
                        │   ├── CharacterStringPrefetchAnonymizerTest.java
                        │   ├── CountryCodeAnonymizerTest.java
                        │   ├── DutchBSNAnononymizerTest.java
                        │   ├── DutchZipCodeAnonymizerTest.java
                        │   ├── FixedValueAnonymizer.java
                        │   ├── HasherTest.java
                        │   ├── IbanAnonymizerTest.java
                        │   ├── RomanNameGeneratorTest.java
                        │   ├── SynonymCacheTest.java
                        │   └── ToLowerAnonymizer.java
                        ├── configuration
                        │   ├── ColumnShortLivedFieldHandlerTest.java
                        │   └── ConfigurationTest.java
                        ├── file
                        │   ├── AcceptAllFilter.java
                        │   ├── CsvFileReaderTest.java
                        │   ├── CsvFileWriterTest.java
                        │   ├── FileAnonymizerServiceTest.java
                        │   └── RecordTest.java
                        ├── integrationtests
                        │   ├── integrationconfig.xml
                        │   └── IntegrationTest.java
                        ├── jdbc
                        │   ├── AbstractInMemoryHsqlDbTest.java
                        │   └── JdbcAnonymizerServiceTest.java
                        ├── LoremIpsum.java
                        ├── LoremIpsumTest.java
                        ├── progress
                        │   ├── ProgressPrinterTest.java
                        │   └── ProgressTest.java
                        └── synonyms
                            ├── Base64StringFieldHandlerTest.java
                            ├── SynonymMapperTest.java
                            └── SynonymTest.java

37 directories, 118 files

In this case, you are trying to run anonimatron from the uncompiled sources. I think this is caused by the link in the readme.md underneath the "Installing Anonimatron" which points to downloading the master sources instead of the binary release.

To solve your problem right now, please download the latest binary release from https://github.com/realrolfje/anonimatron/releases or use the download link at the top of the documentation page at https://realrolfje.github.io/anonimatron/

I'll update the link in the readme.md to point to the binary instead of the sources.

Fixed the download link.