• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

large Core file - What is the reason & can I delete?

K

kuhle

Guest
I have one domain which is creating ENORMOUS (100-500MB) files in httpdocs. It creates a number of them each day! It has only started in the last 2 weeks.

the files are called core.19521 (the numbers are different on each file, and under the file Type, it says 19521 file (or whatever the corresponding number is in the filename). Looking at today, for example, all but 2 were created between 0215 hrs and 0244 hrs - 32 files in total, with total size being >12GB.

Any idea how I can find out what is causing those files to be created?

Can I safely delete them, and prevent any more from being created?

Thanks in advance for any help.
 
Youd look at them with gdb, example:

gdb /usr/sbin/httpd core.12345

This is assuming they're from apache of course. Look for a setting in your configs like this:
CoreDumpDirectory <PATH>
 
Thanks for the reply. Just had to delete hundreds of files that added up to about 170GB of data! Ridiculous!

I tried what you suggested, but with no real success:

-bash-2.05b# gdb /usr/sbin/httpd core.4917
GNU gdb Red Hat Linux (6.0post-0.20040223.19rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu"...(no debugging symbols found)...Using host libthread_db library "/lib/tls/libthread_db.so.1".

/root/core.4917: No such file or directory.

(gdb) quit
-bash-2.05b# gdb /home/httpd/vhosts/domain.com/httpdocs core.4917
GNU gdb Red Hat Linux (6.0post-0.20040223.19rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu".../home/httpd/vhosts/domain.com/httpdocs: No such file or directory.

/root/core.4917: No such file or directory.

I also looked at httpd.include and vhost.conf for that domain and neither of those mention a CoreDumpDirectory. This is only happening on one domain.

Then I looked at one of the small files, and while most of it was in binary, there were occasional words interspersed, and some of them are below. Is there any clue there as to what might be causing the problem? Does it point at the domain rather than the server doing this?

.shstrtab .hash .dynsym .dynstr .gnu.version .gnu.version_r .rel.dyn .rel.plt .init .text .fini .rodata .eh_frame .ctors .dtors .jcr .dynamic .got .got.plt .data .bss .gnu_debuglink .gnu.liblist .gnu.libstr .gnu.prelink_undo

d. No poll structure was provided and one was required. No socket was provided and one was required. No directory was provided and one was required. No shared memory is currently available No thread key structure was provided and one was required. The specified IP address is invalid. The specified network mask is invalid. The given path was above the root path Bad character specified on command line The specified thread is not detached Your code just forked, and you are currently executing in the child process The process is not recognized. Your code just forked, and you are currently executing in the parent process The specified thread is detached The specified child process is not done executing The timeout specified has expired Partial results are valid but processing is incomplete The specified child process is done executing Shared memory is implemented using files Could not find specified socket in poll list. Shared memory is implemented anonymously Missing parameter for the specified command line option There is no error, this value signifies an initialized error code This function has not been implemented on this platform Shared memory is implemented using a key system APR does not understand this error code DSO load failed The given path is relative The given path is incomplete The given path is absolute End of file found passwords do not match %s: illegal option -- %c

missing argument invalid option character invalid option erroneous argument %s: option requires an argument -- %c
/dev/urandom apr_initialize 0.9.4 sysvsem /tmp/aprXXXXXX fcntl flock unknown °“ÿÿÈ“ÿÿדÿÿÓÿÿÓÿÿדÿÿ 2 Q ¬ = \ z â„¢ ¸ Ö õ Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec Sun Mon Tue Wed Thu Fri Sat apr_global_pool No Error

standard Invalid auth file type: AuthUserFile AuthGroupFile AuthAuthoritative mod_auth.c in user %s not found: %s valid-user group text file containing user IDs and passwords text file containing group names and member user IDs Set to 'no' to allow access control to be passed along to lower modules if the UserID is not known to this module Could not open password file: %s user %s: authentication failure for "%s": Password Mismatch access to %s failed, reason: user %s not allowed access access to %s failed, reason: unknown require directive:"%s" /usr/src/build/482557-i386/BUILD/httpd-2.0.51/modules/aaa/mod_auth.c

Specifies the type of the Certificate Authority file. The following types are supported: DER_FILE - file in binary DER format BASE64_FILE - file in Base64 format CERT7_DB_PATH - Netscape certificate database file /usr/src/build/482557-i386/BUILD/httpd-2.0.51/modules/experimental/util_ldap.c
ent variable name a file name, a custom log format string or format name, and an optional "env=" clause (see docs) the filename of the access log a log format string (see docs) and an optional format name the filename of the cookie log Enable Buffered Logging (experimental) could not initialize buffered log mutex, transfer log may become corrupted could not open transfer log file %s. /usr/src/build/482557-i386/BUILD/httpd-2.0.51/modules/loggers/mod_log_config.c
now access plus years months weeks days hours minutes seconds %c%d modification ': 'ExpiresByType 'ExpiresDefault ExpiresActive Limited to 'on' or 'off' ExpiresByType ExpiresDefault an expiry date code max-age=%lld Cache-Control Expires mod_expires.c * MOD_EXPIRES bad expires code, unrecognised <type> bad expires code, missing <type> bad expires code, numeric value expected <num> ' bad expires code, unrecognised <base> ' a MIME type followed by an expiry date code internal error: bad expires code: %s /usr/src/build/482557-i386/BUILD/httpd-2.0.51/modules/metadata/mod_expires.c
could not be compiled Header echo only valid on Header directive header unset takes two arguments first argument must be add, set, append, unset or echo. headers: ap_headers_output_filter() headers: ap_headers_error_filter() an optional condition, an action, header and value followed by optional env clause /usr/src/build/482557-i386/BUILD/httpd-2.0.51/modules/metadata/mod_headers.c
httpd/unix-directory <html>
<head>
<title>Index of <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
Cannot combine other IndexOptions keywords with 'None' Cannot combine '+' or '-' with 'None' keyword Cannot combine '-' with IconWidth=n Cannot combine '-' with IconHeight=n NameWidth with no value may only appear as '-NameWidth' Cannot combine '-' with NameWidth=n NameWidth value must be greater than 5 DescriptionWidth with no value may only appear as '-DescriptionWidth' Invalid directory indexing option Cannot combine '-' with DescriptionWidth=n DescriptionWidth value must be greater than 12 Second keyword must be 'Name', 'Date', 'Size', or 'Description' First keyword must be 'Ascending' or 'Descending' an icon URL followed by one or more filenames an icon URL followed by one or more MIME types an icon URL followed by one or more content encodings alternate descriptive text followed by one or more filenames alternate descriptive text followed by one or more MIME types alternate descriptive text followed by one or more content encodings one or more index options [+|-][] {Ascending,Descending} {Name,Size,Description,Date} Descriptive text followed by one or more filenames The FancyIndexing directive is no longer supported. Use IndexOptions FancyIndexing. </td><td align="right">%d-%b-%Y %H:%M <tr><th colspan="%d"><hr%s></th></tr>
Can't open directory for index: %s Directory index forbidden by rule: %s /usr/src/build/482557-i386/BUILD/httpd-2.0.51/modules/generators/mod_autoindex.c

They have been deleting a lot of old video files (they are an internet TV company). Could it be that something they have done has initiated this.

Grateful if anybody could help more with this. I am trying to migrate all the domains from this server to a new one, but problems like this could affect the whole migration.
 
CoreDumpDirectory does not exist

Apache went down. Will not restart from Plesk CP:

Unable to make action: Unable to manage service by websrvmng: websrvmng: Service /etc/init.d/httpd failed to start

0: /usr/local/psa/admin/plib/common_func.php3:155
psaerror(string 'Unable to make action: Unable to manage service by websrvmng: websrvmng: Service /etc/init.d/httpd failed to start')
1: /usr/local/psa/admin/htdocs/server/restart_services.php:28


From SSH Root login:

-bash-2.05b# /etc/init.d/httpd start
Starting httpd: Syntax error on line 1 of /etc/httpd/conf.d/debug.conf:
CoreDumpDirectory /tmp/apache2-gdb-dump does not exist
[FAILED]
-bash-2.05b#

I guess I simply need to create that file (in UTF-8???) and upload it to that folder? I will try anyway, but hope someone can help.
 
I think I fixed it by doing this:

# mkdir -p /tmp/apache2-gdb-dump
# chmod 0777 /tmp/apache2-gdb-dump

and then restarted Apache and it is working.

Not sure how or why the directory disappeared in the first place, but it meant that when Apache stopped, it could not automatically restart.

Is this linked to the huge core files that were being created on the client's domain possibly?
 
The core files are still being created randomly in the customers /home/httpd/vhosts/domain.com/httpdocs directory.

Today instead of being approx 400MB each, they are now around 70MB each.

There are no files in the apache2-gdb-dump folder that I created.

I ran the command you gave me and got the following:

.4917-2.05b# gdb /usr/sbin/httpd /home/httpd/vhosts/domain.com/httpdocs/core
GNU gdb Red Hat Linux (6.0post-0.20040223.19rh)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu"...(no debugging symbols found)...Using host libthread_db library "/lib/tls/libthread_db.so.1".

Core was generated by `/usr/sbin/httpd'.
Program terminated with signal 11, Segmentation fault.
#0 0x007680dc in ?? ()
(gdb) quit
-bash-2.05b#

Should the above give me any indication of what to do next.
 
The files are back up to being 400-500 MB in size!!! There is absolutely no pattern to when they are created, nor when, but each day they clog up the server with about 30-70GB of data which is ridiculous, and they have to be manually deleted.

Any help that atomicrocket or anyone else can give as to what might be causing this would be greatly appreciated.
 
I have looked in the .htaccess file at /home/httpd/vhosts/domain.com/httpdocs

# -FrontPage-

IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

<Limit GET POST>
order deny,allow
deny from all
allow from all
</Limit>
<Limit PUT DELETE>
order deny,allow
deny from all
</Limit>
AuthName domain.com
AuthUserFile /home/httpd/vhosts/domain.com/httpdocs/_vti_pvt/service.pwd
AuthGroupFile /home/httpd/vhosts/domain.com/httpdocs/_vti_pvt/service.grp

Does that give any clue as to what is causing these files to be created? Today it created 278 files!! You can only begin to imagine the problems I am having with it guzzling disc space! I really want to complete the migration to the new server, but still have some questions on that.

Thanks for advice so far.
 
Back
Top