<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>1171</bug_id>
          
          <creation_ts>2011-06-16 01:02:39 +0000</creation_ts>
          <short_desc>No enough disk space with qemu sato images</short_desc>
          <delta_ts>2011-07-12 00:09:27 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>Meta-yocto</product>
          <component>meta-yocto</component>
          <version>unspecified</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>VERIFIED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.1 M2</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Yi Zhao">yi.zhao</reporter>
          <assigned_to name="Edwin Zhai">edwin.zhai</assigned_to>
          <cc>dvhart</cc>
    
    <cc>elizabeth.flanagan</cc>
    
    <cc>jiajun.xu</cc>
    
    <cc>liang.li2</cc>
    
    <cc>liangliang.wang</cc>
    
    <cc>poky.bs.watcher</cc>
    
    <cc>poky.watcher</cc>
    
    <cc>sgw</cc>
    
    <cc>shane.wang</cc>
    
    <cc>wenhuax.fan</cc>
    
    <cc>yi.zhao</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>14306</commentid>
    <comment_count>0</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2011-06-16 01:02:39 +0000</bug_when>
    <thetext>Testing Env:    
Host: Ubuntu 10.10 x86_64
Kernel: 2.6.35-28-generic

Image location:
http://autobuilder.yoctoproject.org/nightly/20110613-1/
Tree/Branch: Poky/master
Commit: e5f3cc34df74c08c8cab3e1cf9207fafaec6cb9a

After I add a zypper repo and install/remove package, the free disk space is less than 3M, since the rpm db file and log file will spend more then 10M size.  

Setps:
Boot up the qemuarm sato image. At first time the free disk space is about 15M:
################# 
root@qemuarm:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               143.6M    121.6M     14.7M  89% /
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.6M    108.0K     60.5M   0% /dev
tmpfs                    60.6M     68.0K     60.6M   0% /var/volatile
tmpfs                    60.6M         0     60.6M   0% /media/ram
#################

And the size fo /var/lib/rpm directory is:
################
root@qemuarm:/var/lib/rpm# du /var/lib/rpm -sh
3.5M	/var/lib/rpm
################

After I add a zypper repo, the free disk space reduce about 10M.
###############
root@qemuarm:~# zypper ar http://192.168.7.1/rpmrepo rpmrepo
Adding repository &apos;rpmrepo&apos; [done]
Repository &apos;rpmrepo&apos; successfully added
Enabled: Yes
Autorefresh: No
URI: http://192.168.7.1/rpmrepo

root@qemuarm:~# zypper ref
Retrieving repository &apos;rpmrepo&apos; metadata [\]
File &apos;repomd.xml&apos; from repository &apos;rpmrepo&apos; is unsigned, continue? [yes/no] (no): yes
Retrieving repository &apos;rpmrepo&apos; metadata [done]
Building repository &apos;rpmrepo&apos; cache [done]
All repositories have been refreshed.

root@qemuarm:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               143.6M    130.8M      5.5M  96% /
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.6M    108.0K     60.5M   0% /dev
tmpfs                    60.6M      2.5M     58.1M   4% /var/volatile
tmpfs                    60.6M         0     60.6M   0% /media/ram
root@qemuarm:~# 
##############

And the size fo /var/lib/rpm directory is:
################
root@qemuarm:/var/lib/rpm# du /var/lib/rpm -sh
12.7M	/var/lib/rpm
################

After I install and remove a rpm package, for example: man
################
root@qemuarm:/var/lib/rpm# zypper install man
Loading repository data...
Reading installed packages...
Resolving package dependencies...

The following NEW package is going to be installed:
  man 

1 new package to install.
Overall download size: 125.0 KiB. After the operation, additional 246.0 KiB will be used.
Continue? [y/n/?] (y): y
Retrieving package man-1.6f-r0.armv5te (1/1), 125.0 KiB (246.0 KiB unpacked)
Retrieving: man-1.6f-r0.armv5te.rpm [done]
Installing: man-1.6f-r0 [done]

root@qemuarm:/var/lib/rpm# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               143.6M    133.8M      2.5M  98% /
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.6M    108.0K     60.5M   0% /dev
tmpfs                    60.6M      2.6M     58.1M   4% /var/volatile
tmpfs                    60.6M         0     60.6M   0% /media/ram

root@qemuarm:~# zypper rm man
Loading repository data...
Reading installed packages...
Resolving package dependencies...

The following package is going to be REMOVED:
  man 

1 package to remove.
After the operation, 246.0 KiB will be freed.
Continue? [y/n/?] (y): y
Removing man-1.6f-r0 [done]

root@qemuarm:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               143.6M    133.5M      2.8M  98% /
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.6M    108.0K     60.5M   0% /dev
tmpfs                    60.6M      2.6M     58.0M   4% /var/volatile
tmpfs                    60.6M         0     60.6M   0% /media/ram

root@qemuarm:~# du /var/cache/zypp/ -sh
2.4M	/var/cache/zypp/
root@qemuarm:~# du /var/lib/rpm/ -sh
15.4M	/var/lib/rpm/

###########################

