Layers of Layers
Have you tried adding an abstraction layer?
  • Cheat Sheets
    • Linux Commands
    • Linux Network
    • Markdown
    • Regular Expressions
    • Shell Scripting
    • SSL
    • VI
  • To Do
    • Blinkendecke
    • DIY Electronics Construction Kit from Duplo
    • Kobo Hacking
  • $FOO
  • Linux
  • Make
  • misc
  • Pretty
  • Software
  • Things

directly write suse studio image to host using rescue system

Sat 18 May 2013
By Wonko

I recently rented a Virtual Root Server. I was in need of a fixed IPv4
adress since my Home Internet went IPv6 only ( Carrier side NAT sucks ).
So I went with a cheap one from active-servers. Unfortunately they
don't have SLES as a OS option. They do give you the ability to Install
from an Image. But the process involves sending them an Image and their
admins installing it. Not quick enough for me ;-)

What they do have is the ability to boot your vServer into a rescue
system. In this case the Debian rescue system but that does't really
matter as long the rescue system has:

  • Internet Access 
  • (GNU) wget installed
  • (GNU) tar instelled
After that the process to install an Image from SUSE Studio is quite simple:
Go to susestudio.com and create your Image. Then Build it (USB sick/hard disk image). No need to publish (share) it, but why not?
Then copy the Download URL (Red Circle in Image below) from the Build page.
[![][]][]
Now boot your vServer into the rescue system. This differs a bit for different Hosters, but normally you log in to some virtual Console. Reboot and when you see the boot loader menu you select the rescue system. Sometimes you have to be quick as the menu is only displayed for a few seconds before the default is booted. When the rescue system is up test the internet connectivity:
ping google.com

btw. susestudio.com does not answer to pings. Don't be alarmed.

Then figure out which device is your Hard Disk

fdisk -lDisk /dev/vda: 53.7 GB, 53687091200 bytes255 heads, 63 sectors/track, 6527 cylinders, total 104857600 sectorsUnits = sectors of 1 * 512 = 512 bytesSector size (logical/physical): 512 bytes / 512 bytesI/O size (minimum/optimal): 512 bytes / 512 bytesDisk identifier: 0x9602c78f

My system only has one disk ( /dev/vda ). If you have more be SURE to
select the right one. the Imaging process will overwrite this disk
COMPLETELY.
Now the hard part is over the following will in one command download
your susestudio image and write it to the disk:

wget -O- http://url from above | tar xvzO > disk from above

For my System it looked like this:

wget -O- http://http://susestudio.com/download/12345/imagename.x86_64-0.0.2.oem.tar.gz | tar xvzO > /dev/vda

What it all means:

  • wget -O- http://xyz/path/file.tar.gz

-O The documents will not be written to the appropriate files, but
all will be concatenated together and written to file.  If - is used
as file, documents will be printed to standard output so "-O-" sends
everything to stdout.

  • | tar xvzO

| The output of wget is piped into tar

x Extract the content
v Be Verbose (for us Humans)
z The Archive is gz compressed so uncompress it with gzip
O Extract files to standard output (stdout)

  • > /dev/vda

The output of tar is written to the /dev/vda Device

Have fun!

[![][]]: http://4.bp.blogspot.com/-8GKz8hoQWoY/UZdTw_Nh2oI/AAAAAAAADC4/DudvZ86P2go/s1600/susestudio.png

Tags

  • Graphics
  • bash
  • Javascript
  • Database
  • Powersave
  • Cyanogen
  • synology
  • Ideas
  • Android
  • Security
  • Internal
  • Blog
  • Books
  • Network
  • Wood
  • Wallpapers
  • RasPi
  • Storage
  • Serious
  • KDE
  • Cookies
  • Suse
  • Themes
  • Ubuntu
  • Kids
  • Photos
  • Hardware
  • Java
  • Git
  • Pelican
  • Games
  • Virtualization
  • Eclipse

Links

  • CCC-FFM
  • Cat Content
design by jide