Reply
Apprentice
Posts: 16,075
Registered: ‎2007-09-24

Sparc platform development envrionment using Qemu

You can now run a fully emulated Sparc platform development environment on any system capable of running Qemu.

Download: readynas_compile_environment.qcow.gz

# wget -q http://www.readynas.com/download/development/readynas_compile_environment.qcow.gz
# gunzip readynas_compile_environment.qcow.gz
# qemu-system-sparc -hda readynas_compile_environment.qcow -nographic

Default root password for this package is 'a'. The compile environment is all there for most common stuff.
# qemu-system-sparc -hda readynas_compile_environment.qcow -nographic
(qemu)
Nvram id QEMU_BIOS, version 1, machine id 0x80
CPUs: 1
invalid nvram partition length
nvram error detected, zapping pram
Welcome to OpenBIOS v1.0RC1 built on May 31 2007 23:50
Type 'help' for detailed information

[sparc] Booting file 'disk' with parameters ''
Not a bootable ELF image
Not a Linux kernel image
Loading a.out image...
Loaded 7680 bytes
entry point is 0x4000
Jumping to entry point...
SILO Version 1.4.13
boot:
Uncompressing image...
Loaded kernel version 2.6.18
Loading initial ramdisk (3210249 bytes at 0x3000000 phys, 0x60000000 virt)...
PROMLIB: obio_ranges 1
Booting Linux...
PROMLIB: Sun Boot Prom Version 3 Revision 2
Linux version 2.6.18-6-sparc32 (Debian 2.6.18.dfsg.1-23etch1) (dannf@debian.org) (gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)) #1 Fri Dec 12 16:29:52 UTC 2008
ARCH: SUN4M
TYPE: SPARCstation 5
Ethernet address: 52:54:0:12:34:56
Boot time fixup v1.6. 4/Mar/98 Jakub Jelinek (jj@ultra.linux.cz). Patching kernel for srmmu[Fujitsu TurboSparc]/iommu
PROM: Built device tree with 21266 bytes of memory.
Power off control detected.
Built 1 zonelists. Total pages: 31179
Kernel command line: root=/dev/sda2 ro
PID hash table entries: 512 (order: 9, 2048 bytes)
start_kernel(): bug: interrupts were enabled early
Console: colour dummy device 80x25
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 121200k/130232k available (1640k kernel code, 8880k reserved, 404k data, 136k init, 0k highmem)
Mount-cache hash table entries: 512
checking if image is initramfs... it is
Freeing initrd memory: 3135k freed
NET: Registered protocol family 16
IOMMU: impl 0 vers 4 table 0xf3200000[262144 B] map [65536 b]
sbus0: Clock 21.1250 MHz
dma0: Revision 2
dma1: Revision 2
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 4096 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 4096 bind 2048)
TCP reno registered
ioremap: done with statics, switching to malloc
apc: power management initialized
VFS: Disk quotas dquot_6.5.1
Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
Initializing Cryptographic API
io scheduler noop registered
io scheduler anticipatory registered
io scheduler deadline registered
io scheduler cfq registered (default)
Console: switching to colour frame buffer device 128x48
/iommu@0,10000000/sbus@0,10001000/SUNW,tcx@3,800000: TCX at 0:50800000, 24-bit depth
ffd54490: ttyS0 at MMIO 0x71100000 (irq = 44) is a zs
Console: ttyS0 (SunZilog zs0)
ffd54490: ttyS1 at MMIO 0x71100004 (irq = 44) is a zs
ffd5466c: Keyboard at MMIO 71000000 (irq = 44) is a zs
ffd5466c: Mouse at MMIO 71000004 (irq = 44) is a zs
Floppy drive(s): fd0 is 1.44M
FDC 0 is a S82078B
RAMDISK driver initialized: 16 RAM disks of 8192K size 1024 blocksize
rtc_sun_init: Registered Mostek RTC driver.
mice: PS/2 mouse device common for all mice
TCP bic registered
NET: Registered protocol family 1
NET: Registered protocol family 17
Freeing unused kernel memory: 136k freed
input: Sun Type 5 keyboard as /class/input/input0
Loading, please wait...
Begin: Loading essential drivers... ...
SCSI subsystem initialized
esp0: IRQ 36 SCSI ID 7 Clk 40MHz CCYC=25000 CCF=8 TOut 167 NCR53C90(esp100)
scsi0 : Sparc ESP100 (NCR53C90)
Vendor: QEMU Model: QEMU HARDDISK Rev: 0.8.
Type: Direct-Access ANSI SCSI revision: 03
Vendor: QEMU Model: QEMU CD-ROM Rev: 0.8.
Type: CD-ROM ANSI SCSI revision: 03
Done.
Begin: Running /scripts/init-premount ...
SCSI device sda: 20971521 512-byte hdwr sectors (10737 MB)
sda: Write Protect is off
SCSI device sda: drive cache: write back
SCSI device sda: 20971521 512-byte hdwr sectors (10737 MB)
sda: Write Protect is off
SCSI device sda: drive cache: write back
sda: sda1 sda2 sda3 sda4
sd 0:0:0:0: Attached scsi disk sda
Done.
Begin: Mounting root file system... ...
Begin: Running /scripts/local-top ...
Done.
Begin: Running /scripts/local-premount ...
Done.
kjournald starting. Commit interval 5 seconds
EXT3-fs: mounted filesystem with ordered data mode.
Begin: Running /scripts/local-bottom ...
Done.
Done.
Begin: Running /scripts/init-bottom ...
Done.
INIT: version 2.84 booting
INIT: Entering runlevel: 3
EXT3 FS on sda2, internal journal
sunlance.c:v2.02 8/24/03 Miguel de Icaza (miguel@nuclecu.unam.mx)
SunLance: using auto-carrier-detection.
eth0: LANCE 52:54:00:12:34:56
Starting LVM...done.
Checking filesystems...done
Setting kernel variables.
Mounting filesystems:
nothing was mounted
Initializing urandom... done.
Starting portmap...done.
Starting log daemons: syslogd klogd.
Starting atd...done
Starting inetd...done
Starting cupsd...done
Starting cron...done

