mongodb - Take mongdb dump from amazon awz from local -
i trying take mongodb dump amazon aws server. kinldy share command
from local working
sudo mongodump -d db** -o /opt/backup/
how server
sudo mongodump -d db** -i /opt/x.pem ubuntu@ip:/
there 3 things need in order make sure remote mongodump possible -
- make sure security group allows communications between computer , port 27017 (or other port mongo running on server)
- check if mongodb configured bind specific ip (by default binded 127.0.0.1 allows local communications only)
- change mongodump command -
mongodump -d <db**> -u <username> -p <password> --host <server_ip/dns>
having said that, better ssh server , dump data locally, zip , copy local machine in order minimize network load. if have ssh access server better (and more secure) approach dumping data.
Comments
Post a Comment