Malloc / free ansd rump_fs ->Slab-backend exhausted

Stefan Kalkowski stefan.kalkowski at ...1...
Wed Sep 3 12:08:57 CEST 2014


On 09/02/2014 09:11 PM, w_schmidt at ...181... wrote:
> Hi,
> did Stefan had time to look into the issue with the block cache?

I'm afraid no, I didn't had the time. To reproduce your experienced
problems easily, it would be nice to have a complete and working
run-script, as well as the whole output of the broken, and of the intact
scenario. Moreover, if you've changed, or added any code, a topic branch
or at least a patch would be nice.

Now, I've built my own script outgoing from the "" script
(attachment), and try to look into the issue.


> Best regards,
> Wolfgang
> -----Ursprüngliche Nachricht----- 
> From: Sebastian Sumpf
> Sent: Thursday, August 21, 2014 8:40 PM
> To: Genode OS Framework Mailing List
> Subject: Re: Malloc / free ansd rump_fs ->Slab-backend exhausted
> Hi Wolfgang,
> On 08/18/2014 08:09 PM, w_schmidt at ...181... wrote:
>> Hi,
>>>> this seems to be happen only if rump_fs has a larger quota – the file
>>>> can be larger if rump_fs has a smaller quota. (memory tests of the
>>>> system have shown no errors so RAM should be okay)
>>> this is indeed very strange. I hope you have a Genode version where
>>> there is no Slab-Backend allocator, have a look at
>> '>include/util/allocator_fap.h" in the dde_rump repository, there should
>>> only be a PERR message with the slab warning left.
>> The file looks like below,
> Yes, that is the right one. We most likely got a problem with memory
> accounting in this case. Regarding your block cache question: The block
> cache has not really been tested up until now, so there may still be
> bugs. If you could provide a branch (e.g., on GitHub) or a run script, I
> might be able to have a look at it. On the other hand, Stefan will be
> back next week and, since wrote the thing, he might be able to clear
> things up.
> Cheers,
> Sebastian

Stefan Kalkowski
Genode Labs ·
-------------- next part --------------
set use_blk_cache 0

# Build
set build_components {
	core init

lappend_if [have_spec acpi]    build_components drivers/acpi
lappend_if [have_spec pci]     build_components drivers/pci
lappend_if [have_spec pci]     build_components drivers/pci/device_pd
lappend_if $use_blk_cache      build_components server/blk_cache

build $build_components

# Generate config
append config {
		<service name="ROM"/>
		<service name="RAM"/>
		<service name="IRQ"/>
		<service name="IO_MEM"/>
		<service name="IO_PORT"/>
		<service name="CAP"/>
		<service name="PD"/>
		<service name="RM"/>
		<service name="CPU"/>
		<service name="LOG"/>
		<service name="SIGNAL" />
		<any-service> <parent/> <any-child/> </any-service>
	<start name="timer">
		<resource name="RAM" quantum="1M"/>
		<provides><service name="Timer"/></provides>
	<start name="acpi">
		<resource name="RAM" quantum="10M"/>
		<binary name="acpi_drv"/>
			<service name="PCI"/>
			<service name="IRQ" />
			<service name="PCI"> <any-child /> </service>
			<any-service> <parent/> <any-child /> </any-service>
	<start name="ahci">
		<binary name="ahci" />
		<resource name="RAM" quantum="10M" />
		<provides><service name="Block" /></provides>
			<service name="IRQ"><child name="acpi" /></service>
			<any-service> <parent /> <any-child /></any-service>

append_if $use_blk_cache config {
	<start name="blk_cache">
		<resource name="RAM" quantum="3M" />
		<provides><service name="Block" /></provides>
			<service name="Block"><child name="ahci" /></service>
			<any-service> <parent /> <any-child /></any-service>
	</start> }

append config {
	<start name="part_blk">
		<resource name="RAM" quantum="10M" />
		<provides><service name="Block" /></provides>
append_if [expr !$use_blk_cache] config {
			<any-service><child name="ahci"/> <parent/><any-child/></any-service>}
append_if $use_blk_cache config {
			<any-service><child name="blk_cache"/> <parent/><any-child/></any-service>}
append config {
			<policy label="rump_fs" partition="1"/>
	<start name="rump_fs">
		<resource name="RAM" quantum="8M" />
		<provides><service name="File_system"/></provides>
		<config fs="ext2fs"><policy label="" root="/" writeable="yes"/></config>
			<any-service><child name="part_blk"/> <parent/><any-child/></any-service>
	<start name="test-libc_vfs">
		<resource name="RAM" quantum="4M"/>
			<libc stdout="/dev/log">
					<dir name="dev"> <log/> </dir>

install_config $config

# Boot modules

# generic modules
set boot_modules {
	core init timer test-libc_vfs ahci part_blk blk_cache rump_fs

lappend_if [have_spec pci]     boot_modules pci_drv
lappend_if [have_spec acpi]    boot_modules acpi_drv
lappend_if [have_spec nova]    boot_modules pci_device_pd
lappend_if $use_blk_cache      boot_modules blk_cache

build_boot_image $boot_modules

append qemu_args " -m 256 -nographic"
append qemu_args " -drive id=disk,file=var/run/rump_ext2.img,if=none -device ahci,id=ahci -device ide-drive,drive=disk,bus=ahci.0 -boot d"

run_genode_until {.*child exited with exit value 0.*} 60

puts "\nTest succeeded\n"

More information about the users mailing list