Skip to contentSkip to conversation

Auto start script

Qemu-devel Ignacio Geli 1 participant 1 message Dec 7, 2012

lore
Share & tools
lore
#0 lore raw

Hi all...
Sorry if im not posting in the proper list, but i have a solaris
2.5.1 up and running under qemu virtualization, the thing is that every time i boot it i need to enter "boot disk0" on the console to get it up and if I close that console i goes down.

I write a few lines to make it automatic:

/usr/local/sbin/boot-sun.sh
----------------------------------
#!/usr/bin/expect
set timeout -1
log_user 0
spawn /usr/local/sbin/start-sun.sh
expect "ok"
send "boot disk0 \r"
expect eof
----------------------------------

/usr/local/sbin/start-sun.sh:
----------------------------------
sudo /opt/qemu/sparc-softmmu/qemu-system-sparc -M SS-5 -startdate 2009-12-13 -m 256 -bios /opt/solaris/ss5.bin -nographic -hda /srv/discos-solaris/solaris.disk1 -hdb /srv/discos-solaris/solaris.disk2 -hdc /srv/discos-solaris/solaris.disk3 -device lance -net nic -net tap,ifname=tap0
----------------------------------

It did work some times, but now is not working. Im no expert and do not know how to debub the script since i cant get output from expect command. Maybe someone write something similar to make it boot automatically. any help will be apreciated Regards
Ignacio

Signature · 5 lines
ITECNIS SRL <http:/www.itecnis.com>
        Simplicity is the ultimate sophistication

        Ignacio Geli
        Implementación y Soporte