Then the free disk space is less than 3M, it is difficult to install another package.

More info:
When you add a zypper repo or install/remove rpm package at first time. The system will initialize some db file and create a log file, these files will spend more then 10M size. You can find these files in /var/lib/rpm directory.

So I think we should keep more than 20M free space when qemu image boot up at first time.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14307</commentid>
    <comment_count>1</comment_count>
    <who name="Liang Wang">liangliang.wang</who>
    <bug_when>2011-06-16 01:30:32 +0000</bug_when>
    <thetext>The same issue also occurs on qemumips-sato image.

Image location:
http://autobuilder.yoctoproject.org/nightly/20110613-1/
Tree/Branch: Poky/master
Commit: e5f3cc34df74c08c8cab3e1cf9207fafaec6cb9a</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14308</commentid>
    <comment_count>2</comment_count>
    <who name="liang li">liang.li2</who>
    <bug_when>2011-06-16 01:53:34 +0000</bug_when>
    <thetext>the same issues on qemuppc sato images from nightly build 20110613-1:
http://autobuilder.pokylinux.org/nightly/20110613-1/machines/qemu/qemuppc/
free space when boot the sato images:
root@qemuppc:/var/lib/rpm# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               158.1M    133.7M     16.4M  89% /
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                    251.1M     80.0K    251.0M   0% /dev
tmpfs                   251.1M     64.0K    251.0M   0% /var/volatile
tmpfs                   251.1M         0    251.1M   0% /media/ram

and no such issues on qemuppc sato images from nightly build  20110527-1
http://autobuilder.pokylinux.org/nightly/20110527-1/:
free space when boot the sato images:
oot@qemuppc:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               269.0M    223.9M     31.5M  88% /
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.7M     76.0K     60.6M   0% /dev
tmpfs                    60.7M     64.0K     60.6M   0% /var/volatile
tmpfs                    60.7M         0     60.7M   0% /media/ram
root@qemuppc:~#</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14314</commentid>
    <comment_count>3</comment_count>
    <who name="Darren Hart">dvhart</who>
    <bug_when>2011-06-16 08:27:11 +0000</bug_when>
    <thetext>Saul, is this just a result of the updated image sizing mechanism?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14321</commentid>
    <comment_count>4</comment_count>
    <who name="wenhua.fan">wenhuax.fan</who>
    <bug_when>2011-06-16 19:26:22 +0000</bug_when>
    <thetext>This bug also exist in qemux86 sato image.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14396</commentid>
    <comment_count>5</comment_count>
    <who name="Shane Wang">shane.wang</who>
    <bug_when>2011-06-23 17:17:42 +0000</bug_when>
    <thetext>Edwin will expand the qemu image size by changing the parameter of bitbake. We need discuss the policy to do that first to avoid objections from the community, i.e., how many percents of image size should be increased?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14426</commentid>
    <comment_count>6</comment_count>
    <who name="Edwin Zhai">edwin.zhai</who>
    <bug_when>2011-06-27 00:28:20 +0000</bug_when>
    <thetext>Image size is tunable via some parameter when building. Pls. see meta/conf/bitbake.conf:

image_size = rootfs * IMAGE_OVERHEAD_FACTOR(default 1.3) + IMAGE_ROOTFS_EXTRA_SPACE

Issue here is that end user&apos;s requirement are different depends on their own needs. Some of them probably want to run oracle in disk image, but yocto disk image is hard to support it.

Yi,
What&apos;s the requirement from your daily test? Saul can give comments, so we can enlarge some factor to meet the requirement.

BTW, another option is to make and add another free disk image by yourself if the test allow files from another disk.

