heavyai / heavydb

HeavyDB (formerly OmniSciDB)
https://heavy.ai
Apache License 2.0
2.95k stars 448 forks source link

File or directory path "/opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render/storage/import/sample_datasets/flights_2008_7M/flights_2008_7M.csv" is not whitelisted. #732

Closed jieguolove closed 2 years ago

jieguolove commented 2 years ago

omnisky@omnisky-Super-Server:/opt/heavyai$ sudo ./insert_sample_data Using default storage directory: "/opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render/storage" if file path is not whitelisted use '--data /path_to_server_data_directory' /opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render/storage/import/sample_datasets /opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render --2022-04-21 02:55:43-- https://data.mapd.com/manifest.tsv Resolving data.mapd.com (data.mapd.com)... 72.28.97.165 Connecting to data.mapd.com (data.mapd.com)|72.28.97.165|:443... connected. HTTP request sent, awaiting response... 200 OK Length: 192 [application/octet-stream] Saving to: ‘manifest.tsv’

manifest.tsv 100%[==========================================================================>] 192 --.-KB/s in 0s

2022-04-21 02:55:44 (12.2 MB/s) - ‘manifest.tsv’ saved [192/192]

/opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render Enter dataset number to download, or 'q' to quit:

Dataset Rows Table Name File Name

1) Flights (2008) 7M flights_2008_7M flights_2008_7M.tar.gz 2) Flights (2008) 10k flights_2008_10k flights_2008_10k.tar.gz 3) NYC Tree Census (2015) 683k nyc_trees_2015_683k nyc_trees_2015_683k.tar.gz 1 /opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render/storage/import/sample_datasets /opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render

flights_2008_7M.tar.gz 100%[==========================================================================>] 359.57M 562KB/s in 19m 30s

2022-04-21 03:16:03 (315 KB/s) - ‘flights_2008_7M.tar.gz’ saved [377039522/377039522]

flights_2008_7M/ flights_2008_7M/flights_2008_7M.csv flights_2008_7M/flights_2008_7M.sql /opt/heavyai-installs/heavyai-ee-6.0.0-20220418-d4d1c2a42c-Linux-x86_64-render

cdessanti commented 2 years ago

Hi,

you can run the insert_sample_data command using the --data switch to the data location; if you have used the default run insert_sample_data --data /var/lib/heavyai or you can modify the allowed-import-paths to ["/"] so every path in the server is accessible from the server. The command can be placed in the heavy.conf under the data path in the database section and restart the server.

This applies also to files that you need to load into the database.

Regards, Candido