# Modifying IVS Init.gz for testing purposes

## What

With the IVS, target devices uses init.gz as the boot image over the network. For troubleshooting purposes, you may want/need to make a change to this image (for instance to change a driver file or to make some workaround).

## When/Why

This is not an activity most FileWave administrators will do but is being documented for cases where it is needed. Usually you will do this with support to test something.

## How

<div class="highlighter-context page view" data-inline-comments-target="true" data-testid="page-content-only" id="bkmrk-ssh-into-the-ivs-bac"><div class="_19pkidpf _2hwx1wug _otyridpf _18u01wug _1bsb1osq"><div class="wiki-content css-1ugufav e5xcnr80" data-test-appearance="full-width" data-testid="pageContentRendererTestId" id="bkmrk-ssh-into-the-ivs-bac-1"><div class="renderer-overrides"><div class="ak-renderer-wrapper is-full-width cc-1jke4yk"><div class="cc-5rreh"><div class="ak-renderer-document">1. SSH into the IVS
2. Backup the original init.gz so you can restore it if need be (original is in /imaging/netboot/kernel/init.gz)
3. Create a temp working directory like /tmp/working, and make sure you cd into that temp directory
4. Expand the init.gz boot image, as: `zcat /imaging/netboot/kernel/init.gz | cpio -i -d`
5. You should now find that the boot image is expanded in you working directory
6. Make your changes - such as edit filewave/bootup.py for instance, replace a driver file, add another utility, or modify a version of partclone
7. Make sure everything is owned by root before the next step. When I do my changes on macOS the directory is owned by my username so I have to chown -R root to the temp folder before the next step or some things like SSH won't work.
8. Once changes are made, now we’ll want to rebuild init.gz incorporating our changes (again make sure you are in your working directory): `find . | cpio -o -H newc | gzip -9 > /imaging/netboot/kernel/init.gz`
9. Enable an imaging association and PXE boot a system and it will use this updated filesystem when it boots

</div></div></div></div></div><div class="_kqswstnw _lcxvglyw _c71l12am" data-testid="comment-container" id="bkmrk-"></div></div></div><div class="_18s81h6l _1bsb1osq _p12fn7od" data-ssr-placeholder-replace="-JIDW:4y5Pz:qz-Pe:RPrst-0" data-testid="view-page-labels-container" data-vc="view-page-labels-container" id="bkmrk--1"></div>## Related Content

- [Network Imaging / IVS](https://kb.filewave.com/books/network-imaging-ivs "Network Imaging / IVS")