debian-sparc login: root
Password:
Linux debian-sparc 2.6.18-6-sparc32 #1 Fri Dec 12 16:29:52 UTC 2008 sparc GNU/Linux
debian-sparc:~#
(I'm actually running this directly on a ReadyNAS Pro)
Jedi Council Alumni | See my profile About page for my ReadyNAS history (2004-2012) |
https://twitter.com/chirpah/status/852389882764840960/photo/1
Aspirant
Posts: 27
Registered: ‎2010-11-08

Re: Sparc platform development envrionment using Qemu

I am trying to use this on Ubuntu so I can compile the full_audit.so for samba but every time I try to start I get the error:

qemu-system-sparc -hda readynas_compile_environment.qcow -nographic
/usr/share/qemu/openbios-sparc32: No such file or directory
qemu: could not load prom '/usr/share/qemu/openbios-sparc32'


I have looked everywhere trying to find a resolution and I can't find anything. I did look within the /usr/share/qemu and it has symlinks to a folder called openbios from all of the files begining with openbios- (like openbios-sparc32) but the actual folders they are linking to do not exist. I have done an update and reinstall of qemu but it is the same, I also removed and installed from a debian package, still the same thing.

Thanks in advance,
SK
Aspirant
Posts: 27
Registered: ‎2010-11-08

Re: Sparc platform development envrionment using Qemu

I fixed that error now, I had to install the openbios package. But now that I have it installed here is what happens:

Nvram id QEMU_BIOS, version 3, machine id 0x80
CPUs: 1 x FMI,MB86904
Welcome to OpenBIOS v1.0RC1 built on jan 24 2008 01:56
Type 'help' for detailed information

[sparc] Booting file 'disk' with parameters ''
Not a bootable ELF image
Not a Linux kernel image
Loading a.out image...
Loaded 7680 bytes
entry point is 0x4000
Jumping to entry point...
SILO Version 1.4.13
boot:
Uncompressing image...
Loaded kernel version 2.6.18
Loading initial ramdisk (3210249 bytes at 0x3000000 phys, 0x60000000 virt)...
PROMLIB: obio_ranges 1
Booting Linux...
PROMLIB: Sun Boot Prom Version 3 Revision 2
Linux version 2.6.18-6-sparc32 (Debian 2.6.18.dfsg.1-23etch1) (dannf@debian.org) (gcc version 4.1.2 20061115 (prerelease) (Debian 4.1.1-21)) #1 Fri Dec 12 16:29:52 UTC 2008
ARCH: SUN4M
TYPE: SPARCstation 5
Ethernet address: 52:54:0:12:34:56
Boot time fixup v1.6. 4/Mar/98 Jakub Jelinek (jj@ultra.linux.cz). Patching kernel for srmmu[Fujitsu TurboSparc]/iommu
PROM: Built device tree with 21328 bytes of memory.
Power off control detected.
Built 1 zonelists. Total pages: 31179
Kernel command line: root=/dev/sda2 ro
PID hash table entries: 512 (order: 9, 2048 bytes)
start_kernel(): bug: interrupts were enabled early
Console: colour dummy device 80x25
Dentry cache hash table entries: 16384 (order: 4, 65536 bytes)
Inode-cache hash table entries: 8192 (order: 3, 32768 bytes)
Memory: 121200k/130232k available (1640k kernel code, 8880k reserved, 404k data, 136k init, 0k highmem)
Mount-cache hash table entries: 512
checking if image is initramfs... it is
Freeing initrd memory: 3135k freed
NET: Registered protocol family 16
IOMMU: impl 0 vers 5 table 0xf3200000[262144 B] map [65536 b]
sbus0: Clock 21.1250 MHz
dma0: Revision 2
dma1: Revision 0
NET: Registered protocol family 2
IP route cache hash table entries: 1024 (order: 0, 4096 bytes)
TCP established hash table entries: 4096 (order: 2, 16384 bytes)
TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
TCP: Hash tables configured (established 4096 bind 2048)
TCP reno registered
ioremap: done with statics, switching to malloc
apc: power management initialized
VFS: Disk quotas dquot_6.5.1
Dquot-cache hash table entries: 1024 (order 0, 4096 bytes)
Initializing Cryptographic API
io scheduler noop registered
io scheduler anticipatory registered
io scheduler deadline registered
io scheduler cfq registered (default)
Console: switching to colour frame buffer device 128x48
/iommu@0,10000000/sbus@0,10001000/SUNW,tcx@3,800000: TCX at 0:50800000, 8-bit only
ffd54454: ttyS0 at MMIO 0x71100000 (irq = 44) is a zs
Console: ttyS0 (SunZilog zs0)
ffd54454: ttyS1 at MMIO 0x71100004 (irq = 44) is a zs
ffd54630: Keyboard at MMIO 71000000 (irq = 44) is a zs
ffd54630: Mouse at MMIO 71000004 (irq = 44) is a zs
Floppy drive(s): fd0 is 1.44M
Unable to handle kernel paging request at virtual address 7a000000
tsk->{mm,active_mm}->context = ffffffff
tsk->{mm,active_mm}->pgd = fc000000
\|/ ____ \|/
"@'/ ,. \`@"
/_| \__/ |_\
\__U_/
swapper(0): Oops [#1]
PSR: 044010c5 PC: f001c770 NPC: f001c774 Y: 00000000 Not tainted
PC: <apc_swift_idle+0x8/0x1c>
%G: 00000010 f022a000 fd013000 f05b0000 04101fe5 00000040 f000e000 00000001
%O: 00000019 00000032 00000010 00000008 f00d941c 00000001 f000fec8 f0014a40
RPC: <cpu_idle+0xc0/0xfc>
%L: 00000190 f7f2d580 f01d49d0 f01d4aac f022373c 00000066 00000009 00000000
%I: f01d57c0 00000000 00000010 00000008 f00d941c f0235000 f000ff30 f0205f64
Caller[f0205f64]: _etext+0x68754/0x697e8
Caller[f0205790]: _etext+0x67f80/0x697e8
Caller[ffd07fec]: 0xffd07ff4
Instruction DUMP: 90102000 81c3e008 90102000 <033c08a8> c4006220 c2088000 82106001 c2288000 81c3e008
Kernel panic - not syncing: Attempted to kill the idle task!
<0>Press Stop-A (L1-A) to return to the boot prom
no cont in shutdown!


Any ideas?

Thanks again,
SK
Aspirant
Posts: 104
Registered: ‎2007-04-21

Re: Sparc platform development envrionment using Qemu

Like the idea!

I have tried booting this within QEMU (v0.90) on Windows (XP) and a couple of things cropped up:

* with --nographic, it complains it can't open monitor device 'stdio' and doesn't start.
* without --nographic, it states that Hard Disk 0 is not a bootable disk.

Here's the command line (-L . required to point it to the bios file):

qemu.exe -hda readynas_compile_environment.qcow -L .

Any thoughts? Basically am in Windows at the moment can't reboot this second into Ubuntu to test it there.
Apprentice
Posts: 16,075
Registered: ‎2007-09-24

Re: Sparc platform development envrionment using Qemu

Only tested in Linux so far, we haven't tried Windows Qemu.

Scott, try this openbios-sparc32 build instead of the package: http://qemu-forum.ipi.fi/viewtopic.php?p=11539#p11539
Jedi Council Alumni | See my profile About page for my ReadyNAS history (2004-2012) |
https://twitter.com/chirpah/status/852389882764840960/photo/1
Aspirant
Posts: 104
Registered: ‎2007-04-21

Re: Sparc platform development envrionment using Qemu

Don't worry - got it working on Windows in the end. Needed the openbios-sparc32 compiled for Windows.

You can get it from the QEMU website under the Windows download page - look for the SPARC binary.
Aspirant
Posts: 8
Registered: ‎2009-08-20

Re: Sparc platform development envrionment using Qemu

is there in project the same for x86 ?
Apprentice
Posts: 16,075
Registered: ‎2007-09-24

Re: Sparc platform development envrionment using Qemu

1. Debian Live CD
2. apt-get install build-essential

Smiley Tongue
Jedi Council Alumni | See my profile About page for my ReadyNAS history (2004-2012) |
https://twitter.com/chirpah/status/852389882764840960/photo/1
Aspirant
Posts: 8
Registered: ‎2009-08-20

Re: Sparc platform development envrionment using Qemu

shame on me........; I thought it was more specific and not so generic Smiley Happy

thx
Aspirant
Posts: 76
Registered: ‎2009-06-10

Re: Sparc platform development envrionment using Qemu

Hello all,
I'm trying to install an efficient compile environment on a Windows XP Box.
What works so far :
- QEmu sparc (from binary package)
- the "readynas_compile_environment.qcow" boots OK
- I can login on the guestOS as root
- Outgoing network from guest works OK on the overall
What doesn't work :
- I can't ping host OS from guest BUT a can ping the computer nextdoor on the physical net
- I tried "-redir" option on qemu command line to get guest OS sftp access to no avail.

I must say my XP box has got weird network settings (3 static IP on the same NIC, vmware virtual network adapters, IPv6 tunneling adapter), it could be the reason why guest OS cannot ping it.

If anyone had a solution that would allow me to put/get files/folder/archives on the guest, I would very much appreciate. Accessing guest file system from host would be prefered as it would be a bit more user friendly.
HW:

  • ReadyNAS Duo (RND2000) - 1GB RAM

  • 1 x WD Caviar Green 2TB (WD20EARS) OK

  • No disk in second bay

SW:

  • RAIDiator 4.1.7 (SMB+AFP+NFS) + NZBGET 0.6.0

  • RAIDar 4.1.5 (Mac OS X 10.6.6)

Aspirant
Posts: 76
Registered: ‎2009-06-10

Re: Sparc platform development envrionment using Qemu

I answer myself :
smbclient from the guest does the trick if using gateway address.

My problem now is that "sarge" is quite old in the debian tree.
I can't find an apt mirror ...
HW:

  • ReadyNAS Duo (RND2000) - 1GB RAM

  • 1 x WD Caviar Green 2TB (WD20EARS) OK

  • No disk in second bay

SW:

  • RAIDiator 4.1.7 (SMB+AFP+NFS) + NZBGET 0.6.0

  • RAIDar 4.1.5 (Mac OS X 10.6.6)

hno Aspirant
Aspirant
Posts: 110
Registered: ‎2008-09-02

Re: Sparc platform development envrionment using Qemu

archive.debian.org
Aspirant
Posts: 76
Registered: ‎2009-06-10

Re: Sparc platform development envrionment using Qemu

hno wrote:
archive.debian.org


Well, thanx hno.
It does help but the packages I need are not there (vlc source).
I changed strategy and grabed source archives.
I'll start a new thread as I have some difficulties.
HW:

  • ReadyNAS Duo (RND2000) - 1GB RAM

  • 1 x WD Caviar Green 2TB (WD20EARS) OK

  • No disk in second bay

SW:

  • RAIDiator 4.1.7 (SMB+AFP+NFS) + NZBGET 0.6.0

  • RAIDar 4.1.5 (Mac OS X 10.6.6)

Highlighted
Aspirant
Posts: 4
Registered: ‎2010-03-05

Re: Sparc platform development envrionment using Qemu

I'm having trouble running the qemu-Image on my Mac with "Q", the Mac qemu-Port (http://www.kju-app.org/).

It starts, but I can't log in (there is no prompt for the username).

Does anyone know how I can fix this? Perhaps it is like on some *nix-Systems that I have to switch to another console or something, how do I do this?

Aspirant
Posts: 76
Registered: ‎2009-06-10

Re: Sparc platform development envrionment using Qemu

derJan wrote:
Perhaps it is like on some *nix-Systems that I have to switch to another console or something, how do I do this?


Indeed, switch to console 3 (ctrl+alt+3 on the PC, should be Ctrl+Opt+3 on the Mac).
You'll be able to log in.
HW:

  • ReadyNAS Duo (RND2000) - 1GB RAM

  • 1 x WD Caviar Green 2TB (WD20EARS) OK

  • No disk in second bay

SW:

  • RAIDiator 4.1.7 (SMB+AFP+NFS) + NZBGET 0.6.0

  • RAIDar 4.1.5 (Mac OS X 10.6.6)

Aspirant
Posts: 4
Registered: ‎2010-03-05

Re: Sparc platform development envrionment using Qemu

Thanks a lot, that did the trick!
Aspirant
Posts: 32
Registered: ‎2009-04-28

Re: Sparc platform development envrionment using Qemu

I'm not having any luck getting qemu-system-sparc to start the bios on Ubuntu, it just hangs. qemu (x86) starts just fine though. I downloaded the openbios-sparc32 from the link in this thread. Any help linux users? This is with both qemu v0.12.3 and v.0.11

It hangs both with and without -nographic. qemu loads just a black screen if I don't specify -nographic.
Prodigy
Posts: 3,146
Registered: ‎2008-01-15

Re: Sparc platform development envrionment using Qemu

I found that it will only work with qemu 0.9.x but not with any newer versions of qemu.

-Stefan
Follow me on Twitter, Facebook, Google+ or visit my add-on web site
Aspirant
Posts: 9
Registered: ‎2009-12-05

Re: Sparc platform development envrionment using Qemu

I am now running this image with Qemu 0.12.5 on Ubuntu 10.4 Lucid Lynx, after some work.

The qemu-packages in Lucid have had the openbios-files removed and instead suggest
you install the package openbios-sparc, which has no installation candidate - I get the
impression that's because it has build-issues, but you are welcome to try and build
the source package for openbios-sparc, it is in the universe repository. (I tried, and failed)

The openbios link earlier in this thread did not work for me either, qemu just froze.

The solution is to compile qemu from source http://wiki.qemu.org/Download
It will install the openbios-files missing from the packaged version and you are all set.
Aspirant
Posts: 302
Registered: ‎2010-05-29

Re: Sparc platform development envrionment using Qemu

if it's of use to anyone, openSUSE 11.3 x64 works out-of-the-box with qemu via 'zypper install qemu' (qemu 0.12.5), and the guide both in this post and the developing addons guide.
no tinkering required which makes me happy Smiley Very Happy
Unofficial Guides:
nzbget 2.2 auto unrar | files
Transmission Create Torrent
Aspirant
Posts: 8
Registered: ‎2010-10-01

Re: Sparc platform development envrionment using Qemu

I managed to get this running fairly easily in my Ubuntu 10.10 virtual machine (running win 7 pro x64 as a base). What I had real difficulty with was setting up a tap/tun bridge to my external network (for testing updates and patches to the minidlna service more than anything else). The only documentation that QEMU provides (that I was able to find at least) is as follows: http://wiki.qemu.org/Documentation/Networking/Tap Currently this is a bit useless but it may prove useful to people in the future. I managed to get it running in the end using a combination of stuff found through these links:

http://ubuntuforums.org/showthread.php?t=179472
http://compsoc.dur.ac.uk/~djw/qemu.html
http://permalink.gmane.org/gmane.comp.e ... qemu/81839
http://en.wikibooks.org/wiki/QEMU/Networking#qemu-ifup

http://ubuntuforums.org/archive/index.php/t-593577.html <<<<Godsend

As far as I can tell there is no documentation/guides for this on the site so I'm going to document it in this post(if only so I can do it again later when I inevitably forget) and I'm going to try and be as clear as I can about EVERYTHING as most of the tuts I have read in the past tend to assume a base level of knowledge that is (at least in my case) not always there.

To note I am doing this on a virtual machine in Bridge mode and have a router with a DHCP server using Ubuntu 10.10 and Qemu 0.13.0. If you are planing on doing this with static ip addresses you will need to edit your /etc/network/interfaces file (http://compsoc.dur.ac.uk/~djw/qemu.html seems to cover it in at least some depth)

There are some extra packages that need to be installed onto the operating system that do not come with qemu and didn't come with my particular installation of Ubuntu
sudo apt-get install vtun
sudo apt-get install bridge-utils
sudo apt-get install uml-utilities


We need vtun to create our tap interface that Qemu will use to talk to our outside network and bridge-utils to help create the bridge that will allow QEMU to talk to the network rather than just the host.
(Bridges are quite nicely covered here in a qemu context for anyone interested: http://qemu-buch.de/cgi-bin/moin.cgi/Qe ... =%28Tap%29)
Not entirely sure why the uml-utilities are needed, but they are specifically mentioned in one of the tutorials I have read.

Next we have to set up the bridge, set up the tap interface that QEMU will use and then add any connections that we want to use to the bridge

First we set the permissions of the tun device
chown root.users /dev/net/tun 
chmod g+rw /dev/net/tun


One of the tutorials has suggested using a new group to manage this but as I am the only person using this VM I couldn't be arsed.

Next we create the bridge and assign a connection to it. The majority will be wanting to use eth0 the usual wired connection but I have done something similar using my laptop and the ath0 wireless interface. You should also note that you will lose network conectivity briefly at this stage
brctl addbr br0
ifconfig eth0 0.0.0.0 promisc
brctl addif br0 eth0
dhclient br0


Now we create and enable the tap device that we will be using where dave is the username of the account being used. I used tap0 because it made sense to me and sticks vaguely to existing standards but I believe you can rename it to whatever the hell you want.
tunctl -t tap0 -u dave

brctl addif br0 tap0
ifconfig tap0 up


The above code either needs to be done every time you wish to use the connection or be put into your /etc/rc.local file to be run at startup. I did the latter because I'm lazy and it doesn't really impact on my system, however if you have programs that are hard coded to rely on the eth0 interface this could cause problems later.

Next we need to create a script to allow qemu to deal with the tap interface (and because it wont let you run the program without it).
This is named qemu-ifup and it exists in the /etc folder (I got this from: http://compsoc.dur.ac.uk/~djw/qemu.html)


#!/bin/sh

echo "Executing /etc/qemu-ifup"
echo "Bringing up $1 for Bridged mode..."
sudo /sbin/ifconfig $1 0.0.0.0 promisc up
echo "adding $1 to br0..."
sudo /usr/sbin/brctl addif br0 $1
echo "finished running script"
sleep 2


and then we need to make sure that this can be executed by all users
chmod 755 /etc/qemu-ifup 

Or
chmod a+x /etc/qemu-ifup 

if youre just planning to use it yourself

Thats the basics to get things running!
Running Qemu with A tun/tap interface requires root access(sudo) so I've also taken the suggestion of the last link to create a sudoers file, which allows me to run qemu without having to enter my password or switching to a root account. This needs to be done using visudo which is loosely based on vi and isn't particularly user friendly. This can also seriously screw up your instalation if done wrong (as I found out) and require to go back into the recovery mode to fix. In VMware the recovery mode does not seem to be accessible and just dumped me into a standard terminal session without root access so I would highly recomend using snapshots if you aren't doing so already so you can simply revert to an earlier state (also aplies to qemu emulations).

My sudoers file is as follows:
# /etc/sudoers
#
# This file MUST be edited with the 'visudo' command as root.
#
# See the man page for details on how to write a sudoers file.
#

# Host alias specification

# User alias specification

# Cmnd alias specification
Cmnd_Alias QEMU=/sbin/ifconfig, \
/sbin/modprobe, \
/usr/sbin/brctl

# User privilege specification
root ALL=(ALL) ALL
dave ALL=NOPASSWD: QEMU


And that is all the preparation I have done to get this running. I can now call the program using the following code and it appears on my local network like any other device:
sudo qemu-system-sparc -hda readynas_compile_environment.qcow -nographic -m 256 -net nic,vlan=0 -net tap,vlan=0

-m sets the allocated memory to 256MB rather than the default 128
-net nic,vlan=0 -net tap,vlan=0 is the code needed to set qemu to run

As far as I know this is all that is needed to configure to qemu to run in this bridged mode. Any qestions feel free to ask, I only visit infrequently and my knowledge is limited but I will try my best to help.

*Edit: Corrected some typos*
Aspirant
Posts: 3
Registered: ‎2011-04-09

Re: Sparc platform development envrionment using Qemu

First off, being able to run the SPARC platform in a virtualized environment is fantastic; I was hesitant to install the build tools on the one NAS I have - so thanks for making this available. No problems getting this up and running, though once booting into the machine it's not really "configured". Frontview/Apache isn't running and the firmware is a little outdated. This doesn't yield a huge problem as it's easy enough to start these services, though after starting Frontview and loading it in a browser it simply times out with a critical error. This results in nothing but an outline of the Frontview window being rendered, no menus or options, etc, basically a blank screen.

So without a working Frontview, is there any way to upgrade the RAIDiator firmware to the latest (4.1.7 at the moment) through the command line on the virtual machine? Or has anyone successfully gotten Frontview to apply a firmware update to the qemu image?

I'm looking to replicate my NAS completely, Frontview and firmware as well, so I can develop add-ons without risking my environment. This image is perfect for compiling and testing out console based/system modules, though you're a bit limited if you want to do anything with Frontview.

Tip for anyone looking to run the machine with more than 256mb of memory, append "-M SS-10" to your QEMU command line to emulate SparcStation 10 which allows the increase.
Aspirant
Posts: 104
Registered: ‎2007-04-21

Re: Sparc platform development envrionment using Qemu

Can someone please post or send me privately the instructions to update RAIDiator via the command line please.

Want to upgrade my QEMU image to 4.1.7 and I'm having to go through the code at the moment which is proving time consuming when you don't know what you are looking for.

Thanks,

Paul.
Apprentice
Posts: 16,075
Registered: ‎2007-09-24

Re: Sparc platform development envrionment using Qemu

The QEMU image is not based on RAIDiator, so you can't upgrade the QEMU image to 4.1.7. It is just a Sparc emulated Debian Linux, that can be used to compile code to run on the ReadyNAS.
Jedi Council Alumni | See my profile About page for my ReadyNAS history (2004-2012) |
https://twitter.com/chirpah/status/852389882764840960/photo/1
Aspirant
Posts: 104
Registered: ‎2007-04-21

Re: Sparc platform development envrionment using Qemu

Hmmm...

Wanted to compile some code against libraries / kernel included 4.1.7.
Discussion Stats
Top Contributors