{"id":1379,"date":"2021-09-23T10:07:49","date_gmt":"2021-09-23T10:07:49","guid":{"rendered":"https:\/\/www.velaninfo.com\/rs\/?post_type=techtips&#038;p=1379"},"modified":"2021-09-30T05:17:12","modified_gmt":"2021-09-30T05:17:12","slug":"sync-files-linux-server-amazon-s3-bucket","status":"publish","type":"techtips","link":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/","title":{"rendered":"How can I use Amazon S3 bucket to synchronize files and folders from a local Linux server to?"},"content":{"rendered":"<p>You need the following two details in order to communicate with S3.<\/p>\n<ol>\n<li>Credentials for an IAM user with read-write access to an<strong> S3 bucket<\/strong>.<\/li>\n<li>A client such as bash&#8217;s aws-cli, Python&#8217;s boto library, and so on.<\/li>\n<\/ol>\n<p>Once you have these details, you are ready to move your files. You can move them from your Linux server to <a href=\"https:\/\/www.velaninfo.com\/rs\/techtips\/amazon-s3-bucket\/\"><strong>Amazon S3 bucket<\/strong><\/a> and vice versa. The aws-cli example is shown below.<\/p>\n<p><strong>To synchronize all the files in a folder, you can use aws cli the following command<\/strong><\/p>\n<p><em>aws s3 sync \/home\/abc\/public html\/ s3:\/abc-test\/webroot\/ aws s3 sync \/home\/abc\/public html\/ aws s3 sync \/home\/abc\/public html<\/em><\/p>\n<p><strong>To copy a single file to Amazon S3 bucket, you can use the following command<\/strong><\/p>\n<p><em>aws s3 cp source file s3:\/ s3:\/abc-test\/webroot\/ aws s3 cp source file s3:\/ s3:\/abc-test\/webroot\/<\/em><\/p>\n<p>If you want to download any file from Amazon S3 bucket, you have to just replace the source with the destination in the command.<\/p>\n<p><strong>To exclude several folders when using AWS S3 Sync, you can use<\/strong> <strong>the following command.<\/strong><\/p>\n<p><em>aws s3 sync \/home\/abc\/public html\/ s3:\/abc-test\/webroot\/ \u2014exclude &#8216;blog images\/* soon\/*&#8217;<\/em><\/p>\n<p>At Velan, our server support engineers can assist you in installing and configuring Amazon S3 bucket to backup important data on your servers. If you wish to avail any of our services, please fill the <a href=\"https:\/\/www.velaninfo.com\/contact\"><strong>Quick connect form<\/strong><\/a> and get in touch with us.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>You need the following two details in order to communicate with S3. Credentials for an IAM user with read-write access to an S3 bucket. A client such as bash&#8217;s aws-cli, Python&#8217;s boto library, and so on. Once you have these details, you are ready to move your files. You can move them from your Linux&#8230;<a class=\"continue-reading text-uppercase\" href=\"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/\"> Continue Reading <img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.velaninfo.com\/rs\/wp-content\/themes\/velaninfo\/images\/reading_arw.png\" alt=\"Continue Reading\" width=\"16\" height=\"12\"\/><\/a><\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"open","ping_status":"closed","template":"","meta":{"footnotes":""},"tags":[],"class_list":["post-1379","techtips","type-techtips","status-publish","hentry","Categories_tech_tip-aws","Categories_tech_tip-cloud","Categories_tech_tip-s3"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v19.5 (Yoast SEO v27.5) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>Synchronize Files and Folders from Linux Server with Amazon S3 Bucket<\/title>\n<meta name=\"description\" content=\"You can upload files from the command line on your Linux server, or sync entire directories to Amazon S3 bucket, using these commands.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How can I use Amazon S3 bucket to synchronize files and folders from a local Linux server to?\" \/>\n<meta property=\"og:description\" content=\"You can upload files from the command line on your Linux server, or sync entire directories to Amazon S3 bucket, using these commands.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/\" \/>\n<meta property=\"og:site_name\" content=\"Velan\" \/>\n<meta property=\"article:modified_time\" content=\"2021-09-30T05:17:12+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/techtips\\\/sync-files-linux-server-amazon-s3-bucket\\\/\",\"url\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/techtips\\\/sync-files-linux-server-amazon-s3-bucket\\\/\",\"name\":\"Synchronize Files and Folders from Linux Server with Amazon S3 Bucket\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/#website\"},\"datePublished\":\"2021-09-23T10:07:49+00:00\",\"dateModified\":\"2021-09-30T05:17:12+00:00\",\"description\":\"You can upload files from the command line on your Linux server, or sync entire directories to Amazon S3 bucket, using these commands.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/techtips\\\/sync-files-linux-server-amazon-s3-bucket\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/techtips\\\/sync-files-linux-server-amazon-s3-bucket\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/techtips\\\/sync-files-linux-server-amazon-s3-bucket\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Tech Tips\",\"item\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/techtips\\\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"How can I use Amazon S3 bucket to synchronize files and folders from a local Linux server to?\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/#website\",\"url\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/\",\"name\":\"Velan\",\"description\":\"Velaninfo Services India Pvt Ltd\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.velaninfo.com\\\/rs\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Synchronize Files and Folders from Linux Server with Amazon S3 Bucket","description":"You can upload files from the command line on your Linux server, or sync entire directories to Amazon S3 bucket, using these commands.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/","og_locale":"en_US","og_type":"article","og_title":"How can I use Amazon S3 bucket to synchronize files and folders from a local Linux server to?","og_description":"You can upload files from the command line on your Linux server, or sync entire directories to Amazon S3 bucket, using these commands.","og_url":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/","og_site_name":"Velan","article_modified_time":"2021-09-30T05:17:12+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/","url":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/","name":"Synchronize Files and Folders from Linux Server with Amazon S3 Bucket","isPartOf":{"@id":"https:\/\/www.velaninfo.com\/rs\/#website"},"datePublished":"2021-09-23T10:07:49+00:00","dateModified":"2021-09-30T05:17:12+00:00","description":"You can upload files from the command line on your Linux server, or sync entire directories to Amazon S3 bucket, using these commands.","breadcrumb":{"@id":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.velaninfo.com\/rs\/techtips\/sync-files-linux-server-amazon-s3-bucket\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.velaninfo.com\/rs\/"},{"@type":"ListItem","position":2,"name":"Tech Tips","item":"https:\/\/www.velaninfo.com\/rs\/techtips\/"},{"@type":"ListItem","position":3,"name":"How can I use Amazon S3 bucket to synchronize files and folders from a local Linux server to?"}]},{"@type":"WebSite","@id":"https:\/\/www.velaninfo.com\/rs\/#website","url":"https:\/\/www.velaninfo.com\/rs\/","name":"Velan","description":"Velaninfo Services India Pvt Ltd","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.velaninfo.com\/rs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/techtips\/1379","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/techtips"}],"about":[{"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/types\/techtips"}],"author":[{"embeddable":true,"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/comments?post=1379"}],"version-history":[{"count":5,"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/techtips\/1379\/revisions"}],"predecessor-version":[{"id":1426,"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/techtips\/1379\/revisions\/1426"}],"wp:attachment":[{"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/media?parent=1379"}],"wp:term":[{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.velaninfo.com\/rs\/wp-json\/wp\/v2\/tags?post=1379"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}