gonymizer: gonymizer "process" ends with panic: runtime error: index out of range
Hi,
I am trying to use the docker image from smithoss/gonymizer and I am having partial success. Is the number of rows possibly capped at 3.000.000?
Here is my docker command:
docker build --no-cache --rm gonymizer
The Dockerfile:
#FROM junkert/gonymizer
FROM smithoss/gonymizer
ENV PG_SRC_HOST=
ENV PG_SRC_USER=
ENV PG_SRC_PSWD=
ENV PG_SRC_PORT=
ENV PG_SRC_DBNAME=grossolini_as
ENV PG_SRC_SCHEMA=as
ENV FILE_PREFIX=$PG_SRC_DBNAME
ENV SKEL_FILE=$FILE_PREFIX.skeleton.json
ENV TMP_FILE=$FILE_PREFIX.tmp.sql
ENV DUMP_FILE=$FILE_PREFIX.dump.sql
ENV DBG_LVL=DEBUG
RUN pg_dump --version && pg_restore --version && gonymizer version
RUN apk update
RUN apk add jq
RUN touch $SKEL_FILE && rm $SKEL_FILE
#RUN gonymizer map --map-file="$FILE_PREFIX" -S -H "$PG_SRC_HOST" -p "$PG_SRC_PSWD" -U "$PG_SRC_USER" -P "$PG_SRC_PORT" -d "$PG_SRC_DBNAME" --schema "$PG_SRC_SCHEMA" -L "$DBG_LVL"
RUN echo '{"DBName":"grossolini_as","SchemaPrefix":"","Seed":0,"ColumnMaps":[{"Comment":"","TableSchema":"as","TableName":"as_streams_search","ColumnName":"v3_deprecated_login","DataType":"character varying","ParentSchema":"","ParentTable":"","ParentColumn":"","OrdinalPosition":16,"IsNullable":true,"Processors":[{"Name":"AlphaNumericScrambler","Max":0,"Min":0,"Variance":0,"Comment":""}]},{"Comment":"","TableSchema":"as","TableName":"as_streams_search","ColumnName":"v3_deprecated_password","DataType":"character varying","ParentSchema":"","ParentTable":"","ParentColumn":"","OrdinalPosition":17,"IsNullable":true,"Processors":[{"Name":"ScrubString","Max":0,"Min":0,"Variance":0,"Comment":""}]}]}' | jq > $SKEL_FILE
RUN touch $TMP_FILE && rm $TMP_FILE
RUN gonymizer dump --dump-file="$TMP_FILE" -S -H "$PG_SRC_HOST" -p "$PG_SRC_PSWD" -U "$PG_SRC_USER" -P "$PG_SRC_PORT" -d "$PG_SRC_DBNAME" --schema "$PG_SRC_SCHEMA" -L "$DBG_LVL"
RUN gonymizer process --map-file="$SKEL_FILE" --dump-file="$TMP_FILE" --processed-file="$DUMP_FILE" --generate-seed -L "$DBG_LVL"
The output with the smithoss/gonymizer image (starting after all the ENVβs):
Step 25/32 : RUN pg_dump --version && pg_restore --version && gonymizer version
---> Running in acc22444b47e
pg_dump (PostgreSQL) 11.3
pg_restore (PostgreSQL) 11.3
gonymizer (v1.1.1, build 5, build date:2019-05-06 23:50:02 +0000 UTC)
Go (runtime:go1.12.6) (GOMAXPROCS:2) (NumCPUs:2)
Removing intermediate container acc22444b47e
---> 30c431b3bc6c
Step 26/32 : RUN apk update
---> Running in 524cd4b2c078
fetch http://dl-cdn.alpinelinux.org/alpine/v3.10/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.10/community/x86_64/APKINDEX.tar.gz
v3.10.5-83-g4b863b300a [http://dl-cdn.alpinelinux.org/alpine/v3.10/main]
v3.10.5-73-g9ff6848e18 [http://dl-cdn.alpinelinux.org/alpine/v3.10/community]
OK: 10365 distinct packages available
Removing intermediate container 524cd4b2c078
---> 2dfe825e40b6
Step 27/32 : RUN apk add jq
---> Running in 6f1fdc068f01
(1/2) Installing oniguruma (6.9.4-r0)
(2/2) Installing jq (1.6-r0)
Executing busybox-1.30.1-r2.trigger
OK: 37 MiB in 32 packages
Removing intermediate container 6f1fdc068f01
---> dc8d01962a14
Step 28/32 : RUN touch $SKEL_FILE && rm $SKEL_FILE
---> Running in a3525973e8d8
Removing intermediate container a3525973e8d8
---> bf1226931dee
Step 29/32 : RUN echo '{"DBName":"grossolini_as","SchemaPrefix":"","Seed":0,"ColumnMaps":[{"Comment":"","TableSchema":"as","TableName":"as_streams_search","ColumnName":"v3_deprecated_login","DataType":"character varying","ParentSchema":"","ParentTable":"","ParentColumn":"","OrdinalPosition":16,"IsNullable":true,"Processors":[{"Name":"AlphaNumericScrambler","Max":0,"Min":0,"Variance":0,"Comment":""}]},{"Comment":"","TableSchema":"as","TableName":"as_streams_search","ColumnName":"v3_deprecated_password","DataType":"character varying","ParentSchema":"","ParentTable":"","ParentColumn":"","OrdinalPosition":17,"IsNullable":true,"Processors":[{"Name":"ScrubString","Max":0,"Min":0,"Variance":0,"Comment":""}]}]}' | jq > $SKEL_FILE
---> Running in d4127754615f
Removing intermediate container d4127754615f
---> fd635a371ac3
Step 30/32 : RUN touch $TMP_FILE && rm $TMP_FILE
---> Running in 3441491edaf9
Removing intermediate container 3441491edaf9
---> dbdf302a46e6
Step 31/32 : RUN gonymizer dump --dump-file="$TMP_FILE" -S -H "$PG_SRC_HOST" -p "$PG_SRC_PSWD" -U "$PG_SRC_USER" -P "$PG_SRC_PORT" -d "$PG_SRC_DBNAME" --schema "$PG_SRC_SCHEMA" -L "$DBG_LVL"
---> Running in 2a7de0e1e1f8
time="2020-09-08 09:55:36.938" level=debug msg="π \x1b[1;32m configuration \x1b[0m π"
Aliases:
map[string]string{}
Override:
map[string]interface {}{}
time="2020-09-08 09:55:36.938" level=debug msg="π \x1b[1;32m configuration \x1b[0m βοΈ"
time="2020-09-08 09:55:36.938" level=debug msg="os.Args: [gonymizer dump --dump-file=grossolini_as.tmp.sql -S **REMOVED** -L DEBUG]"
PFlags:
map[string]viper.FlagValue{"config":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d06e0)}, "database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0c80)}, "disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0960)}, "dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1180)}, "dump.database":viper.pflagValue{flag:(*pflag.Flag)(0xc000095c20)}, "dump.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc000095900)}, "dump.dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc000095cc0)}, "dump.exclude-schemas":viper.pflagValue{flag:(*pflag.Flag)(0xc000095ae0)}, "dump.exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0000959a0)}, "dump.exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc000095a40)}, "dump.host":viper.pflagValue{flag:(*pflag.Flag)(0xc000095b80)}, "dump.password":viper.pflagValue{flag:(*pflag.Flag)(0xc000095ea0)}, "dump.port":viper.pflagValue{flag:(*pflag.Flag)(0xc000095f40)}, "dump.row-count-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d05a0)}, "dump.schema":viper.pflagValue{flag:(*pflag.Flag)(0xc000095d60)}, "dump.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d00a0)}, "exclude-schemas":viper.pflagValue{flag:(*pflag.Flag)(0xc000095ae0)}, "exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0aa0)}, "exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0b40)}, "generate-seed":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1040)}, "help":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1400)}, "host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0be0)}, "load.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0280)}, "load.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0140)}, "load.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d01e0)}, "load.load-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0320)}, "load.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0460)}, "load.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0500)}, "load.skip-procedures":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d03c0)}, "load.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0640)}, "log-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0780)}, "log-format":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d08c0)}, "log-level":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0820)}, "map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d10e0)}, "map.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0c80)}, "map.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0960)}, "map.exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0aa0)}, "map.exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0b40)}, "map.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0be0)}, "map.map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0a00)}, "map.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0e60)}, "map.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0f00)}, "map.schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0d20)}, "map.schema-prefix":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0dc0)}, "map.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0fa0)}, "password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0e60)}, "port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0f00)}, "post-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d12c0)}, "process.dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1180)}, "process.generate-seed":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1040)}, "process.map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d10e0)}, "process.post-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d12c0)}, "process.processed-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1220)}, "process.s3-file-path":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1360)}, "processed-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1220)}, "row-count-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0000)}, "s3-file-path":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d1360)}, "schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0d20)}, "schema-prefix":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0dc0)}, "username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001d0fa0)}}
Env:
map[string]string{}
Key/Value Store:
map[string]interface {}{}
Config:
map[string]interface {}{}
Defaults:
map[string]interface {}{}
time="2020-09-08 09:55:36.938" level=debug msg="Starting gonymizer (v1.1.1, build 5, build date:2019-05-06 23:50:02 +0000 UTC)"
time="2020-09-08 09:55:36.938" level=debug msg="Go (runtime:go1.12.6) (GOMAXPROCS:2) (NumCPUs:2)\n"
time="2020-09-08 09:55:36.938" level=info msg="\x1b[1;33mEnabling log level: DEBUG\x1b[0m"
time="2020-09-08 09:55:41.963" level=info msg="π \x1b[1;32mCreating dump file\x1b[0m π"
time="2020-09-08 09:55:41.963" level=info msg="Dumping the following schemas: [as]"
time="2020-09-08 09:55:41.963" level=debug msg="Running command: pg_dump **REMOVED** --oids --no-owner --schema=as.*"
time="2020-09-08 09:56:34.741" level=info msg="π¦ \x1b[1;32m-- SUCCESS --\x1b[0m π"
Removing intermediate container 2a7de0e1e1f8
---> 08b12d84887b
Step 32/32 : RUN gonymizer process --map-file="$SKEL_FILE" --dump-file="$TMP_FILE" --processed-file="$DUMP_FILE" --generate-seed -L "$DBG_LVL"
---> Running in a99a167a770a
Aliases:
map[string]string{}
Override:
map[string]interface {}{}
time="2020-09-08 09:56:40.034" level=debug msg="π \x1b[1;32m configuration \x1b[0m π"
PFlags:
map[string]viper.FlagValue{"config":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac640)}, "database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acbe0)}, "disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac8c0)}, "dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad0e0)}, "dump.database":viper.pflagValue{flag:(*pflag.Flag)(0xc000079b80)}, "dump.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc000079860)}, "dump.dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc000079c20)}, "dump.exclude-schemas":viper.pflagValue{flag:(*pflag.Flag)(0xc000079a40)}, "dump.exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc000079900)}, "dump.exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0000799a0)}, "dump.host":viper.pflagValue{flag:(*pflag.Flag)(0xc000079ae0)}, "dump.password":viper.pflagValue{flag:(*pflag.Flag)(0xc000079e00)}, "dump.port":viper.pflagValue{flag:(*pflag.Flag)(0xc000079ea0)}, "dump.row-count-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac500)}, "dump.schema":viper.pflagValue{flag:(*pflag.Flag)(0xc000079cc0)}, "dump.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac000)}, "exclude-schemas":viper.pflagValue{flag:(*pflag.Flag)(0xc000079a40)}, "exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001aca00)}, "exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acaa0)}, "generate-seed":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acfa0)}, "help":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad360)}, "host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acb40)}, "load.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac1e0)}, "load.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac0a0)}, "load.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac140)}, "load.load-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac280)}, "load.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac3c0)}, "load.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac460)}, "load.skip-procedures":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac320)}, "load.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac5a0)}, "log-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac6e0)}, "log-format":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac820)}, "log-level":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac780)}, "map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad040)}, "map.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acbe0)}, "map.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac8c0)}, "map.exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001aca00)}, "map.exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acaa0)}, "map.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acb40)}, "map.map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ac960)}, "map.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acdc0)}, "map.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ace60)}, "map.schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acc80)}, "map.schema-prefix":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acd20)}, "map.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acf00)}, "password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acdc0)}, "port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ace60)}, "post-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad220)}, "process.dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad0e0)}, "process.generate-seed":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acfa0)}, "process.map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad040)}, "process.post-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad220)}, "process.processed-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad180)}, "process.s3-file-path":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad2c0)}, "processed-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad180)}, "row-count-file":viper.pflagValue{flag:(*pflag.Flag)(0xc000079f40)}, "s3-file-path":viper.pflagValue{flag:(*pflag.Flag)(0xc0001ad2c0)}, "schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acc80)}, "schema-prefix":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acd20)}, "username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001acf00)}}
Env:
map[string]string{}
Key/Value Store:
map[string]interface {}{}
Config:
map[string]interface {}{}
Defaults:
map[string]interface {}{}
time="2020-09-08 09:56:40.034" level=debug msg="π \x1b[1;32m configuration \x1b[0m βοΈ"
time="2020-09-08 09:56:40.034" level=debug msg="os.Args: [gonymizer process --map-file=grossolini_as.skeleton.json --dump-file=grossolini_as.tmp.sql --processed-file=grossolini_as.dump.sql --generate-seed -L DEBUG]"
time="2020-09-08 09:56:40.034" level=debug msg="Starting gonymizer (v1.1.1, build 5, build date:2019-05-06 23:50:02 +0000 UTC)"
time="2020-09-08 09:56:40.034" level=debug msg="Go (runtime:go1.12.6) (GOMAXPROCS:2) (NumCPUs:2)\n"
time="2020-09-08 09:56:40.034" level=info msg="\x1b[1;33mEnabling log level: DEBUG\x1b[0m"
time="2020-09-08 09:56:40.034" level=debug msg="s3-file-path: "
time="2020-09-08 09:56:40.034" level=debug msg="S3 URL: <nil>\tScheme: \tBucket: \tRegion: \tFile Path: "
time="2020-09-08 09:56:40.034" level=info msg="π \x1b[1;32mProcessing dump file\x1b[0m π"
time="2020-09-08 09:56:40.034" level=info msg="Loading map file from: grossolini_as.skeleton.json"
time="2020-09-08 09:56:40.035" level=info msg="Processing dump file: grossolini_as.tmp.sql"
time="2020-09-08 09:56:40.035" level=debug msg="Using internal number generator for seed value: 2135716918243314402"
[ ...a bunch of Schema.Table logs... ]
time="2020-09-08 09:56:54.899" level=info msg="Processing line number: 2900000"
time="2020-09-08 09:56:55.249" level=info msg="Processing line number: 3000000"
panic: runtime error: index out of range
goroutine 1 [running]:
github.com/smithoss/gonymizer.(*LineState).parseCopyLine(0xc000373928, 0xc000260aa0, 0x13)
/usr/local/go/src/github.com/smithoss/gonymizer/generator.go:404 +0x5ac
github.com/smithoss/gonymizer.processLine(0xc00005d480, 0xc000373928, 0xc000260aa0, 0x13, 0xc000260aa0, 0x13, 0x0, 0x0, 0x0)
/usr/local/go/src/github.com/smithoss/gonymizer/generator.go:301 +0x276
github.com/smithoss/gonymizer.ProcessDumpFile(0xc00005d480, 0x7ffd256fdd75, 0x15, 0x7ffd256fdd9c, 0x16, 0x0, 0x0, 0xaca301, 0x0, 0x0)
/usr/local/go/src/github.com/smithoss/gonymizer/generator.go:200 +0x8de
main.process(0x7ffd256fdd75, 0x15, 0x7ffd256fdd4d, 0x1b, 0x7ffd256fdd9c, 0x16, 0x1, 0xc00007ea00, 0xc000157b30, 0x0)
/usr/local/go/src/github.com/smithoss/gonymizer/command/process.go:136 +0x20d
main.cliCommandProcess(0x126ea60, 0xc000060ba0, 0x0, 0x6)
/usr/local/go/src/github.com/smithoss/gonymizer/command/process.go:111 +0x830
github.com/spf13/cobra.(*Command).execute(0x126ea60, 0xc000060a80, 0x6, 0x6, 0x126ea60, 0xc000060a80)
/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:766 +0x2ae
github.com/spf13/cobra.(*Command).ExecuteC(0x126e5a0, 0x0, 0x0, 0xc00015a900)
/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:852 +0x2ec
github.com/spf13/cobra.(*Command).Execute(...)
/go/pkg/mod/github.com/spf13/cobra@v0.0.3/command.go:800
main.main()
/usr/local/go/src/github.com/smithoss/gonymizer/command/main.go:116 +0x32
The command '/bin/sh -c gonymizer process --map-file="$SKEL_FILE" --dump-file="$TMP_FILE" --processed-file="$DUMP_FILE" --generate-seed -L "$DBG_LVL"' returned a non-zero code: 2
Here is the output using the junkert/gonymizer image:
Step 25/32 : RUN pg_dump --version && pg_restore --version && gonymizer version
---> Running in dee19173bf66
pg_dump (PostgreSQL) 12.3
pg_restore (PostgreSQL) 12.3
gonymizer (v1.2.0, build 10, build date:2019-07-31 17:23:35 +0000 UTC)
Go (runtime:go1.13.15) (GOMAXPROCS:2) (NumCPUs:2)
Removing intermediate container dee19173bf66
---> a344329f4c4b
Step 26/32 : RUN apk update
---> Running in 5a2dcd65cd28
fetch http://dl-cdn.alpinelinux.org/alpine/v3.12/main/x86_64/APKINDEX.tar.gz
fetch http://dl-cdn.alpinelinux.org/alpine/v3.12/community/x86_64/APKINDEX.tar.gz
v3.12.0-295-gaaa7f43dbe [http://dl-cdn.alpinelinux.org/alpine/v3.12/main]
v3.12.0-301-g6a4ffc91b5 [http://dl-cdn.alpinelinux.org/alpine/v3.12/community]
OK: 12743 distinct packages available
Removing intermediate container 5a2dcd65cd28
---> c50cfe680df3
Step 27/32 : RUN apk add jq
---> Running in 7ee73a81b6a9
(1/2) Installing oniguruma (6.9.5-r1)
(2/2) Installing jq (1.6-r1)
Executing busybox-1.31.1-r19.trigger
OK: 143 MiB in 34 packages
Removing intermediate container 7ee73a81b6a9
---> 4a6b2d3c0e5c
Step 28/32 : RUN touch $SKEL_FILE && rm $SKEL_FILE
---> Running in f7c9b3e50d61
Removing intermediate container f7c9b3e50d61
---> 8a9bb573a6be
Step 29/32 : RUN echo '{"DBName":"grossolini_as","SchemaPrefix":"","Seed":0,"ColumnMaps":[{"Comment":"","TableSchema":"as","TableName":"as_streams_search","ColumnName":"v3_deprecated_login","DataType":"character varying","ParentSchema":"","ParentTable":"","ParentColumn":"","OrdinalPosition":16,"IsNullable":true,"Processors":[{"Name":"AlphaNumericScrambler","Max":0,"Min":0,"Variance":0,"Comment":""}]},{"Comment":"","TableSchema":"as","TableName":"as_streams_search","ColumnName":"v3_deprecated_password","DataType":"character varying","ParentSchema":"","ParentTable":"","ParentColumn":"","OrdinalPosition":17,"IsNullable":true,"Processors":[{"Name":"ScrubString","Max":0,"Min":0,"Variance":0,"Comment":""}]}]}' | jq > $SKEL_FILE
---> Running in e9f771655822
Removing intermediate container e9f771655822
---> 976c25ed8ce8
Step 30/32 : RUN touch $TMP_FILE && rm $TMP_FILE
---> Running in f61f78f618a5
Removing intermediate container f61f78f618a5
---> 1b0f4064cfd2
Step 31/32 : RUN gonymizer dump --dump-file="$TMP_FILE" -S -H "$PG_SRC_HOST" -p "$PG_SRC_PSWD" -U "$PG_SRC_USER" -P "$PG_SRC_PORT" -d "$PG_SRC_DBNAME" --schema "$PG_SRC_SCHEMA" -L "$DBG_LVL"
---> Running in d84f19600f4a
time="2020-09-08 10:03:48.473" level=debug msg="os.Args: [gonymizer dump --dump-file=grossolini_as.tmp.sql -S **REMOVED** -L DEBUG]"
time="2020-09-08 10:03:48.473" level=debug msg="π configuration π"
Aliases:
map[string]string{}
Override:
map[string]interface {}{}
PFlags:
map[string]viper.FlagValue{"config":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3220)}, "database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a37c0)}, "disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a34a0)}, "dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3cc0)}, "dump.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2780)}, "dump.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2460)}, "dump.dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2820)}, "dump.exclude-schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2640)}, "dump.exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2500)}, "dump.exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a25a0)}, "dump.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a26e0)}, "dump.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2a00)}, "dump.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2aa0)}, "dump.row-count-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a30e0)}, "dump.schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a28c0)}, "dump.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2be0)}, "exclude-schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2640)}, "exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a35e0)}, "exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3680)}, "generate-seed":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3b80)}, "help":viper.pflagValue{flag:(*pflag.Flag)(0xc0001f2140)}, "host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3720)}, "inclusive":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3d60)}, "load.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2dc0)}, "load.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2c80)}, "load.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2d20)}, "load.load-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2e60)}, "load.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2fa0)}, "load.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3040)}, "load.skip-procedures":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2f00)}, "load.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3180)}, "local-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001f20a0)}, "log-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a32c0)}, "log-format":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3400)}, "log-level":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3360)}, "map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3c20)}, "map.database":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a37c0)}, "map.disable-ssl":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a34a0)}, "map.exclude-table":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a35e0)}, "map.exclude-table-data":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3680)}, "map.host":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3720)}, "map.map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3540)}, "map.password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a39a0)}, "map.port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3a40)}, "map.schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3860)}, "map.schema-prefix":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3900)}, "map.username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3ae0)}, "password":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a39a0)}, "port":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3a40)}, "post-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3f40)}, "pre-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3ea0)}, "process.dump-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3cc0)}, "process.generate-seed":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3b80)}, "process.inclusive":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3d60)}, "process.map-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3c20)}, "process.post-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3f40)}, "process.pre-process-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3ea0)}, "process.processed-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3e00)}, "processed-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3e00)}, "row-count-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a2b40)}, "s3-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001f2000)}, "schema":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3860)}, "schema-prefix":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3900)}, "upload.local-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001f20a0)}, "upload.s3-file":viper.pflagValue{flag:(*pflag.Flag)(0xc0001f2000)}, "username":viper.pflagValue{flag:(*pflag.Flag)(0xc0001a3ae0)}}
Env:
map[string]string{}
Key/Value Store:
map[string]interface {}{}
Config:
map[string]interface {}{}
Defaults:
map[string]interface {}{}
time="2020-09-08 10:03:48.473" level=debug msg="π configuration βοΈ"
time="2020-09-08 10:03:48.473" level=debug msg="Starting gonymizer (v1.2.0, build 10, build date: 2019-07-31 17:23:35 +0000 UTC)"
time="2020-09-08 10:03:48.473" level=debug msg="Go (runtime: go1.13.15) (GOMAXPROCS: 2) (NumCPUs: 2)
"
time="2020-09-08 10:03:48.473" level=info msg="Enabling log level: DEBUG"
time="2020-09-08 10:03:48.506" level=info msg="π Creating dump file π"
time="2020-09-08 10:03:48.506" level=debug msg="Running command: pg_dump --oids --no-owner --schema=as.* -f grossolini_as.tmp.sql **REMOVED**"
time="2020-09-08 10:03:48.509" level=error msg="exit status 1"
time="2020-09-08 10:03:48.509" level=debug msg="name: pg_dump"
time="2020-09-08 10:03:48.509" level=debug msg="arg: [--oids --no-owner --schema=as.* -f grossolini_as.tmp.sql **REMOVED**]"
time="2020-09-08 10:03:48.509" level=debug msg="errBytes:
=====================
pg_dump: unrecognized option: oids
Try "pg_dump --help" for more information.
=====================
"
time="2020-09-08 10:03:48.509" level=debug msg="errBytes:
=====================
pg_dump: unrecognized option: oids
Try "pg_dump --help" for more information.
=====================
"
time="2020-09-08 10:03:48.509" level=error msg="STDOUT: "
time="2020-09-08 10:03:48.509" level=error msg="STDERR: pg_dump: unrecognized option: oids
Try "pg_dump --help" for more information.
"
time="2020-09-08 10:03:48.509" level=error msg="exit status 1"
time="2020-09-08 10:03:48.509" level=error msg="exit status 1"
time="2020-09-08 10:03:48.509" level=error msg="β Gonymizer did not exit properly. See above for errors β"
The command '/bin/sh -c gonymizer dump --dump-file="$TMP_FILE" -S -H "$PG_SRC_HOST" -p "$PG_SRC_PSWD" -U "$PG_SRC_USER" -P "$PG_SRC_PORT" -d "$PG_SRC_DBNAME" --schema "$PG_SRC_SCHEMA" -L "$DBG_LVL"' returned a non-zero code: 1
About this issue
- Original URL
- State: closed
- Created 4 years ago
- Comments: 18 (2 by maintainers)
Might it be because the first fieldβs value starts with the substring βCOPYβ?