migrate 1.9 openv container

Discussion in 'Proxmox VE: Installation and configuration' started by bread-baker, Oct 1, 2011.

  1. bread-baker

    bread-baker Member

    Joined:
    Mar 6, 2010
    Messages:
    432
    Likes Received:
    0
    ti did this and it almost works except the .mount file:

    our hostname is fbc158 so,

    set a link so .conf and .mount get to correct place:
    Code:
    ln -s /etc/pve/nodes/fbc158/openvz /etc/vz/conf
    
    restore the backup
    Code:
    root@fbc158 /var/lib/vz/fbc6bkp # vzrestore vzdump-openvz-101-2011_09_24-23_00_02.tar 3401
    ...tar: write error
    INFO: restore openvz backup 'vzdump-openvz-101-2011_09_24-23_00_02.tar' successful
    
    I'm not sure what the 'tar: write error' was . i assume it is related to not being able to set execute mode on the .mount file, but I'll check into it further tomorrow by setting -v on the tar command ?


    try to run it
    Code:
    vzctl start 3401
    
    Starting container ...
    Initializing quota ...
    Error exec /etc/pve/openvz/3401.mount: Permission denied
    Error executing mount script /etc/pve/openvz/3401.mount
    
    but it will start without the .mount file
    Code:
    mv 3401.mount 3401.mount-
    
    vzctl start 3401
    
    
    Starting container ...
    Container is mounted
    Adding IP address(es): 10.100.100.207
    Setting CPU units: 50000
    Setting CPUs: 4
    Container start in progress..
    

    So next thing to figure out is how to set execute permission on the .mount :
    Code:
    -rw-r----- 1 root www-data  365 Sep 30 22:51 3401.mount
    root@fbc158 /etc/pve/nodes/fbc158/openvz # chmod +x 3401.mount
    chmod: changing permissions of `3401.mount': Function not implemented
    
    or how are bind mounts done in 2.0 ?
     
    #1 bread-baker, Oct 1, 2011
    Last edited: Oct 1, 2011
  2. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    16,431
    Likes Received:
    298
    It is not possible to set exec permission on the cluster fs - I guess we need to tweak the
    vzctl binary/scrips a bit so that it does not require that.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  3. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    16,431
    Likes Received:
    298
    I have uploaded a fix which automatically sets the exec permission for openvz action scripts. Please can you test if you can now start the container?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. bread-baker

    bread-baker Member

    Joined:
    Mar 6, 2010
    Messages:
    432
    Likes Received:
    0
    all set now:
    Code:
    root@homenet-fbc158 /bkup/fbc6bkp # vzrestore vzdump-openvz-169-2011_09_24-23_14_53.tar 3169
    INFO: restore openvz backup 'vzdump-openvz-169-2011_09_24-23_14_53.tar' using ID 3169
    INFO: extracting archive 'vzdump-openvz-169-2011_09_24-23_14_53.tar'
    tar: write error
    INFO: Total bytes read: 488222720 (466MiB, 44MiB/s)
    INFO: extracting configuration to '/etc/vz/conf/3169.conf'
    INFO: restore openvz backup 'vzdump-openvz-169-2011_09_24-23_14_53.tar' successful
    root@homenet-fbc158 /bkup/fbc6bkp # ll /etc/vz/conf/3169*
    -rw-r----- 1 root www-data 1664 Oct  3 06:24 /etc/vz/conf/3169.conf
    -rwxr----- 1 root www-data  310 Oct  3 06:24 /etc/vz/conf/3169.mount
    root@homenet-fbc158 /bkup/fbc6bkp # vi /etc/vz/conf/3169.mount
    root@homenet-fbc158 /bkup/fbc6bkp # vzctl start 3169
    Starting container ...
    Initializing quota ...
    Container is mounted
    Setting CPU units: 1000
    Setting CPUs: 1
    Configure veth devices: veth169.0 veth169.1 
    Adding interface veth169.0 to bridge vmbr0 on CT0 for CT3169
    Adding interface veth169.1 to bridge vmbr1 on CT0 for CT3169
    Container start in progress...
    
    
    there is still : tar: write error

    if there is something I can do to to help track that down, let me know.
     
  5. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    16,431
    Likes Received:
    298
    Sure, I know - but its harmless. I will fix that later when I adopt vzdump for V2.0.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  6. mrballcb

    mrballcb New Member

    Joined:
    Sep 30, 2011
    Messages:
    24
    Likes Received:
    0
  7. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    16,431
    Likes Received:
    298
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  8. mrballcb

    mrballcb New Member

    Joined:
    Sep 30, 2011
    Messages:
    24
    Likes Received:
    0
    So I must use git://git.proxmox.com/git/ for the path to each sub module. Many thanks!
    ...
    Looking in the vzdump repo, I don't see the above mentioned changes, and there are no other remote branches, so I'll assume you have a private area to exchange scripts/diffs with other devs. Until I figure the locations out, I'll just manually rsync things and put them where they need to go.

    Again thanks :)
     
  9. bread-baker

    bread-baker Member

    Joined:
    Mar 6, 2010
    Messages:
    432
    Likes Received:
    0
    to fix this I think just doing
    Code:
    aptitude update
    aptitude safe-upgrade
    
    works.
     
  10. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    16,431
    Likes Received:
    298
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  11. mrballcb

    mrballcb New Member

    Joined:
    Sep 30, 2011
    Messages:
    24
    Likes Received:
    0
    Awesome, thanks once again. Two notes:
    1. I had to force autoconf1.10 because 1.9 (1.96) barfed on @MKDIR_P@
    2. I had to manually install lintian for final step of make to succeed

    Other than that, it built properly (along with dev prereqs libqb and corosync). Looking forward to the rest of the improvements!
     
  12. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    16,431
    Likes Received:
    298
    what package caused that error?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  13. mrballcb

    mrballcb New Member

    Joined:
    Sep 30, 2011
    Messages:
    24
    Likes Received:
    0
    On a 2.0 Beta install, I install build-essential, which pulled in a bunch of packages. Then I installed all of the suggested packages (which included "autoconf") except for a couple of doc packages that apt-get couldn't find. Once done with that, I installed git and cloned pve-cluster, corosync-pve, and libqb. I attempted to build pve-cluster and libqb, but both required some additional dev packages so I installed them. I then built pve-cluster and libqb by running make and installed the resulting dev packages.

    Then I tried to build pve-cluster and it failed at the very end, complaining about not being able to find @MKDIR_P@ in the path. Obviously, something wasn't expanding right from the Makefile.in. Whether it is something I did wrong or out of sequence or if it's a bug, I am not 100% sure. A quick google led me to believe that versions of autoconf 1.9 and below had issues with mkdir detection, so I installed autoconf1.10; make clean && make then ran successfully.

    I apologize, but I have already blown away this 2.0 installation and installed 1.9, but that had some issues migrating from our 1.8 machine, so I blew THAT away and installed 1.8, and now live migration works again. I'm willing to try just about anything, so let me know.
     
  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice