Created
September 20, 2018 05:29
-
-
Save ediskandarov/fb494224ad781ec41c913e6718281966 to your computer and use it in GitHub Desktop.
Fetch a file from remote sever when there is no ssh or any other access
This file contains hidden or 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
$ # compress a file and encode it in base64 format | |
$ gzip -k -c grafana.db | base64 - > grafana.db.gz.base64 | |
$ # calculate md5 sum | |
$ md5sum grafana.db.gz.base64 | |
$ # calculate md5 sum and compare results | |
$ md5sum grafana.db.gz.base64 | |
$ # to decompress, reverse actions | |
$ base64 -D grafana.db.gz.base64 | gunzip > grafana.db |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment