SystemImager Falko-Way

Discussion in 'HOWTO-Related Questions' started by pureblood, Mar 20, 2006.

  1. pureblood

    pureblood New Member

    Hey everybody, this is my first one over here, so upfront:
    great site so far and man I really spent a lot of hours already trying out the most of the how tos, not that they are so fdifficult but most of all they very interesting and many of them available;-).

    To the point:
    I tried to figure out http://www.howtoforge.org/dedicated_server_backup_restore_systemimager
    but it fails with

    Code:
    @ERROR: Unknown module 'scripts'
    rsync error: error starting client-server protocol (code 5) at main.c(1171)
    ERROR: rsync of the master script failed!
    
    So I took a look at the script itself and found this line

    Code:
    rsync $image_server::scripts/$image_name.master /tmp
    to be honest I have no clue what thi ":scripts" should be and why there is a ".master" behind the image variable

    One would think the command should be s.t. like
    "rsync -r $image_server:/var/lib/systemimager/images/$image_name /tmp"

    So I guess the error is somewhere there ..

    Would be amazing if some of you guys could gimme a hint ;-)
    thanks in advance
     
  2. falko

    falko Super Moderator Howtoforge Staff

    Please post the output of
    Code:
    ls -la /var/lib/systemimager
    on the image server.
     
  3. pureblood

    pureblood New Member

    XANDROSII:~# ls -la /var/lib/systemimager
    insgesamt 1
    drwxr-xr-x 5 root root 128 2006-03-20 08:39 .
    drwxr-xr-x 32 root root 856 2006-03-20 08:39 ..
    drwxr-xr-x 3 root root 192 2006-03-20 08:48 images
    drwxr-xr-x 3 root root 96 2006-03-20 09:03 overrides
    drwxr-xr-x 4 root root 144 2006-03-20 09:03 scripts
     
  4. pureblood

    pureblood New Member

    ok this hints me to edit the ::scripts with my real directory which is /var/lib/scripts

    I edited your script and now i get this
    Code:
    --13:43:51--  http://www.falkotimme.com/howtos/dedicated_server_backup_restore_systemimager/functions
               => `functions'
    Resolving www.falkotimme.com... 81.169.182.36
    Connecting to www.falkotimme.com[81.169.182.36]:80... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 34,564 [text/plain]
    
    100%[=================================================================================>] 34,564        --.--K/s
    
    13:43:51 (3.63 MB/s) - `functions' saved [34564/34564]
    
    mv: cannot move `functions' to `/etc/init.d/functions': No such file or directory
    /tmp/my_image.master: line 13: /etc/init.d/functions: No such file or directory
    
    btw I also use a strato server but the rescue system does not seem to be busy box .. this maybe a problem right?

    ok next thing I now just made an mkdir /etc/init.d/ so your skript can work

    but next failure is this

    Code:
    
    --13:58:51--  http://www.falkotimme.com/howtos/dedicated_server_backup_restore_systemimager/functions
               => `functions'
    Resolving www.falkotimme.com... 81.169.182.36
    Connecting to www.falkotimme.com[81.169.182.36]:80... connected.
    HTTP request sent, awaiting response... 200 OK
    Length: 34,564 [text/plain]
    
    100%[=================================================================================>] 34,564        --.--K/s
    
    13:58:51 (9.15 MB/s) - `functions' saved [34564/34564]
    
    
    get_arch
    Partitioning /dev/sda...
    Old partition table for /dev/sda:
    Error: Error opening /dev/sda: No such device or address
    parted -s -- /dev/sda mklabel msdos || shellout
    Error: Error opening /dev/sda: No such device or address
    Killing off running processes.
    kill: usage: kill [-s sigspec | -n signum | -sigspec] [pid | job]... or kill -l [sigspec]
    udp-receiver: no process killed
    rsync: no process killed
    
    write_variables
    \s \r \m\ \n
    LFS based rescue system
    
    ok this is caused because my image originated from an sda install and the server only has a hda
    so I just changed the sda`s with hda`s

    but now I ended up here
    Code:
    : bad interpreter: No such file or directory
    
    I think this is caused by this
    Code:
    ::${IMAGENAME}/
    part in the my_image.master
    and I am sure it fails for the same reason like the script failed in the first place above where I replaced
    ::scripts with my real directory which is /var/lib/scripts

    but I dont know why this doesnt work out of the box ?
    what do the two colons mean?
     
    Last edited: Mar 20, 2006
  5. falko

    falko Super Moderator Howtoforge Staff

    I guess you have edited the file on Windows and then transferred it back to your server? Make sure you save the file with Unix linebreaks, not Windows linebreaks.
     
  6. pureblood

    pureblood New Member

    hmm ok so i started it all over again, I did edit the files in windoze, because the f.... up vi on the rescue system didnt let me to.


    but the root of all evil still seems to be the following notation
    Code:
    rsync $image_server::scripts/$image_name.master /tmp
    could you please explain to me why there are two colons right one after another?
    Code:
    ::
    maybe this is just damn easy but I ve never encountered such a notation I am just familiar with
    Code:
    rsync $image_server:/scripts/$image_name.master /tmp
    Is this some kind of shortened way for a path?

    And man, thanks so far for your quick replies and your kind help.
    It is great to have such support in ones learning process


    ADDED:
    I asked around a bit and looked at the rsync man pages and there I found that the
    Code:
    rsync HOST::SRC DEST 
    and that this requires a rsync daemon....

    so I guess for your script to work a rsync daemon must be running?
     
    Last edited: Mar 21, 2006
  7. falko

    falko Super Moderator Howtoforge Staff

    Yes, you must have rsync on your rescue system.
     
  8. pureblood

    pureblood New Member

    I found it ;-)

    on the the image server runs a xandros system and for whatever reason, the rsync manager included in systemimager-server was not startet...

    now everything works fine just right out of the box without anything needed to be edited
    JUST it ends with a few errors ;-:)
    sent 109 bytes received 66 bytes 116.67 bytes/sec
    total size is 0 speedup is 0.00




    Code:
    Probing devices to guess BIOS drives. This may take a long time.
    df: Warning: cannot read table of mounted filesystems
    df: Warning: cannot read table of mounted filesystems
    Could not find device for /boot: Not found or not a block device.
    Probing devices to guess BIOS drives. This may take a long time.
    Probing devices to guess BIOS drives. This may take a long time.
    /tmp/my_image.master: line 278: [INTERFACE0]: command not found
    /tmp/my_image.master: line 279: DEVICE: command not found
    /tmp/my_image.master: line 280: EOL: command not found
    /tmp/my_image.master: line 289: run_post_install_scripts: command not found
    umount /a/proc || shellout
    umount /a/ || shellout
    Is there anything I can do to fix this??
    So near...
     
    Last edited: Mar 22, 2006
  9. falko

    falko Super Moderator Howtoforge Staff

    I don't know where the df warnings come from, however, they are warnings, not errors.
    Have you tested if the image works afterwards?
     
  10. pureblood

    pureblood New Member

    no sorry the server didnt came online after a reboot ;-(
     

Share This Page