Thanks,
Edwin</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14428</commentid>
    <comment_count>7</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2011-06-27 03:00:27 +0000</bug_when>
    <thetext>(In reply to comment #6)
&gt; Image size is tunable via some parameter when building. Pls. see
&gt; meta/conf/bitbake.conf:
&gt; 
&gt; image_size = rootfs * IMAGE_OVERHEAD_FACTOR(default 1.3) +
&gt; IMAGE_ROOTFS_EXTRA_SPACE
&gt; 
&gt; Issue here is that end user&apos;s requirement are different depends on their own
&gt; needs. Some of them probably want to run oracle in disk image, but yocto disk
&gt; image is hard to support it.
&gt; 
&gt; Yi,
&gt; What&apos;s the requirement from your daily test? Saul can give comments, so we can
&gt; enlarge some factor to meet the requirement.
&gt; 
&gt; BTW, another option is to make and add another free disk image by yourself if
&gt; the test allow files from another disk.
&gt; 
&gt; Thanks,
&gt; Edwin

There are some zypper test cases in my weekly testing. I need to install/remove 4 packages by using zypper.

I re-test with 20110625 build, when boot up the sato image at first time:
###################
root@qemuarm:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               145.5M    120.6M     17.5M  87% /
devtmpfs                 60.2M    108.0K     60.1M   0% /dev
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.2M    108.0K     60.1M   0% /dev
tmpfs                    60.2M     64.0K     60.2M   0% /var/volatile
tmpfs                    60.2M         0     60.2M   0% /media/ram
root@qemuarm:~# 

root@qemuarm:~# du /var/lib/rpm/ -sh
3.4M	/var/lib/rpm/
###################

When I add a zypper repo, rpm will initialize some db file and create a log file, these files will cost about 10MB space.

###################
root@qemuarm:~# zypper ar http://192.168.7.1/rpmrepo rpmrepo
Adding repository &apos;rpmrepo&apos; [done]
Repository &apos;rpmrepo&apos; successfully added
Enabled: Yes
Autorefresh: No
URI: http://192.168.7.1/rpmrepo

root@qemuarm:/var/lib# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               145.5M    129.8M      8.2M  94% /
devtmpfs                 60.2M    108.0K     60.1M   0% /dev
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.2M    108.0K     60.1M   0% /dev
tmpfs                    60.2M    236.0K     60.0M   0% /var/volatile
tmpfs                    60.2M         0     60.2M   0% /media/ram

root@qemuarm:~# du /var/lib/rpm/ -sh
12.7M	/var/lib/rpm/
####################

Then I install the first package:
###################
root@qemuarm:~# zypper in man
Loading repository data...
Reading installed packages...
Resolving package dependencies...

The following NEW package is going to be installed:
  man 

1 new package to install.
Overall download size: 125.0 KiB. After the operation, additional 246.0 KiB will be used.
Continue? [y/n/?] (y): y
Retrieving package man-1.6f-r0.armv5te (1/1), 125.0 KiB (246.0 KiB unpacked)
Retrieving: man-1.6f-r0.armv5te.rpm [done]
Installing: man-1.6f-r0 [done]

root@qemuarm:~# df -h
Filesystem                Size      Used Available Use% Mounted on
/dev/root               145.5M    132.8M      5.3M  96% /
devtmpfs                 60.2M    108.0K     60.1M   0% /dev
tmpfs                    40.0K         0     40.0K   0% /mnt/.psplash
none                     60.2M    108.0K     60.1M   0% /dev
tmpfs                    60.2M      2.6M     57.6M   4% /var/volatile
tmpfs                    60.2M         0     60.2M   0% /media/ram

root@qemuarm:~# du /var/lib/rpm/ -sh
15.3M	/var/lib/rpm/
######################

You can see the &apos;man&apos; package only uses 125KB + 246KB space. But the rpm db file will increase about 3MB.

Then I install the second package, the free space is not enough: 
#######################
root@qemuarm:~# zypper in mc
Loading repository data...
Reading installed packages...
Resolving package dependencies...

The following NEW packages are going to be installed:
  mc ncurses-terminfo 

2 new packages to install.
Overall download size: 1.4 MiB. After the operation, additional 4.3 MiB will be used.
Continue? [y/n/?] (y): y
Retrieving package ncurses-terminfo-5.7-r1.armv5te (1/2), 529.0 KiB (1.6 MiB unpacked)
Retrieving: ncurses-terminfo-5.7-r1.armv5te.rpm [done]
Retrieving package mc-4.7.5-r0.armv5te (2/2), 927.0 KiB (2.7 MiB unpacked)
Retrieving: mc-4.7.5-r0.armv5te.rpm [done]
Installing: ncurses-terminfo-5.7-r1 [done]
Installing: mc-4.7.5-r0 [error]
Installation of mc-4.7.5-r0 failed:
(with --nodeps --force) Error: Subprocess failed. Error: RPM failed: error: Install/Erase problems:
	installing package mc-4.7.5-r0.armv5te needs 3MB on the / filesystem


Abort, retry, ignore? [a/r/i] (a): 
#########################


For a large rootfs, for example, sato-sdk image has 80MB free space. When rpm db file has initialized. There is still enough space to install other packages. However, for a small rootfs, only less than 20MB free space, and the rpm db file will use more than 10MB. It is difficult to install other packages. So I think for a small rootfs, in order to complete the testing, 30MB space is required. 

And this issue maybe relate with bug 1174.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14523</commentid>
    <comment_count>8</comment_count>
    <who name="Jiajun Xu">jiajun.xu</who>
    <bug_when>2011-07-03 19:10:16 +0000</bug_when>
    <thetext>Hi Saul,
I remember that you will ask Beth to increase IMAGE_ROOTFS_EXTRA_SPACE on autobuilder. So there is no other fixing required for the bug, right?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14638</commentid>
    <comment_count>9</comment_count>
    <who name="Saul Wold">sgw</who>
    <bug_when>2011-07-08 15:26:44 +0000</bug_when>
    <thetext>http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=7061af381277a20e4df455daac9754b73fcbe467</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14674</commentid>
    <comment_count>10</comment_count>
    <who name="Yi Zhao">yi.zhao</who>
    <bug_when>2011-07-12 00:09:27 +0000</bug_when>
    <thetext>Verified it with 20110708 build

Now there is enough space to complete the testing.

Image location:
http://autobuilder.yoctoproject.org/nightly/20110708-1/
Tree/Branch: Poky/1.1_M2
Poky Commit: 9f4eaeef33da5595748253d59d95c7ca548e28fa</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>