I can't export my data

Hello.
I can’t export my data.
Ubuntu 18.04 ip 192.168.0.199
My commands step by step

dgraph zero
dgraph alpha --lru_mb 2048
curl 192.168.0.199:8080/admin/export
curl http://192.168.0.199:8080/admin/export
curl localhost:8080/admin/export
curl 127.0.0.1:8080/admin/export

Video step by step

reposting it here

Maybe this is the issue. I think in that version this export endpoint was removed (It will be deprecated, but in the future, in the latest version it is back). You need to use the GraphQL Admin endpoint tho.

Use cURL or some GraphQL UI (e.g. Insomnia REST Client) and run this mutation.

mutation {
		export(input: {format: "rdf"}) {
			response {
				code
				message
			}
		}
	}
1 Like

It works for dgraph version : v2.0.0-rc1
My ip addr is 192.168.0.111
Target computer ip is 192.168.0.199

dgraph zero
dgraph alpha --lru_mb 2048 --whitelist localhost,192.168.0.111

You can do curl from 192.168.0.111 or localhost (http://localhost:8080/admin)

curl -Ss -H “Content-Type: application/json” http://192.168.0.199:8080/admin -XPOST -d ‘{ “query”: “mutation { export(input: {format: “rdf”}) { response { code message } }}” }’

It’s response:
{“data”:{“export”:{“response”:{“code”:“Success”,“message”:“Export completed.”}}}}

1 Like