<?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>8264</bug_id>
          
          <creation_ts>2015-09-07 12:31:53 +0000</creation_ts>
          <short_desc>LogrotateTest Error and Fail on x86-64-lsb</short_desc>
          <delta_ts>2015-10-23 13:04:40 +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>OE-Core</product>
          <component>Scripts and Tools</component>
          <version>1.7.3</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>2.0</target_milestone>
          
          <blocked>7983</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Beth Flanagan">elizabeth.flanagan</reporter>
          <assigned_to name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</assigned_to>
          <cc>bogdanx.a.voiculescu</cc>
    
    <cc>ross.burton</cc>
          
          <qa_contact name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</qa_contact>
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>53777</commentid>
    <comment_count>0</comment_count>
    <who name="Beth Flanagan">elizabeth.flanagan</who>
    <bug_when>2015-09-07 12:31:53 +0000</bug_when>
    <thetext>https://autobuilder.yoctoproject.org/main/builders/nightly-x86-64-lsb

Logrotate can&apos;t create directory during setup/or timesout, causing ERROR in LogrotateTest.

| ======================================================================
| ERROR: test_2_logrotate (oeqa.runtime.logrotate.LogrotateTest)
| ----------------------------------------------------------------------
| Traceback (most recent call last):
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/utils/decorators.py&quot;, line 102, in wrapped_f
|     return func(*args)
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/utils/decorators.py&quot;, line 90, in wrapped_f
|     return f(*args)
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/runtime/logrotate.py&quot;, line 28, in test_2_logrotate
|     self.assertTrue(int(output)&gt;=3, msg = &quot;new logfile could not be created. List of files within log directory: %s&quot; %(self.target.run(&apos;ls -la /home/root/logrotate_dir&apos;)[1]))
| ValueError: invalid literal for int() with base 10: &apos;ls: cannot access /home/root/logrotate_dir/: No such file or directory\n0&apos;
| 
| ======================================================================
| FAIL: test_1_logrotate_setup (oeqa.runtime.logrotate.LogrotateTest)
| ----------------------------------------------------------------------
| Traceback (most recent call last):
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/utils/decorators.py&quot;, line 90, in wrapped_f
|     return f(*args)
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/runtime/logrotate.py&quot;, line 18, in test_1_logrotate_setup
|     self.assertEqual(status, 0, msg = &quot;Could not create logrotate_dir. Output: %s&quot; % output)
| AssertionError: -15 != 0 : Could not create logrotate_dir. Output:
| Process killed - no output for 300 seconds. Total running time: 300 seconds.
| 
| ----------------------------------------------------------------------
| Ran 59 tests in 5879.028s
| 
| FAILED (failures=1, errors=1, skipped=8)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54535</commentid>
    <comment_count>1</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2015-09-23 13:40:50 +0000</bug_when>
    <thetext>Another issue coming from 

https://autobuilder.yoctoproject.org/main/builders/nightly-x86-64-lsb/builds/502

| ======================================================================
| FAIL: test_2_logrotate (oeqa.runtime.logrotate.LogrotateTest)
| ----------------------------------------------------------------------
| Traceback (most recent call last):
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/utils/decorators.py&quot;, line 102, in wrapped_f
|     return func(*args)
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/utils/decorators.py&quot;, line 90, in wrapped_f
|     return f(*args)
|   File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-x86-64-lsb/build/meta/lib/oeqa/runtime/logrotate.py&quot;, line 26, in test_2_logrotate
|     self.assertEqual(status, 0, msg = &quot;logrotate service could not be reloaded. Status and output: %s and %s&quot; % (status, output))
| AssertionError: 143 != 0 : logrotate service could not be reloaded. Status and output: 143 and
| Process killed - no output for 300 seconds. Total running time: 300 seconds.
| 
| ----------------------------------------------------------------------

Still investigating the root cause.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54721</commentid>
    <comment_count>2</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2015-09-28 13:52:45 +0000</bug_when>
    <thetext>Seems to be a random failure. Since Sep/16. this issue has not shown again. Unfortunately, when I tried to the log from Sep/16, the log was already removed, so I have no system data to check. I will keep monitoring.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>54787</commentid>
    <comment_count>3</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2015-09-29 14:57:19 +0000</bug_when>
    <thetext>There are two problem not related to logrotate but the logrotate unit tests helped to bring them out

1) @skip* decorators: A patch sent t to the mailing list titled &apos;[PATCH] oeqa/utils/decorators: Append the testname without the full path&apos; which allows indicating unit tests without full path. This will prevent running test_2_logrotate if this depends on test_1_logrotate_setup through the decorator @skipUnlessPassed, as observed on https://bugzilla.yoctoproject.org/show_bug.cgi?id=8264#c0

2) timeouts: sometimes, there are timeouts when running either mkdir or logrotate commands. I do not know for sure what is causing this type of failures, but it may the case that the connection (ssh) is being lost for a while, so timeout is triggered. This is not related to the logrotate package, it is a connectivity issue and should be reported as a separate bug. Log reported on https://bugzilla.yoctoproject.org/show_bug.cgi?id=8264#c1</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>55669</commentid>
    <comment_count>4</comment_count>
    <who name="Bogdan Alexandru Voiculescu">bogdanx.a.voiculescu</who>
    <bug_when>2015-10-23 13:04:40 +0000</bug_when>
    <thetext>Fixed in build nightly-x86-64-lsb #528: 
https://autobuilder.yoctoproject.org/main/builders/nightly-x86-64-lsb/builds/528/steps/Running%20Sanity%20Tests/logs/stdio


| test_1_logrotate_setup (oeqa.runtime.logrotate.LogrotateTest) ... ok
| test_2_logrotate (oeqa.runtime.logrotate.LogrotateTest) ... ok</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>