OpenVZ

From PostgreSQL_wiki
Revision as of 20:52, 14 January 2011 by Martin (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

debootstrap --arch amd64 squeeze /var/lib/vz/private/ http://mirror.webhuis.nl:3142/debian

 540  vzctl set test --applyconfig vps.basic --save
 541  mount /dev/dev-xen/test /var/lib/vz/private/test/
 542  vzctl set test --applyconfig vps.basic --save
 543  cd private/
 544  mv test/ 101
 545  mount /dev/dev-xen/test /var/lib/vz/private/101/
 546  vzctl set 101 --applyconfig vps.basic --save
 547  debootstrap --arch amd64 squeeze /var/lib/vz/private/101 http://mirror.webhuis.nl:3142/debian
 548  vzctl set 101 --applyconfig vps.basic --save
 549  apt-get install vzpkg vzyum vzrpm43-python vzrpm44-python vzctl-lib
 550  vzctl set 101 --applyconfig webhuis-basis.conf --save
 551  vzctl set 101 --applyconfig webhuis-basis --save
 552  sh -c 'echo "OSTEMPLATE=debian-6.0" >> /etc/vz/conf/101.conf'
 553  ping 10.68.71.190
 554  ping 10.68.71.189
 555  vzctl set 101 --ipadd 10.68.71.190 --save
 556  vzctl set 101 --nameserver 10.68.71.187 --save
 557  vzctl start 101
 558  umount /var/lib/vz/private/101/
 559  umount /var/lib/vz/private/101/
 560  vzctl start 101
 561  mount /dev/dev-xen/test /var/lib/vz/private/101/
 562  cd 101/
 563  tar --numeric-owner -zcf /var/lib/vz/template/cache/debian-6.0-amd64-minimal.tar.gz .
 564  vzctl create 102 --ostemplate debian-6.0-amd64-minimal
 565  vzctl start 102
 566  vzctl exec 102  ps ax
 567  vzctl stop 102
 568  vzctl exec 102  ps ax
 569  vzctl destroy 102
 570  vzctl start 101
 571  vzctl exec 101  ps ax
 572  vzctl enter 101
 573  vzctl set 101 --ipdel all --save
 574  vi /var/lib/vz/private/101/etc/resolv.conf 
 575  rm -f  /var/lib/vz/private/101/etc/hostname 
 576  vzctl stop 101
 577  history | grep tar
 578  tar --numeric-owner -zcf /var/lib/vz/template/cache/debian-6.0-amd64-minimal.tar.gz .
 579  man cp
 580  man rsync
 581  vzctl start 101
 582  vzctl enter 101
 583  vzctl enter 101
 584  vzctl stop 101
 585  ls -al ../../template/
 586  ls -al ../../template/cache/
 587  tar --numeric-owner -zcf /var/lib/vz/template/cache/debian-6.0-amd64-minimal.tar.gz .
 588  ls -al ../../template/cache/
 589  cd ..
 590  history | grep create
 591  vzctl create 1234567890 --ostemplate debian-6.0-amd64-minimal
 592  vzctl start 1234567890
 593  vzctl exec 1234567890 ps ax
 594  vzctl enter 1234567890
 595  vzctl stop 1234567890
 596  vzctl destroy 1234567890
 597  rm /etc/vz/conf/1234567890.conf.destroyed 
 598  ls -al /etc/vz/conf/
 599  rm /etc/vz/conf/102.conf.destroyed
 600  history | grep vzct
 601  vzctl exec 101  ps ax



Terug naar: Webhuis bouwstenen