Created
June 7, 2018 15:57
-
-
Save infotroph/e0b95af26bf22eadc50ba6739d4b0124 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# OS X 10.13.4, Postgres 10.4 | |
0> curl -o bety.sql.gz http://pecan.ncsa.illinois.edu/dump/betydump.psql.gz | |
% Total % Received % Xferd Average Speed Time Time Time Current | |
Dload Upload Total Spent Left Speed | |
100 167M 100 167M 0 0 7790k 0 0:00:21 0:00:21 --:--:-- 8289k | |
# read into a new database cluster, to avoid disturbing my local bety | |
0> mkdir tmp_bety chrisb@morus:~/Desktop | |
0> initdb -U postgres -D tmp_bety chrisb@morus:~/Desktop | |
The files belonging to this database system will be owned by user "chrisb". | |
This user must also own the server process. | |
The database cluster will be initialized with locale "en_US.UTF-8". | |
The default database encoding has accordingly been set to "UTF8". | |
The default text search configuration will be set to "english". | |
Data page checksums are disabled. | |
fixing permissions on existing directory tmp_bety ... ok | |
creating subdirectories ... ok | |
selecting default max_connections ... 100 | |
selecting default shared_buffers ... 128MB | |
selecting dynamic shared memory implementation ... posix | |
creating configuration files ... ok | |
running bootstrap script ... ok | |
performing post-bootstrap initialization ... ok | |
syncing data to disk ... ok | |
WARNING: enabling "trust" authentication for local connections | |
You can change this by editing pg_hba.conf or using the option -A, or | |
--auth-local and --auth-host, the next time you run initdb. | |
Success. You can now start the database server using: | |
pg_ctl -D tmp_bety -l logfile start | |
0> pg_ctl -D tmp_bety -l tmp_bety/logfile start chrisb@morus:~/Desktop | |
waiting for server to start.... done | |
server started | |
# generate fresh bety as in .travis.yml | |
# Travis version of this line has UNENCRYPTED before PASSWORD; removed when my Postgres complained | |
0> psql -q -o /dev/null -U postgres -c "CREATE ROLE BETY WITH LOGIN CREATEDB SUPERUSER CREATEROLE PASSWORD 'bety'"; | |
0> psql -q -o /dev/null -U postgres -c "CREATE DATABASE bety OWNER bety;" | |
0> gunzip -c bety.sql.gz | psql -q -o /dev/null -U postgres | |
ERROR: database "betydump" does not exist | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY citations, line 1: "3 Balasko 1984 Yield and Quality of Switchgrass Grown without Soil Amendments Agronomy Journal 76 20..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY cultivars, line 1: "55 1477 hornum see brown2001pmg for details \N \N mghorn" | |
ERROR: relation "pfts_species" does not exist | |
LINE 1: SELECT EXISTS(SELECT 1 FROM pfts_species WHERE pft_id = this... | |
^ | |
QUERY: SELECT EXISTS(SELECT 1 FROM pfts_species WHERE pft_id = this_pft_id) | |
CONTEXT: PL/pgSQL function public.no_species_member(bigint) line 4 at SQL statement | |
COPY cultivars_pfts, line 1: "137 1 2018-01-31 16:44:25.756546 2018-01-31 16:44:25.756546 1" | |
ERROR: relation "inputs" does not exist | |
LINE 4: inputs | |
^ | |
QUERY: SELECT | |
ARRAY_AGG(id) | |
FROM | |
inputs | |
CONTEXT: PL/pgSQL function public.get_input_ids() line 5 at SQL statement | |
COPY dbfiles, line 1: "232 mrp.clim /home/share/data/dbfiles/ 8738893b4316b11a59e50f99c04d8c2b 1 1 2 2012-07-22 22:58:45 20..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY entities, line 1: "1 \N Picea engelmannii collected from High elevation2013-06-05 17:22:02 2013-06-05 17:36:17" | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY formats, line 1: "21 Weekly AmeriFlux level 4 gap filled, partitioned, and flagged flux tower data. Variables descript..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY inputs, line 1: "5 76 2011-10-17 20:36:09 2011-10-17 20:36:09 \N \N EBI Energy farm site \N 2 2 f 10" | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY methods, line 1: "3 PM Penman-Monteith 617 2012-09-20 18:09:05 2012-09-20 18:09:05" | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY models, line 1: "13 dvmdostem git \N 2017-07-21 17:38:14.521487 2017-07-21 17:38:14.521487 4" | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY pfts, line 1: "110 Early successional hardwood for eastern temperate forest. Default pft = 9. Archetypes are poplar..." | |
ERROR: relation "cultivars_pfts" does not exist | |
LINE 1: SELECT EXISTS(SELECT 1 FROM cultivars_pfts WHERE pft_id = th... | |
^ | |
QUERY: SELECT EXISTS(SELECT 1 FROM cultivars_pfts WHERE pft_id = this_pft_id) | |
CONTEXT: PL/pgSQL function public.no_cultivar_member(bigint) line 4 at SQL statement | |
COPY pfts_species, line 1: "10 938 2010-08-31 16:19:13 2010-09-01 23:05:50 1" | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY priors, line 1: "1 276 36 plants gamma 1.46999999999999997 0.0577999999999999972 \N 0 optimized to gamma with 95% CI ..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY sites, line 1: "668 Mount Edgecombe ZA \N \N \N elevation queried from lat lon using R geonames::GNstrm3 2011-09-..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY species, line 1: "30938 \N Loxosporopsis Loxosporopsis 2011-03-02 13:48:36 2011-03-02 13:48:36 LOXOS2 LOXOS2 NA L..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY treatments, line 1: "1 observational \N 2013-11-01 21:22:12 t \N" | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY users, line 1: "0 user0 user 0 betydb+0@gmail.com Urbana USA 1234567890abcdef BU 2018-06-07 00:04:02.366333 2018-06..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY variables, line 1: "605 proposed standard name for plant functional type 2016-05-18 15:44:48.424244 2016-05-18 15:44:4..." | |
ERROR: function normalize_whitespace(text) does not exist | |
LINE 1: SELECT string = normalize_whitespace(string) | |
^ | |
HINT: No function matches the given name and argument types. You might need to add explicit type casts. | |
QUERY: SELECT string = normalize_whitespace(string) | |
CONTEXT: PL/pgSQL function public.is_whitespace_normalized(text) line 3 at RETURN | |
COPY workflows, line 1: "106 /home/dlebauer/.pecan/biocrotest 2014-12-15 10:35:25 \N 2014-12-15 10:35:25 \N 154 7 localhost ..." | |
ERROR: insert or update on table "benchmarks_ensembles" violates foreign key constraint "benchmarks_ensembles_model_id_fkey" | |
DETAIL: Key (model_id)=(1000000002) is not present in table "models". | |
ERROR: insert or update on table "benchmarks" violates foreign key constraint "benchmarks_input_id_fkey" | |
DETAIL: Key (input_id)=(1000008121) is not present in table "inputs". | |
ERROR: insert or update on table "benchmarks" violates foreign key constraint "benchmarks_site_id_fkey" | |
DETAIL: Key (site_id)=(666) is not present in table "sites". | |
ERROR: insert or update on table "benchmarks" violates foreign key constraint "benchmarks_variable_id_fkey" | |
DETAIL: Key (variable_id)=(411) is not present in table "variables". | |
ERROR: insert or update on table "citations_sites" violates foreign key constraint "fk_citations_sites_citations_1" | |
DETAIL: Key (citation_id)=(209) is not present in table "citations". | |
ERROR: insert or update on table "citations_sites" violates foreign key constraint "fk_citations_sites_sites_1" | |
DETAIL: Key (site_id)=(285) is not present in table "sites". | |
ERROR: insert or update on table "citations_treatments" violates foreign key constraint "fk_citations_treatments_citations_1" | |
DETAIL: Key (citation_id)=(152) is not present in table "citations". | |
ERROR: insert or update on table "citations_treatments" violates foreign key constraint "fk_citations_treatments_treatments_1" | |
DETAIL: Key (treatment_id)=(685) is not present in table "treatments". | |
ERROR: insert or update on table "covariates" violates foreign key constraint "fk_covariates_variables_1" | |
DETAIL: Key (variable_id)=(191) is not present in table "variables". | |
ERROR: insert or update on table "ensembles" violates foreign key constraint "fk_ensembles_workflows_1" | |
DETAIL: Key (workflow_id)=(109) is not present in table "workflows". | |
ERROR: insert or update on table "formats_variables" violates foreign key constraint "fk_formats_variables_formats_1" | |
DETAIL: Key (format_id)=(19) is not present in table "formats". | |
ERROR: insert or update on table "formats_variables" violates foreign key constraint "fk_formats_variables_variables_1" | |
DETAIL: Key (variable_id)=(297) is not present in table "variables". | |
ERROR: insert or update on table "inputs_runs" violates foreign key constraint "fk_inputs_runs_inputs_1" | |
DETAIL: Key (input_id)=(295) is not present in table "inputs". | |
ERROR: insert or update on table "likelihoods" violates foreign key constraint "fk_likelihoods_inputs_1" | |
DETAIL: Key (input_id)=(1000000358) is not present in table "inputs". | |
ERROR: insert or update on table "likelihoods" violates foreign key constraint "fk_likelihoods_variables_1" | |
DETAIL: Key (variable_id)=(297) is not present in table "variables". | |
ERROR: insert or update on table "managements" violates foreign key constraint "fk_managements_citations_1" | |
DETAIL: Key (citation_id)=(42) is not present in table "citations". | |
ERROR: insert or update on table "managements_treatments" violates foreign key constraint "fk_managements_treatments_treatments_1" | |
DETAIL: Key (treatment_id)=(1) is not present in table "treatments". | |
ERROR: insert or update on table "managements" violates foreign key constraint "fk_managements_users_1" | |
DETAIL: Key (user_id)=(97) is not present in table "users". | |
ERROR: insert or update on table "modeltypes_formats" violates foreign key constraint "fk_modeltypes_formats_formats_1" | |
DETAIL: Key (format_id)=(24) is not present in table "formats". | |
ERROR: insert or update on table "modeltypes" violates foreign key constraint "fk_modeltypes_users_1" | |
DETAIL: Key (user_id)=(1000000001) is not present in table "users". | |
ERROR: insert or update on table "posteriors" violates foreign key constraint "fk_posteriors_pfts_1" | |
DETAIL: Key (pft_id)=(62) is not present in table "pfts". | |
ERROR: insert or update on table "runs" violates foreign key constraint "fk_runs_models_1" | |
DETAIL: Key (model_id)=(12) is not present in table "models". | |
ERROR: insert or update on table "runs" violates foreign key constraint "fk_runs_sites_1" | |
DETAIL: Key (site_id)=(1017) is not present in table "sites". | |
ERROR: insert or update on table "sitegroups_sites" violates foreign key constraint "fk_sitegroups_sites_sites" | |
DETAIL: Key (site_id)=(1000000030) is not present in table "sites". | |
ERROR: insert or update on table "sitegroups" violates foreign key constraint "fk_sitegroups_users" | |
DETAIL: Key (user_id)=(55) is not present in table "users". | |
ERROR: insert or update on table "trait_covariate_associations" violates foreign key constraint "fk_trait_covariate_associations_variables_1" | |
DETAIL: Key (covariate_variable_id)=(343) is not present in table "variables". | |
ERROR: insert or update on table "trait_covariate_associations" violates foreign key constraint "fk_trait_covariate_associations_variables_2" | |
DETAIL: Key (trait_variable_id)=(39) is not present in table "variables". | |
ERROR: insert or update on table "yields" violates foreign key constraint "fk_yields_citations_1" | |
DETAIL: Key (citation_id)=(808) is not present in table "citations". | |
ERROR: insert or update on table "yields" violates foreign key constraint "fk_yields_cultivars_1" | |
DETAIL: Key (cultivar_id)=(543) is not present in table "cultivars". | |
ERROR: insert or update on table "yields" violates foreign key constraint "fk_yields_methods_1" | |
DETAIL: Key (method_id)=(3) is not present in table "methods". | |
ERROR: insert or update on table "yields" violates foreign key constraint "fk_yields_species_1" | |
DETAIL: Key (specie_id)=(831) is not present in table "species". | |
ERROR: insert or update on table "yields" violates foreign key constraint "fk_yields_treatments_1" | |
DETAIL: Key (treatment_id)=(2494) is not present in table "treatments". | |
ERROR: insert or update on table "yields" violates foreign key constraint "fk_yields_users_1" | |
DETAIL: Key (user_id)=(2) is not present in table "users". | |
ERROR: insert or update on table "reference_runs" violates foreign key constraint "reference_runs_model_id_fkey" | |
DETAIL: Key (model_id)=(1000000013) is not present in table "models". | |
0> psql -U bety -d betydump chrisb@morus:~/Desktop | |
psql (10.4) | |
Type "help" for help. | |
betydump=# select count(id) from pfts; | |
count | |
------- | |
0 | |
(1 row) | |
betydump=# select count(id) from cultivars; | |
count | |
------- | |
0 | |
(1 row) | |
betydump=# select count(id) from modeltypes; | |
count | |
------- | |
16 | |
(1 row) | |
betydump=# select count(id) from likelihoods; | |
count | |
--------- | |
3786679 | |
(1 row) | |
betydump=# |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Attempted bety load, PEcAn VM: