| 1 | So here's my first attempt and poking around the orbit infrastructure. The goal clone a machine. |
| 2 | My candidate is orbit-pc2, one of the user service machines. It's going to be migrated to a dell. |
| 3 | |
| 4 | Step 1 -- Some kind of pxe thing happens. |
| 5 | |
| 6 | step 2 -- Orbit-pc2 boots the image ...winlab.img |
| 7 | |
| 8 | once at the console, the resting place of the image was mounted. |
| 9 | |
| 10 | step 3 -- mount -o nolock repository2:/export/orbit/image/tmp /mnt |
| 11 | |
| 12 | We need the nolock option because of some NFS bug. |
| 13 | Repository2:yadayada is the NFS destination (where the image will be dumped) |
| 14 | /mnt is my mount point (could be anything really) |
| 15 | |
| 16 | So now that I have some place to put the image file, I can create it with the imagezip utility (should live in /bin on the image). |
| 17 | |
| 18 | step 4 -- imagezip /dev/hda - > /mnt/orbit-pc1... |
| 19 | |
| 20 | imagezip is part of the firsbee suite, it is dumb and will just start dumping to std out. To use it you need to redirect that to a file or some such place. (unix pipe + ssh?) |
| 21 | |
| 22 | /dev/hda is my target (where I want the image to come from) |
| 23 | the target is followed by a - for some reason I don't know. |
| 24 | |
| 25 | > is the unix redirect |
| 26 | |
| 27 | and /mnt/orbit-pc1... is my file name (note that I put it on the nfs mounted directory, since the image has no place / space to hold any thing. And even if it did, how would you get at it?) |
| 28 | |
| 29 | Assuming that all went well, you should have a file sitting somewhere on some box, that you can get at later. |
| 30 | |
| 31 | Now the fun begins. We have and image, it would be usefull to put it somewhere. |
| 32 | |
| 33 | Since frisbee is a client / server type service, I'll need a place for the server to run. This place should have access to my freshly generated image. Mogwai (?!$#@) is our candidate. Once ssh'd to mogwai, I'll scp my file from repository2, and place it in /tmp. (an exercise left to the reader) |
| 34 | |
| 35 | step 5 frisbeed -p 5050 -m 10.0.250.221 /tmp/orbit-pc2... |
| 36 | |
| 37 | frisbeed lives in /usr/sbin. Note the d for daemon. |
| 38 | -p 5050 is the port number for the service (I just picked one at random) |
| 39 | -m 10.0.250.221 is the address of the client. This could be some kind of multi cast address, but to keep things simple I figued I'd just do one machine for now. |
| 40 | /tmp/orbit-pc2 is my image file, freshly copied. |
| 41 | |
| 42 | step 6 frisbee -p 5050 -m 10.0.101.10 -i 10.0.250.221 /dev/hda |
| 43 | frisbee should live in /bin somewhere on the winlab.img that we booted into. |
| 44 | -p 5050 is the randomly choosen port number |
| 45 | -m 10.0.101.10 is mogwai's ip (my service host) |
| 46 | -i 10.0.250.221 is the interface I'm trying to use to get my image from. No idea why I need this, but if I don't put it there, it complains about not being able to resolve the host name. ("gethostbyname: Unknown host") |
| 47 | /dev/hda is where I'm going to dump my image. (Hope you don't have anything there you need, it's going to be gone in a miniute). |
| 48 | |
| 49 | Start the service first, start the client second. Assming that it worked you should see a progress indicator. |
| 50 | |