Renombrar CTID OpenVZ "on the fly"

Enviado por el 09/04/2012

Renombrar CTID OpenVZ "on the fly"

Ojo al crear máquinas virtuales con OpenVZ y asignar un 'ctid' menor que 100, pues están reservados para el sistema.He creado dos máquinas en "enjuto" , el servidor que tengo "rulando" en casa con OpenVZ y al realizar un backup con vzdump de una de las máquinas devolvía en siguiente error:root@enjuto:/backups# vzdump --suspend --dumpdir /backups --snapshot 2ERROR: got reserved VM ID '2'Supongo que en la actualidad OpenVZ tendrá un modo más rápido(en realidad lo es) que teclear 5 líneas para cambiar ctid's, pero lo que he leído en este foro ha funcionado al 100% .enjuto# vzctl chkpnt 1 --dumpfile /tmp/Dump.1enjuto# mv /etc/vz/conf/1.conf /etc/vz/conf/100.confenjuto# mv /vz/private/1 /vz/private/100enjuto# mv /vz/root/1 /vz/root/100enjuto# vzctl restore 100 --dumpfile /tmp/Dump.1Ahora sí funciona el comando vzdump sin problemas:root@enjuto:/backups# vzdump --dumpdir /backups --snapshot 100unable to find command 'lvcreate'root@enjuto:/backups# vzdump 100INFO: starting new backup job: vzdump 100INFO: Starting Backup of VM 100 (openvz)INFO: CTID 100 exist mounted runningINFO: status = CTID 100 exist mounted runningINFO: mode failure - unable to detect lvm volume groupINFO: trying 'suspend' mode insteadINFO: backup mode: suspendINFO: bandwidth limit: 10240 KB/sINFO: starting first sync /var/lib/vz/private/100/ to /var/lib/vz/dump/vzdump-openvz-100-2012_04_09-11_38_50.tmpINFO: Number of files: 24892INFO: Number of files transferred: 19140INFO: Total file size: 456167369 bytesINFO: Total transferred file size: 455391436 bytesINFO: Literal data: 455391436 bytesINFO: Matched data: 0 bytesINFO: File list size: 573708INFO: File list generation time: 0.001 secondsINFO: File list transfer time: 0.000 secondsINFO: Total bytes sent: 456866413INFO: Total bytes received: 398372INFO: sent 456866413 bytes received 398372 bytes 4595625.98 bytes/secINFO: total size is 456167369 speedup is 1.00INFO: first sync finished (99 seconds)INFO: suspend vmINFO: Setting up checkpoint...INFO: suspend...INFO: get context...INFO: Checkpointing completed succesfullyINFO: starting final sync /var/lib/vz/private/100/ to /var/lib/vz/dump/vzdump-openvz-100-2012_04_09-11_38_50.tmpINFO: Number of files: 24892INFO: Number of files transferred: 0INFO: Total file size: 456167369 bytesINFO: Total transferred file size: 0 bytesINFO: Literal data: 0 bytesINFO: Matched data: 0 bytesINFO: File list size: 573708INFO: File list generation time: 0.001 secondsINFO: File list transfer time: 0.000 secondsINFO: Total bytes sent: 575625INFO: Total bytes received: 1916INFO: sent 575625 bytes received 1916 bytes 231016.40 bytes/secINFO: total size is 456167369 speedup is 789.84INFO: final sync finished (2 seconds)INFO: resume vmINFO: Resuming...INFO: vm is online again after 5 secondsINFO: Total bytes written: 473118720 (452MiB, 9.3MiB/s)INFO: tar: Exiting with failure status due to previous errorsINFO: archive file size: 451MBINFO: Finished Backup of VM 100 (00:02:40)INFO: Backup job finished successfuly

Añadir nuevo comentario

Esta pregunta es para comprobar si usted es un visitante humano y prevenir envíos de spam automatizado.

8 + 0 =
Resuelva este simple problema matemático y escriba la solución; por ejemplo: Para 1+3, escriba 4.