Family, Work, Life

Howto boot ISO images via grub2 with ubuntu

February 6th, 2010 Ansi

Moin

I am using Ubuntu “Daily builds” for some time inside Suns VirtualBox. Unfortunately the daily builds are not longer booting inside VirtualBox for more then 2 weeks now. Christian told me about a new feature of Grub2. You can boot ISO images directly from your hard disk without burning them on CD or USB. Awesome feature and I had to try it today. Here is the description on how to do it with Ubuntu 9.10.

First I am using this tiny script to update all daily builds with the zsync tool. It transfers only the changed parts of the ISO so you and the Ubuntu teams save a lot of traffic.

zsync http://cdimages.ubuntu.com/daily-live/current/lucid-desktop-i386.iso.zsync
cd kubuntu
zsync http://cdimages.ubuntu.com/kubuntu/daily-live/current/lucid-desktop-i386.iso.zsync
cd ../netbook
zsync http://cdimages.ubuntu.com/ubuntu-netbook/daily-live/current/lucid-netbook-i386.iso.zsync
cd ../xubunutu
zsync http://cdimages.ubuntu.com/xubuntu/daily-live/current/lucid-desktop-i386.iso.zsync
cd ..
rm `find ./ -name "*.zs-old" `

This script keeps all my daily builds up to date.

Next Step is to enable the grub menu. In Ubuntu it can be done in “/etc/default/grub“. Change the following lines

GRUB_HIDDEN_TIMEOUT=10
GRUB_HIDDEN_TIMEOUT_QUIET=false

With this change you will see a 10 seconds count down when booting up. With the shift-key you get access to the grub boot menu. Next is to add the ISO images to the grub menu. Change to the “/etc/grub.d” dir.

Here you can find the grub menu entries and configuration files. Add your ISO images starting with 50 here. For example my entry for the normal Ubuntu ISO image (50_ubuntu) looks like this:

echo "Adding $(egrep menu[e]ntry $0 | cut -d'"' -f2)" >&2
 cat << EOF
menuentry "Ubuntu 10.04 Daily Build" {
       loopback loop (hd0,3)/ansi/software_and_config/ISOs/ubuntu/lucid-desktop-i386.iso
       linux (loop)/casper/vmlinuz boot=casper iso-scan/filename=/ansi/software_and_config/ISOs/ubuntu/lucid-desktop-i386.iso file=(loop)/preseed/ubuntu.seed quiet splash bootkbd=sg --
       initrd (loop)/casper/initrd.lz
}

My ISO files are stored on sda3 under /ansi/software_and_config/ISOs/ubuntu/. In order to change it for your needs there are 3 elements to change. The loopback line contains your hard disk in grub style (hdx,y  x=0->sda x=1->sdb aso) and the path. The third element to change is in the linux line. Store this file as “50_ubuntu” in “/etc/grub.d“, make it executable with “chmod a+x 50_ubuntu” and activate the changes with “ubdate-grub“. After a reboot you should be able to activate the grub menu with the shift-key and select the new entry. Have fun.

I found some pages on this topic but the description there was not working for me so I changed it. But take a look on your own:

  • Share/Bookmark

Chrome extentions

December 20th, 2009 Ansi

Moin

I just run through several Chrome Extensions and here is my list of extensions I can recommend. Please write some comments if you have additional  recommendations.

  • Share/Bookmark

Server update to Ubuntu Server 9.04

April 26th, 2009 Ansi

Moin

My blog will be offline on sunday for some time because I will reinstall the server with new HD and Ubuntu 9.04.

  • Share/Bookmark

Howto Setup Ubuntu postfix to send email with 1und1 as smarthost

July 24th, 2008 Ansi

Installing Postfix with

apt-get install postfix

or choose dpkg-reconfigure postfix when you allready installed postfix before.

The configuration working for me is “satelite”.

  1. System Mail Name: your maildomain name (interblc.com) not the dns name of your server.
  2. SMTP relay host:smtp.1und1.de
  3. Root and Postmaster mail recipient: your user account or external email address
  4. Other destinations to accept mail for: your servername, localhost.localdomain,localhost
  5. Force synchronous updates on mail queue: If you have ext3 oder reiser NO otherwise better YES
  6. Local Networks: 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
  7. Procmail for local delivery: Yes
  8. Mailbox size limit: 0
  9. Local address extension character: +
  10. Internet Protocol:All

Edit /etc/postfix/main.cf and add these lines at the end:

smtp_sasl_auth_enable = yes
smtp_sasl_security_options = noanonymous
smtp_sasl_password_maps = hash:/etc/postfix/sasl_password

Create /etc/postfox/sasl_password with one line:

smtp.1und1.de MAILACCOUNT_at_1und1:PASSWD

Create and db file from this passwd file with

postmap /etc/postfix/sasl_password

Restart postfix with:

/etc/init.d/postfix restart
Now it should work. Give it a try with

date | mail -s “testing” regen@wetter.de

and watch the logfile with

tail -f /var/log/mail.log

  • Share/Bookmark