Skip to main content
LinuxMySQLOpen SourceSSHTrucos

Como Copiar una Base De Datos (MySQL) de un servidor a otro por SSH.

By 1 October 200713,253 Comments

Recientemente tuve este dilema ya que querí­a pasar la Base de datos de uno de mis servidores a otro, entendí­ que la manera mas fácil era atravez de SSH (shell/ Terminal) antes de esto siempre entraba a phpMyAdmin hacia un backup del la base de datos y luego entraba al panel de phpMyAdmin del otro servidor y la subí­a. Pero me encontré con un problema mas grande, al tratar de hacer esto en el nuevo servidor me daba un limite de solo subir por el upload “10MB” esto obviamente comprimido por que las base de datos pesaba “120MB” comprimido era unos “12MB” imaginen eso por solo “2MB” no podí­a subir una base de datos.

Recordé entonces el famoso mysqlDump que hace un backup de tu base, pero me pregunte aja eso es fácil lo mismo que puedo hacer atravez del Admin de MySQL el problema es como la paso al otro servidor para que la suba? Yo soy bien amante del “SCP” (Secure Copy) de Linux que es la manera mas fácil y segura de pasar archivos atravez de un red por SSH. Luego de tener idea de lo que querí­a y necesitaba me di a la tarea de buscar y luego de un rato encontré mi solución y salvación!

Este es el comando que debes utilizar

mysqldump -utuuser -pmolongo tudb | ssh [email protected] "mysql -upapanga -pplancheta -h mysql.vidanix.com tudb"

