{"id":3298,"date":"2010-07-07T05:08:26","date_gmt":"2010-07-07T09:08:26","guid":{"rendered":"http:\/\/g33kinfo.com\/info\/?p=3298"},"modified":"2010-07-07T05:08:26","modified_gmt":"2010-07-07T09:08:26","slug":"migrating-from-rackspace-cloud-to-cpanel","status":"publish","type":"post","link":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/","title":{"rendered":"Migrating from Rackspace Cloud to Cpanel"},"content":{"rendered":"<p>From <a href=\"http:\/\/djlab.com\/2010\/02\/migrating-from-rackspace-cloud-to-cpanel\/\" target=\"_blank\" rel=\"noopener noreferrer\">djlab.com<\/a><\/p>\n<p>Fed up with cloud hosting? You\u2019re not alone. Just recently, I assisted a mass exodus of over 50 mysql\/joomla based sites. After the migration to just a modest dedicated server with Cpanel, MySQL queries improved by 200% on average. Some longer queries and page loading times saw improvement of over 1000%. Additionally, the dedicated server won\u2019t fall on its face when a single script such as a DB backup process consumes \u2018too many\u2019 resources and the Cloud decides to put your whole site in the timeout corner.<\/p>\n<p>Here are some scripts to migrate all your files and db\u2019s from a RackSpace Cloud Sites instance to a Cpanel account quickly and easily. Run this script as the Cpanel user you\u2019re migrating to to avoid ownership issues. If you run this as root, you\u2019ll need to run the ownership repair script referenced below.<\/p>\n<p>In addition to the correct chmod of files and folders (see part 1), you must ensure that all public_html files and folders have the correct (user and group) ownership.  The following Perl code will eliminate nobody\/root ownership.  Place the Perl script into your \/home directory and execute it.<br \/>\n<code><br \/>\n#!\/usr\/bin\/perl -w<\/p>\n<p>my @dirs = grep -d,< *>;<\/p>\n<p>foreach my $user (@dirs) {<br \/>\n`chown -R $user:$user $user\/public_html\/*`;<br \/>\n}<br \/>\n<\/code><\/p>\n<p>I was able to pull from 10-20 sites simultaneously and even .htaccess and other \u2018hidden\u2019 files came across intact.<\/p>\n<p>The progress will be saved in \/home\/cpanel_user\/xferlog.txt so you can monitor it in realtime. You can launch multiple scripts simultaneously to transfer many sites at once.<br \/>\n<code><br \/>\n#!\/bin\/sh<\/p>\n<p>RACKSPACE_CLOUD_FTP_USERNAME=\"rackspace_ftp_user\"<br \/>\nRACKSPACE_CLOUD_FTP_PASSWORD=\"rackspace_ftp_password\"<br \/>\nDOMAIN=\"www.myrackspacedomain.com\"<\/p>\n<p>LOCAL_CPANEL_USERNAME=cpanel_username<\/p>\n<p>wget -rc --level=0  --no-parent --cut-dirs=3 -nH \\<br \/>\n   --directory-prefix=\/home\/$LOCAL_CPANEL_USERNAME\/public_html\/ \\<br \/>\n   --user=\"$RACKSPACE_CLOUD_FTP_USERNAME\" \\<br \/>\n   --ftp-password=\"$RACKSPACE_CLOUD_FTP_PASSWORD\" \\<br \/>\n   ftp:\/\/$RACKSPACE_CLOUD_FTP_IP\/$DOMAIN\/web\/content\/* \\<br \/>\n   -o \/home\/$LOCAL_CPANEL_USERNAME\/xferlog.txt -nv &<br \/>\n<\/code><br \/>\nNow, let\u2019s migrate a mysql database (this can actually be used for migrating from any host, not just Rackspace). Place the file in the Cpanel user\u2019s home folder so it can be run again right before your DNS switch so your records are totally up to date. You can run it as many times as you wish.<br \/>\n<code><br \/>\n#!\/bin\/sh<br \/>\n# Rackspace Cloud to Cpanel DB copy<\/p>\n<p>REMOTE_HOST=\"rackspace_cloud_mysql_ip\"<br \/>\nREMOTE_DB=\"rackspace_cloud_mysql_db\"<br \/>\nREMOTE_USER=\"rackspace_cloud_mysql_user\"<br \/>\nREMOTE_PASS=\"rackspace_cloud_mysql_pass\"<\/p>\n<p>LOCAL_HOST=\"127.0.0.1\"<br \/>\nLOCAL_DB=\"local_cpanel_mysql_db\"<br \/>\nLOCAL_USER=\"local_cpanel_mysql_user\"<br \/>\nLOCAL_PASS=\"local_cpanel_mysql_pass\"<\/p>\n<p>MYSQL=\"$(which mysql)\"<br \/>\nMYSQLDUMP=\"$(which mysqldump)\"<\/p>\n<p>CMD=\"$MYSQLDUMP --lock-tables --add-drop-table \\<br \/>\n   -h'$REMOTE_HOST' -u'$REMOTE_USER' -p'$REMOTE_PASS' $REMOTE_DB \\<br \/>\n   | $MYSQL -h'$LOCAL_HOST' -u'$LOCAL_USER' -p'$LOCAL_PASS' --database $LOCAL_DB\"<\/p>\n<p>echo \"Running: $CMD\"<br \/>\necho<br \/>\neval $CMD<br \/>\n<\/code><\/p>\n","protected":false},"excerpt":{"rendered":"<p>From djlab.com Fed up with cloud hosting? You\u2019re not alone. Just recently, I assisted a mass exodus of over 50 mysql\/joomla based sites. After the migration to just a modest dedicated server with Cpanel, MySQL queries improved by 200% on average. Some longer queries and page loading times saw improvement of over 1000%. Additionally, the&#8230; <\/p>\n<div class=\"read-more navbutton\"><a href=\"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/\">Read More<i class=\"fa fa-angle-double-right\"><\/i><\/a><\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[9],"tags":[],"class_list":["post-3298","post","type-post","status-publish","format-standard","hentry","category-info"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.0 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Migrating from Rackspace Cloud to Cpanel - Linux Shtuff<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Migrating from Rackspace Cloud to Cpanel - Linux Shtuff\" \/>\n<meta property=\"og:description\" content=\"From djlab.com Fed up with cloud hosting? You\u2019re not alone. Just recently, I assisted a mass exodus of over 50 mysql\/joomla based sites. After the migration to just a modest dedicated server with Cpanel, MySQL queries improved by 200% on average. Some longer queries and page loading times saw improvement of over 1000%. Additionally, the... Read More\" \/>\n<meta property=\"og:url\" content=\"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/\" \/>\n<meta property=\"og:site_name\" content=\"Linux Shtuff\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/fb.me\/g33kinf0\" \/>\n<meta property=\"article:author\" content=\"https:\/\/fb.me\/g33kinf0\" \/>\n<meta property=\"article:published_time\" content=\"2010-07-07T09:08:26+00:00\" \/>\n<meta name=\"author\" content=\"g33kadmin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@https:\/\/twitter.com\/drsinger1111\" \/>\n<meta name=\"twitter:site\" content=\"@drsinger1111\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/\"},\"author\":{\"name\":\"g33kadmin\",\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/#\\\/schema\\\/person\\\/c022e4c40b13ea1b678e6f020756f547\"},\"headline\":\"Migrating from Rackspace Cloud to Cpanel\",\"datePublished\":\"2010-07-07T09:08:26+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/\"},\"wordCount\":310,\"publisher\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/#\\\/schema\\\/person\\\/c022e4c40b13ea1b678e6f020756f547\"},\"articleSection\":[\"General Info\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/\",\"url\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/\",\"name\":\"Migrating from Rackspace Cloud to Cpanel - Linux Shtuff\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/#website\"},\"datePublished\":\"2010-07-07T09:08:26+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/migrating-from-rackspace-cloud-to-cpanel\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Migrating from Rackspace Cloud to Cpanel\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/#website\",\"url\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/\",\"name\":\"Linux Shtuff\",\"description\":\"Because I have CRS Syndrome...\",\"publisher\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/#\\\/schema\\\/person\\\/c022e4c40b13ea1b678e6f020756f547\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/#\\\/schema\\\/person\\\/c022e4c40b13ea1b678e6f020756f547\",\"name\":\"g33kadmin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/wp-content\\\/uploads\\\/2022\\\/07\\\/minion-researchA.gif\",\"url\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/wp-content\\\/uploads\\\/2022\\\/07\\\/minion-researchA.gif\",\"contentUrl\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/wp-content\\\/uploads\\\/2022\\\/07\\\/minion-researchA.gif\",\"width\":512,\"height\":512,\"caption\":\"g33kadmin\"},\"logo\":{\"@id\":\"https:\\\/\\\/g33kinfo.com\\\/info\\\/wp-content\\\/uploads\\\/2022\\\/07\\\/minion-researchA.gif\"},\"description\":\"I am a g33k, Linux blogger, developer, student and Tech Writer for Liquidweb.com\\\/kb. My passion for all things tech drives my hunt for all the coolz. I often need a vacation after I get back from vacation....\",\"sameAs\":[\"https:\\\/\\\/thelinuxreport.com\",\"https:\\\/\\\/fb.me\\\/g33kinf0\",\"https:\\\/\\\/x.com\\\/https:\\\/\\\/twitter.com\\\/drsinger1111\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Migrating from Rackspace Cloud to Cpanel - Linux Shtuff","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:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/","og_locale":"en_US","og_type":"article","og_title":"Migrating from Rackspace Cloud to Cpanel - Linux Shtuff","og_description":"From djlab.com Fed up with cloud hosting? You\u2019re not alone. Just recently, I assisted a mass exodus of over 50 mysql\/joomla based sites. After the migration to just a modest dedicated server with Cpanel, MySQL queries improved by 200% on average. Some longer queries and page loading times saw improvement of over 1000%. Additionally, the... Read More","og_url":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/","og_site_name":"Linux Shtuff","article_publisher":"https:\/\/fb.me\/g33kinf0","article_author":"https:\/\/fb.me\/g33kinf0","article_published_time":"2010-07-07T09:08:26+00:00","author":"g33kadmin","twitter_card":"summary_large_image","twitter_creator":"@https:\/\/twitter.com\/drsinger1111","twitter_site":"@drsinger1111","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/#article","isPartOf":{"@id":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/"},"author":{"name":"g33kadmin","@id":"https:\/\/g33kinfo.com\/info\/#\/schema\/person\/c022e4c40b13ea1b678e6f020756f547"},"headline":"Migrating from Rackspace Cloud to Cpanel","datePublished":"2010-07-07T09:08:26+00:00","mainEntityOfPage":{"@id":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/"},"wordCount":310,"publisher":{"@id":"https:\/\/g33kinfo.com\/info\/#\/schema\/person\/c022e4c40b13ea1b678e6f020756f547"},"articleSection":["General Info"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/","url":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/","name":"Migrating from Rackspace Cloud to Cpanel - Linux Shtuff","isPartOf":{"@id":"https:\/\/g33kinfo.com\/info\/#website"},"datePublished":"2010-07-07T09:08:26+00:00","breadcrumb":{"@id":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/g33kinfo.com\/info\/migrating-from-rackspace-cloud-to-cpanel\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/g33kinfo.com\/info\/"},{"@type":"ListItem","position":2,"name":"Migrating from Rackspace Cloud to Cpanel"}]},{"@type":"WebSite","@id":"https:\/\/g33kinfo.com\/info\/#website","url":"https:\/\/g33kinfo.com\/info\/","name":"Linux Shtuff","description":"Because I have CRS Syndrome...","publisher":{"@id":"https:\/\/g33kinfo.com\/info\/#\/schema\/person\/c022e4c40b13ea1b678e6f020756f547"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/g33kinfo.com\/info\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/g33kinfo.com\/info\/#\/schema\/person\/c022e4c40b13ea1b678e6f020756f547","name":"g33kadmin","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/g33kinfo.com\/info\/wp-content\/uploads\/2022\/07\/minion-researchA.gif","url":"https:\/\/g33kinfo.com\/info\/wp-content\/uploads\/2022\/07\/minion-researchA.gif","contentUrl":"https:\/\/g33kinfo.com\/info\/wp-content\/uploads\/2022\/07\/minion-researchA.gif","width":512,"height":512,"caption":"g33kadmin"},"logo":{"@id":"https:\/\/g33kinfo.com\/info\/wp-content\/uploads\/2022\/07\/minion-researchA.gif"},"description":"I am a g33k, Linux blogger, developer, student and Tech Writer for Liquidweb.com\/kb. My passion for all things tech drives my hunt for all the coolz. I often need a vacation after I get back from vacation....","sameAs":["https:\/\/thelinuxreport.com","https:\/\/fb.me\/g33kinf0","https:\/\/x.com\/https:\/\/twitter.com\/drsinger1111"]}]}},"_links":{"self":[{"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/posts\/3298","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/comments?post=3298"}],"version-history":[{"count":0,"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/posts\/3298\/revisions"}],"wp:attachment":[{"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/media?parent=3298"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/categories?post=3298"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/g33kinfo.com\/info\/wp-json\/wp\/v2\/tags?post=3298"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}