• Recent
    • Unsolved
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Register
    • Login

    Modify init.gz

    Scheduled Pinned Locked Moved
    General
    2
    3
    1.7k
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • E
      electronico_nc
      last edited by

      Brief resume :
      Lenovos don’t have a standard 512B MBR. (/dev/sda1 starts @ 2048)
      So no integrated FOG function can clone an HD (as MBR is replaced by standard Win7 one).
      PXE boot can’t be used as first boot device neither as the chainloader (booting from local HD) is broken (probably because of this long MBR too).
      Way found (thanks to Tom Elliott) is to debug-upload a well configured /dev/sda2 to FOG, and to debug-deploy it to destination HD using partimage.
      Tom has kindly (and fast) built an init.gz that has all the keymaps, so debug mode is now easy for a non-QWERTY keyboard.
      As I would like to keep the original MBR (which allows to boot from /dev/sda3 : Recovery partition by pressing F11 key at startup), I have to use debug mode.
      So I need to add a small restore_pc1sda2.sh script in /root that mounts FOG_SERVER:/images and starts the restore process of ONLY /dev/sda2
      FOG Wiki is telling to gunzip init.gz, but I’m told :
      [QUOTE]gzip: init.gz: not in gzip format[/QUOTE]Could someone please assist on how to decompress init.gz and recompress it ?
      Thanks (once more) for your time.
      Nicolas

      1 Reply Last reply Reply Quote 0
      • Tom ElliottT
        Tom Elliott
        last edited by

        My init gz is compressed in lzma to make it smaller. However if you decompress it you want be able to decompress as lzma. To extract run this command.
        [code]lzma -d -c /tftpboot/fog/images/init.gz > /tftpboot/fog/images/init[/code]

        Mount the init file as per normal instruction. Add your script. Unmount the file and recompress as gz. To recompress run this command.
        [code]gzip -9 < /tftpboot/fog/images/init > /tftpboot/fog/images/init.gz[/code]

        Please help us build the FOG community with everyone involved. It's not just about coding - way more we need people to test things, update documentation and most importantly work on uniting the community of people enjoying and working on FOG! Get in contact with me (chat bubble in the top right corner) if you want to join in.

        Web GUI issue? Please check apache error (debian/ubuntu: /var/log/apache2/error.log, centos/fedora/rhel: /var/log/httpd/error_log) and php-fpm log (/var/log/php*-fpm.log)

        Please support FOG if you like it: https://wiki.fogproject.org/wiki/index.php/Support_FOG

        1 Reply Last reply Reply Quote 0
        • E
          electronico_nc
          last edited by

          Thank Tom !
          worked as expected 🙂
          Nicolas
          PS : sorry for the delay, motorbike fall has taken me away from computers these days.

          1 Reply Last reply Reply Quote 0
          • 1 / 1
          • First post
            Last post

          183

          Online

          12.0k

          Users

          17.3k

          Topics

          155.2k

          Posts
          Copyright © 2012-2024 FOG Project