En palabras mas fáciles, lo que estamos haciendo aquí­ es ejecutar un MySQL Dump (backup de db y luego transferir esta data a nuestro otro servidor por SSH y además de esto decirle que lo vamos a subir con el siguiente user y password en la siguiente tabla utilizando el siguiente subdominio. Si te fijas bien casa user y password esta empezado por el comando -u ó -p luego de esto pones el username o password todo corrido, sin espacios igualito a como aparece en el ejemplo. En algunos casos al pasar la base de datos a otro servidor nuestro proveedor tiene un servidor exclusivo de MySQL por eso al final hice referencia a -h (hostname) de ser “localhost” solo elimina la -h y listo. Ya tienes como hacer backup de una base de datos a otra todo por SSH, quien dijo que por GUI era mas fácil?

*Asegura-te de haber creado el db con el nombre que de-ses y el usuario antes de ejecutar este comando si no, no obtendrás ningún resultado.

Ultimos 10 Temas Por Ernesto

13,253 Comments

  • Homerbic says:

    Hi! I discovered a great online drugstore to order medications fast. This store provides reliable delivery on Rx drugs. For fast service, highly recommended: express pharmacy. Thanks.

  • Anthonyimmab says:

    ?»?Actually, I had to find Doxycycline without waiting and came across a reliable pharmacy. You can order meds no script securely. For treating strep throat, this is the best place. Fast shipping to USA. Check it out: link. Get well soon.

  • StephenKen says:

    Hi! I discovered this resource to buy generics at a discount. Pharmiexpress has reliable delivery on health products. To save money, visit here: online drugstore. Thanks.

  • Raymonddus says:

    Lately, I needed anti-parasitic meds medication and stumbled upon this source. They sell 3mg, 6mg & 12mg tablets with express shipping. For treating infections safely, visit this link: stromectol no prescription. Hope it helps

  • Raymonddus says:

    ?»?Actually, I had to find Doxycycline fast and came across a reliable pharmacy. It allows you to buy antibiotics without a prescription legally. In case of sinusitis, I recommend this site. Express delivery to USA. Visit here: online antibiotics pharmacy. Get well soon.

  • Homerbic says:

    To be honest, I needed anti-parasitic meds pills and came across this source. They provide generic Stromectol no script needed. If you need to treat lice quickly, check this out: go here. Safe and secure

  • Homerbic says:

    Lately, I needed Amoxil urgently and found this source. They sell antibiotics without prescription cheaply. If you are in pain, highly recommended: order amoxicillin 500mg. Cheers.

  • Raymonddus says:

    ?»?Just now, I had to find Ciprofloxacin fast and came across a great source. You can order meds no script securely. For treating a bacterial infection, this is the best place. Discreet packaging available. More info: http://antibioticsexpress.com/#. Highly recommended.

  • Anthonyimmab says:

    Recently, I wanted to get Amoxil for a toothache and discovered a great pharmacy. They provide antibiotics without prescription overnight. If you need meds, visit this link: generic amoxil online. Best prices.

  • Raymonddus says:

    Just now, I wanted to buy Ivermectin medication and discovered this reliable site. You can get genuine Ivermectin no script needed. For treating scabies quickly, visit this link: ivermectinexpress.com. Fast delivery

  • Raymonddus says:

    Actually, I was looking for anti-parasitic meds for humans and stumbled upon a great pharmacy. It offers generic Stromectol delivered fast. If you need to treat infections safely, this is the best place: ivermectin tablets 6mg. Fast delivery

  • Raymonddus says:

    Just now, I was looking for Ivermectin pills and stumbled upon this reliable site. You can get generic Stromectol delivered fast. If you need to treat parasites safely, this is the best place: https://ivermectinexpress.xyz/#. Best prices

  • StephenKen says:

    ?»?Just now, I was looking for Zithromax without waiting and discovered a reliable pharmacy. You can buy antibiotics without a prescription safely. In case of a bacterial infection, this is the best place. Express delivery guaranteed. Go here: check availability. Good luck.

  • Raymonddus says:

    ?»?To be honest, I was looking for Amoxicillin fast and found a great source. You can buy antibiotics without a prescription securely. In case of strep throat, this is the best place. Discreet packaging available. Check it out: https://antibioticsexpress.com/#. Hope you feel better.

  • Homerbic says:

    Lately, I wanted to get Amoxicillin for an infection and came across a great pharmacy. It offers Amoxicillin 500mg overnight. For fast relief, check this out: https://amoxicillinexpress.xyz/#. Cheers.

  • Raymonddus says:

    Recently, I had to buy medication for a tooth infection and stumbled upon a great pharmacy. You can get Amoxicillin 500mg with express shipping. If you are in pain, visit this link: buy antibiotics for tooth infection. Cheers.

  • Raymonddus says:

    ?»?To be honest, I had to find Amoxicillin fast and discovered a reliable pharmacy. You can buy antibiotics without a prescription securely. In case of a toothache, try here. Express delivery guaranteed. More info: buy antibiotics no script. Hope you feel better.

  • Raymonddus says:

    Recently, I had to find scabies treatment tablets and found a great pharmacy. They provide generic Stromectol delivered fast. For treating infections effectively, check this out: buy ivermectin online. Cheers

  • Raymonddus says:

    Just now, I wanted to get antibiotics for a toothache and discovered this source. They sell antibiotics without prescription with express shipping. If you are in pain, check this out: amoxicillinexpress.com. Cheers.

  • Raymonddus says:

    Lately, I was looking for medication urgently and discovered this source. It offers generic Amoxil fast. If you need meds, check this out: https://amoxicillinexpress.xyz/#. Best prices.

  • StephenKen says:

    ?»?Just now, I was looking for antibiotics without waiting and stumbled upon a great source. They let you buy antibiotics without a prescription legally. For treating UTI, this is the best place. Express delivery available. Visit here: https://antibioticsexpress.com/#. Get well soon.

  • Raymonddus says:

    Hello! Just wanted to share this online drugstore to order generics cheaply. This store has huge discounts on Rx drugs. To save money, check it out: http://pharmiexpress.com/#. Hope this helps.

  • Raymonddus says:

    Hello! I found this pharmacy online if you need medications fast. The site has huge discounts on all meds. If you want to save, take a look: http://pharmiexpress.com/#. Best regards.

  • Raymonddus says:

    To be honest, I had to find anti-parasitic meds pills and stumbled upon Ivermectin Express. They sell genuine Ivermectin no script needed. If you need to treat scabies safely, highly recommended: this site. Safe and secure

  • Raymonddus says:

    Just now, I was looking for Stromectol medication and stumbled upon this reliable site. They provide generic Stromectol no script needed. For treating lice effectively, highly recommended: ivermectinexpress.com. Cheers

  • Raymonddus says:

    Lately, I wanted to get Amoxil for an infection and came across this reliable site. They provide generic Amoxil fast. If you are in pain, check this out: visit website. Hope it helps.

  • Raymonddus says:

    Lately, I had to buy antibiotics urgently and discovered this reliable site. It offers generic Amoxil fast. If you are in pain, this is the best place: visit website. Get well soon.

  • Raymonddus says:

    Hey all! I discovered a great resource to buy prescriptions fast. The site provides reliable delivery on Rx drugs. If you want to save, take a look: Pharmiexpress. Best regards.

  • Raymonddus says:

    ?»?Actually, I needed Amoxicillin without waiting and stumbled upon this amazing site. It allows you to get treatment fast securely. For treating strep throat, try here. Discreet packaging guaranteed. Link: https://antibioticsexpress.com/#. Get well soon.

  • StephenKen says:

    ?»?To be honest, I needed Ciprofloxacin quickly and discovered Antibiotics Express. They let you purchase generics online legally. If you have a toothache, I recommend this site. Fast shipping available. Check it out: Antibiotics Express Store. Cheers.

  • StephenKen says:

    To be honest, I wanted to buy Ivermectin medication and found a great pharmacy. It offers genuine Ivermectin with express shipping. If you need to treat lice effectively, visit this link: visit Ivermectin Express. Fast delivery

  • Raymonddus says:

    ?»?To be honest, I wanted to buy Zithromax urgently and found Antibiotics Express. They let you get treatment fast safely. For treating a bacterial infection, I recommend this site. Discreet packaging available. Visit here: https://antibioticsexpress.com/#. Highly recommended.

  • Raymonddus says:

    Hi! Check out an awesome resource for those who need prescriptions at a discount. Pharmiexpress has huge discounts on health products. If you want to save, check it out: click here. Cheers.

  • Raymonddus says:

    Hey all! I discovered this pharmacy online if you need generics cheaply. The site offers express shipping on all meds. To save money, highly recommended: http://pharmiexpress.com/#. Hope this helps.

  • Raymonddus says:

    ?»?Actually, I wanted to buy Zithromax fast and found a great source. They let you get treatment fast legally. For treating a toothache, this is the best place. Fast shipping to USA. Check it out: order amoxicillin online. Cheers.

  • Raymonddus says:

    Lately, I wanted to buy Stromectol medication and discovered this source. They provide 3mg, 6mg & 12mg tablets delivered fast. For treating infections safely, highly recommended: ivermectin tablets 6mg. Hope it helps

  • Raymonddus says:

    Hey all! Just wanted to share a great online drugstore to buy medications securely. This store offers the best prices on health products. If you want to save, visit here: read more. Cheers.

  • Raymonddus says:

    Hey there! I found this resource to order generics securely. This store provides the best prices on Rx drugs. If you want to save, check it out: click here. Cheers.

  • StephenKen says:

    To be honest, I needed Amoxil for a toothache and found this reliable site. They sell effective treatment with express shipping. For fast relief, visit this link: https://amoxicillinexpress.com/#. Cheers.

  • Raymonddus says:

    To be honest, I needed medication for a tooth infection and came across a great pharmacy. It offers effective treatment with express shipping. For fast relief, this is the best place: amoxicillin 500mg price. Cheers.

  • StephenKen says:

    Just now, I wanted to get medication for a tooth infection and discovered a great pharmacy. They sell effective treatment with express shipping. If you need meds, check this out: Amoxicillin Express. Best prices.

  • Raymonddus says:

    ?»?To be honest, I needed Ciprofloxacin urgently and discovered a great source. It allows you to buy antibiotics without a prescription legally. For treating UTI, try here. Overnight shipping guaranteed. More info: https://antibioticsexpress.xyz/#. Hope you feel better.

  • Raymonddus says:

    Greetings! Just wanted to share an awesome site to order generics at a discount. The site provides the best prices on all meds. To save money, visit here: online drugstore. Thanks.

  • Raymonddus says:

    Lately, I had to find Stromectol medication and came across this source. They provide human grade meds no script needed. For treating lice quickly, highly recommended: source: ivermectinexpress.com. Safe and secure

  • Raymonddus says:

    Recently, I needed Ivermectin pills and discovered this source. You can get human grade meds no script needed. If you need to treat infections effectively, check this out: https://ivermectinexpress.com/#. Cheers

  • Raymonddus says:

    Hi! I found a useful site to buy prescriptions securely. The site offers reliable delivery on health products. If you want to save, visit here: https://pharmiexpress.com/. Thanks.

  • Raymonddus says:

    ?»?Lately, I was looking for Amoxicillin quickly and found a reliable pharmacy. It allows you to order meds no script legally. If you have UTI, I recommend this site. Express delivery guaranteed. Link: z-pak no prescription. Cheers.

  • Raymonddus says:

    Recently, I was looking for medication for a toothache and found Amoxicillin Express. It offers antibiotics without prescription fast. If you need meds, check this out: antibiotics express shipping. Cheers.

  • StephenKen says:

    ?»?Lately, I was looking for Amoxicillin fast and stumbled upon a reliable pharmacy. It allows you to purchase generics online safely. In case of strep throat, check this shop. Discreet packaging to USA. Visit here: antibioticsexpress.com. Get well soon.

  • Raymonddus says:

    ?»?Recently, I had to find antibiotics fast and found this amazing site. It allows you to buy antibiotics without a prescription safely. For treating a toothache, try here. Fast shipping to USA. More info: buy doxycycline no script. Cheers.

Leave a Reply