Skip to content

Discoverd is a ramdisk to get some informations from a server

Notifications You must be signed in to change notification settings

uoi-io/discoverd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 

Repository files navigation

Discoverd

Discoverd image is only useful to collect informations of an asset and learn howto build a ramdisk.

  • Interfaces name, speed, status, mac, etc...
  • Processor, memory
  • Virtual machine, physical server

Build the image

Before bulding the image, few packages are required:

$ sudo apt-get install curl debootstrap

Build the discoverd image is easy, just run the mkdiscoverd.sh script. Before running this script be sure that debootstrap (this packages exists on Red Hat distributions) and sudo packages are installed.

$ git clone git@github.com:uoi-io/discoverd.git
$ cd discoverd
$ ./mkdiscoverd.sh

When the build is done, a directory named generated has been created the discoverd.img.gz ramdisk and the vmlinuz associated to this ramdisk.

Extract the image

For some reasons you might want extract the image to add scripts, files, etc... To avoid a full rebuild just follow the steps below.

$ gunzip discoverd.img.gz
$ mkdir discoverd ; cd discoverd
$ cpio -idv < ../discoverd.img
$ echo "> UOI DISCOVERD IMAGE <" > etc/motd
$ mkdir opt/folder1

Then rebuild the image with the changes made.

$ find . | cpio -H newc -o | gzip -v -c > ../discoverd.img.gz

The compression is done by gzip but it can be done by another compression tools:

  • bzip2
  • lzma
  • xz

Releases

No releases published

Packages

No packages published

Languages