title: no core dump in /var/crash
body: <p>I am trying to understand a bit how the core dump work.</p>
  
  <p>I use the test.c file to generate a core dump :</p>
  
  <pre><code>#include &lt;stdio.h&gt;                                                              
  
  void foo()                                                                      
  {                                                                               
          int *ptr = 0;                                                           
          *ptr = 7;                                                               
  }                                                                               
  
  int main()                                                                      
  {                                                                               
          foo();                                                                  
          return 0;                                                               
  }
  </code></pre>
  
  <p>I compile with </p>
  
  <pre><code>gcc test.c -o test
  </code></pre>
  
  <p>Which gives me the following message when I run ./test</p>
  
  <pre><code>Segmentation fault (core dumped)
  </code></pre>
  
  <p>My file</p>
  
  <pre><code>/proc/sys/kernel/core_pattern 
  </code></pre>
  
  <p>contains :</p>
  
  <pre><code>|/usr/share/apport/apport %p %s %c %d %P
  </code></pre>
  
  <p>I checked that I have the permissions to write to the directory</p>
  
  <pre><code>/var/crash/
  </code></pre>
  
  <p>but after the core dump there is nothing in this folder (/var/crash/).
  I am using Linux release 17.04.
  Do you know what can go wrong here?</p>
  
  <p><strong>edit</strong></p>
  
  <p>I forgot to mention that I set the limits with :</p>
  
  <pre><code>ulimit -c unlimited
  </code></pre>
  
  <p>so the output of </p>
  
  <pre><code>ulimit -c
  </code></pre>
  
  <p>reads :</p>
  
  <pre><code>unlimited
  </code></pre>
  
  <p>I even tried to do what they say <a href="https://wiki.ubuntu.com/Apport" rel="nofollow noreferrer">here</a> in section <strong>How to enable apport</strong>, so I added a hash sign in front of </p>
  
  <pre><code>'problem_types': ['Bug', 'Package']
  </code></pre>
  
  <p>But with all of this the core dump cannot be found in /var/cash</p>