{"id":3057,"date":"2017-01-28T10:10:04","date_gmt":"2017-01-28T10:10:04","guid":{"rendered":"https:\/\/www.milesweb.com\/hosting-faqs\/?p=3057"},"modified":"2023-02-06T12:14:59","modified_gmt":"2023-02-06T06:44:59","slug":"learn-backup-export-database-ssh","status":"publish","type":"post","link":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/","title":{"rendered":"Learn how to Backup or Export the Database from SSH"},"content":{"rendered":"<p>Today we will see how you can export the&nbsp;database from SSH. This can be useful in situations like moving your site, as it can help you to export the entire database, or need to upgrade a website.<\/p>\n<h3>Generate a Database Backup:<\/h3>\n<p><strong>Step 1:<\/strong> Connect to your server via SSH.<\/p>\n<p><strong>Step 2:<\/strong> In the command line enter the following code:<\/p>\n<pre class=\"plain:false plain-toggle:false copy:false popup:false lang:default decode:true\">mysqldump -u dbusername -p databasename &gt; nameofdbbackup.sql<\/pre>\n<p><strong>Make sure you replace:<\/strong><\/p>\n<p>dbusername = with the database username for the database you want to export.<\/p>\n<p>databasename = with the name of the database you want to export.<\/p>\n<p>nameofdbbackup = enter a name for the exported database.<\/p>\n<p><strong>Step 3:<\/strong> Once you Press the Enter key, it will ask you for your password. Provide your password and press Enter key again, the exporting process will begin. It may take some time to complete the process, depending on the size of your database. The SSH client will take you to the new line when this process is completed and the database will now be available for download in your home directory.<\/p>\n<p><strong>Related: <a href=\"https:\/\/www.milesweb.in\/hosting-faqs\/how-to-connect-your-server-by-ssh\/\">How To Login to Your Server By SSH?<\/a><\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today we will see how you can export the&nbsp;database from SSH. This can be useful in situations like moving your site, as it can help you to export the entire database, or need to upgrade a website. Generate a Database Backup: Step 1: Connect to your server via SSH. Step 2: In the command line [&hellip;]<\/p>\n","protected":false},"author":9,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[41],"tags":[],"class_list":["post-3057","post","type-post","status-publish","format-standard","placeholder-for-hentry","category-howtos"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.1.1 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Learn how to Backup or Export the Database from SSH<\/title>\n<meta name=\"description\" content=\"You can easily import\/export your database from SSHM using mysqldump -u dbusername -p databasename &gt; nameofdbbackup.sql command\" \/>\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.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Learn how to Backup or Export the Database from SSH\" \/>\n<meta property=\"og:description\" content=\"You can easily import\/export your database from SSHM using mysqldump -u dbusername -p databasename &gt; nameofdbbackup.sql command\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\" \/>\n<meta property=\"og:site_name\" content=\"Web Hosting FAQs by MilesWeb\" \/>\n<meta property=\"article:published_time\" content=\"2017-01-28T10:10:04+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-02-06T06:44:59+00:00\" \/>\n<meta name=\"author\" content=\"Pravin Ganore\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Pravin Ganore\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\"},\"author\":{\"name\":\"Pravin Ganore\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/9f6aad74f4af57132ba60117b4ab3ea6\"},\"headline\":\"Learn how to Backup or Export the Database from SSH\",\"datePublished\":\"2017-01-28T10:10:04+00:00\",\"dateModified\":\"2023-02-06T06:44:59+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\"},\"wordCount\":184,\"commentCount\":0,\"articleSection\":[\"How-Tos\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\",\"url\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\",\"name\":\"Learn how to Backup or Export the Database from SSH\",\"isPartOf\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#website\"},\"datePublished\":\"2017-01-28T10:10:04+00:00\",\"dateModified\":\"2023-02-06T06:44:59+00:00\",\"author\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/9f6aad74f4af57132ba60117b4ab3ea6\"},\"description\":\"You can easily import\/export your database from SSHM using mysqldump -u dbusername -p databasename > nameofdbbackup.sql command\",\"breadcrumb\":{\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.milesweb.in\/hosting-faqs\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Learn how to Backup or Export the Database from SSH\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#website\",\"url\":\"https:\/\/www.milesweb.in\/hosting-faqs\/\",\"name\":\"Web Hosting FAQs by MilesWeb\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.milesweb.in\/hosting-faqs\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/9f6aad74f4af57132ba60117b4ab3ea6\",\"name\":\"Pravin Ganore\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/911c7c72d64a0d0e0b6c8f1be7e7421c413395f2f2403d0adb26ae16b4130572?s=96&d=blank&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/911c7c72d64a0d0e0b6c8f1be7e7421c413395f2f2403d0adb26ae16b4130572?s=96&d=blank&r=g\",\"caption\":\"Pravin Ganore\"},\"description\":\"Pravin is Journalist Specializing in Blogging, Social Networking and Community Management. As a constant learner, he is always aiming towards new ideas and greater knowledge. When he is not doing research, reading, or writing for blogs, you can find him hanging around social media sites.\",\"sameAs\":[\"https:\/\/www.milesweb.com\"],\"url\":\"https:\/\/www.milesweb.in\/hosting-faqs\/author\/pravin\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Learn how to Backup or Export the Database from SSH","description":"You can easily import\/export your database from SSHM using mysqldump -u dbusername -p databasename > nameofdbbackup.sql command","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.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/","og_locale":"en_US","og_type":"article","og_title":"Learn how to Backup or Export the Database from SSH","og_description":"You can easily import\/export your database from SSHM using mysqldump -u dbusername -p databasename > nameofdbbackup.sql command","og_url":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/","og_site_name":"Web Hosting FAQs by MilesWeb","article_published_time":"2017-01-28T10:10:04+00:00","article_modified_time":"2023-02-06T06:44:59+00:00","author":"Pravin Ganore","twitter_misc":{"Written by":"Pravin Ganore","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#article","isPartOf":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/"},"author":{"name":"Pravin Ganore","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/9f6aad74f4af57132ba60117b4ab3ea6"},"headline":"Learn how to Backup or Export the Database from SSH","datePublished":"2017-01-28T10:10:04+00:00","dateModified":"2023-02-06T06:44:59+00:00","mainEntityOfPage":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/"},"wordCount":184,"commentCount":0,"articleSection":["How-Tos"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/","url":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/","name":"Learn how to Backup or Export the Database from SSH","isPartOf":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#website"},"datePublished":"2017-01-28T10:10:04+00:00","dateModified":"2023-02-06T06:44:59+00:00","author":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/9f6aad74f4af57132ba60117b4ab3ea6"},"description":"You can easily import\/export your database from SSHM using mysqldump -u dbusername -p databasename > nameofdbbackup.sql command","breadcrumb":{"@id":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/learn-backup-export-database-ssh\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.milesweb.in\/hosting-faqs\/"},{"@type":"ListItem","position":2,"name":"Learn how to Backup or Export the Database from SSH"}]},{"@type":"WebSite","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#website","url":"https:\/\/www.milesweb.in\/hosting-faqs\/","name":"Web Hosting FAQs by MilesWeb","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.milesweb.in\/hosting-faqs\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/9f6aad74f4af57132ba60117b4ab3ea6","name":"Pravin Ganore","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.milesweb.in\/hosting-faqs\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/911c7c72d64a0d0e0b6c8f1be7e7421c413395f2f2403d0adb26ae16b4130572?s=96&d=blank&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/911c7c72d64a0d0e0b6c8f1be7e7421c413395f2f2403d0adb26ae16b4130572?s=96&d=blank&r=g","caption":"Pravin Ganore"},"description":"Pravin is Journalist Specializing in Blogging, Social Networking and Community Management. As a constant learner, he is always aiming towards new ideas and greater knowledge. When he is not doing research, reading, or writing for blogs, you can find him hanging around social media sites.","sameAs":["https:\/\/www.milesweb.com"],"url":"https:\/\/www.milesweb.in\/hosting-faqs\/author\/pravin\/"}]}},"_links":{"self":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts\/3057","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/users\/9"}],"replies":[{"embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/comments?post=3057"}],"version-history":[{"count":4,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts\/3057\/revisions"}],"predecessor-version":[{"id":17453,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/posts\/3057\/revisions\/17453"}],"wp:attachment":[{"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/media?parent=3057"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/categories?post=3057"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.milesweb.in\/hosting-faqs\/wp-json\/wp\/v2\/tags?post=3057"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}