Mailinglist Archive: opensuse-bugs (2746 mails)

< Previous Next >
[Bug 827105] New: Getting Memory fault with korn shell when running a shell script.
  • From: bugzilla_noreply@xxxxxxxxxx
  • Date: Thu, 27 Jun 2013 15:26:15 +0000
  • Message-id: <bug-827105-21960@http.bugzilla.novell.com/>

https://bugzilla.novell.com/show_bug.cgi?id=827105

https://bugzilla.novell.com/show_bug.cgi?id=827105#c0


Summary: Getting Memory fault with korn shell when running a
shell script.
Classification: openSUSE
Product: openSUSE 11.4
Version: RC 1
Platform: x86-64
OS/Version: SLES 11
Status: NEW
Severity: Major
Priority: P5 - None
Component: Other
AssignedTo: bnc-team-screening@xxxxxxxxxxxxxxxxxxxxxx
ReportedBy: sangameshwar.allipuram@xxxxxxxxxxxxxx
QAContact: qa-bugs@xxxxxxx
Found By: ---
Blocker: ---


User-Agent: Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like
Gecko) Chrome/27.0.1453.116 Safari/537.36

We are running SUSE Linux Enterprise server 11 at patch level 1. (11.1) and ksh
shell version is "93t+ 2010-03-05".

When we are running the shell script with the korn shell it is exiting with
memory fault. Running with strace it shows at different points with different
runs.


I am putting the "strace" and "set -x" output with actual results part.

I am not finding any fault with the script code. I am not sure something got
messing up. This script was successfully working with solaris/ksh. We are
porting the product to suse linux server.

Please, let me know if there are some thoughts to resolve this issue.

Reproducible: Always

Steps to Reproduce:
This issue could not reproduced using a simple shell script.

If we comment some part of the code which was giving this issue, it gives
memory fault some other place.
Actual Results:
Log for strace:
-----------------
stat("/u2/workarea/swmgr/sms01/LOG/INSTALL_DEBUG.log", 0x7fff26d5adb0) = -1
ENOENT (No such file or directory)
stat("/u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log", {st_mode=S_IFREG|0775,
st_size=61064, ...}) = 0
access("/u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log", W_OK) = 0
stat("/u2/workarea/swmgr/sms01/LOG/INSTALL_ERROR.log", {st_mode=S_IFREG|0775,
st_size=3775, ...}) = 0
access("/u2/workarea/swmgr/sms01/LOG/INSTALL_ERROR.log", W_OK) = 0
write(2, "+ set -x\n+ logA $'Dependency: \\E"..., 491+ set -x
+ logA $'Dependency: \E[7mCore\E(B\E[m and \E[7mNetwork_Elements\E(B\E[m are
compatible\\n\\n'
+ DEBUG_file=INSTALL_DEBUG.log
+ [[ -f /u2/workarea/swmgr/sms01/LOG/INSTALL_DEBUG.log ]]
+ AUDIT_file=INSTALL_AUDIT.log
+ [[ -f /u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log ]]
+ [[ ! -w /u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log ]]
+ ERROR_file=INSTALL_ERROR.log
+ [[ -f /u2/workarea/swmgr/sms01/LOG/INSTALL_ERROR.log ]]
+ [[ ! -w /u2/workarea/swmgr/sms01/LOG/INSTALL_ERROR.log ]]
) = 491
fcntl(1, F_DUPFD, 10) = 11
fcntl(11, F_SETFD, FD_CLOEXEC) = 0
close(1) = 0
socketpair(PF_FILE, SOCK_STREAM, 0, [1, 3]) = 0
shutdown(3, 0 /* receive */) = 0
fchmod(3, 0200) = 0
shutdown(1, 1 /* send */) = 0
fchmod(1, 0400) = 0
dup(1) = 4
close(1) = 0
fcntl(4, F_SETFD, FD_CLOEXEC) = 0
fcntl(3, F_DUPFD, 1) = 1
close(3) = 0
write(2, "+ date '+%Y/%m/%d - %H:%M:%S'\n", 30+ date '+%Y/%m/%d - %H:%M:%S'
) = 30
fstat(1, {st_mode=S_IFSOCK|0200, st_size=0, ...}) = 0
clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD,
child_tidptr=0x7f14f44a09d0) = 18285
fstat(4, {st_mode=S_IFSOCK|0400, st_size=0, ...}) = 0
fstat(4, {st_mode=S_IFSOCK|0400, st_size=0, ...}) = 0
close(1) = 0
close(1) = -1 EBADF (Bad file descriptor)
fcntl(11, F_DUPFD, 1) = 1
close(11) = 0
read(4, "2013/06/27 - 11:14:52\n", 8192) = 22
read(4, "", 8192) = 0
--- SIGCHLD (Child exited) @ 0 (o) ---
wait4(-1, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], WNOHANG|WSTOPPED|WCONTINUED,
NULL) = 18285
wait4(-1, 0x7fff26d5a1c4, WNOHANG|WSTOPPED|WCONTINUED, NULL) = -1 ECHILD (No
child processes)
rt_sigaction(SIGCHLD, {0x7f14f3dff210, [], SA_RESTORER|SA_INTERRUPT,
0x7f14f313c9e0}, {0x7f14f3dff210, [], SA_RESTORER|SA_INTERRUPT,
0x7f14f313c9e0}, 8) = 0
rt_sigreturn(0x11) = 0
ioctl(2, TIOCGPGRP, [18155]) = 0
close(4) = 0
write(2, "+ DATE='2013/06/27 - 11:14:52'\n+"..., 274+ DATE='2013/06/27 -
11:14:52'
+ typeset -u LOG_TYPE
+ LOG_TYPE=AUDIT
+ Message=$'Dependency: \E[7mCore\E(B\E[m and \E[7mNetwork_Elements\E(B\E[m are
compatible\\n\\n'
+ set -x
+ print $' Dependency: \E[7mCore\E(B\E[m and \E[7mNetwork_Elements\E(B\E[m are
compatible\\n\\n'
) = 274
write(1, " Dependency: \33[7mCore\33(B\33[m and "..., 76 Dependency: Core and
Network_Elements are compatible


) = 76
write(2, "+ print - 2013/06/27 - 11:14:52 "..., 131+ print - 2013/06/27 -
11:14:52 :AUDIT: Dependency: $'\E[7mCore\E(B\E[m' and
$'\E[7mNetwork_Elements\E(B\E[m' are 'compatible\n\n'
) = 131
open("/u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log",
O_WRONLY|O_CREAT|O_APPEND, 0666) = 3
fcntl(1, F_DUPFD, 10) = 11
fcntl(11, F_SETFD, FD_CLOEXEC) = 0
write(2, "+ 1>> /u2/workarea/swmgr/sms01/L"..., 53+ 1>>
/u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log
) = 53
close(1) = 0
ioctl(3, SNDCTL_TMR_TIMEBASE or TCGETS, 0x7fff26d5a580) = -1 ENOTTY
(Inappropriate ioctl for device)
lseek(3, 0, SEEK_CUR) = 0
fstat(3, {st_mode=S_IFREG|0775, st_size=61064, ...}) = 0
fcntl(3, F_DUPFD, 1) = 1
close(3) = 0
fstat(1, {st_mode=S_IFREG|0775, st_size=61064, ...}) = 0
lseek(1, 0, SEEK_CUR) = 0
close(3) = -1 EBADF (Bad file descriptor)
write(1, "2013/06/27 - 11:14:52 :AUDIT: De"..., 105) = 105
lseek(1, 0, SEEK_CUR) = 61169
close(1) = 0
fcntl(11, F_DUPFD, 1) = 1
close(11) = 0
--- SIGSEGV (Segmentation fault) @ 0 (o) ---
+++ killed by SIGSEGV +++



---------------------------------------------------------------------
---------------------------------------------------------------------

Log with set -x:

---------------------------------------------------------------------
---------------------------------------------------------------------


**********************************************************
+ printf ' Name | Dependency\t | Compatibility \n'
Name | Dependency | Compatibility
+ printf '***********************************************************\n'
***********************************************************
+ printf 'Network_Elements |Core | \n'
Network_Elements |Core |
+ printf ver='5.1.0\t|min_ver= 5.1.0\t | \n '
ver=5.1.0 |min_ver= 5.1.0 |
+ printf ' |max_ver= 5.99.999\t |COMPATIBLE \n'
|max_ver= 5.99.999 |COMPATIBLE
+ printf ' |status = Y\t | \n '
|status = Y |
+ printf '***********************************************************\n'
***********************************************************
+ set -x
+ logA $'Dependency: \E[7mCore\E(B\E[m and \E[7mNetwork_Elements\E(B\E[m are
compatible\\n\\n'
+ DEBUG_file=INSTALL_DEBUG.log
+ [[ -f /u2/workarea/swmgr/sms01/LOG/INSTALL_DEBUG.log ]]
+ AUDIT_file=INSTALL_AUDIT.log
+ [[ -f /u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log ]]
+ [[ ! -w /u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log ]]
+ ERROR_file=INSTALL_ERROR.log
+ [[ -f /u2/workarea/swmgr/sms01/LOG/INSTALL_ERROR.log ]]
+ [[ ! -w /u2/workarea/swmgr/sms01/LOG/INSTALL_ERROR.log ]]
+ date '+%Y/%m/%d - %H:%M:%S'
+ DATE='2013/06/27 - 11:12:59'
+ typeset -u LOG_TYPE
+ LOG_TYPE=AUDIT
+ Message=$'Dependency: \E[7mCore\E(B\E[m and \E[7mNetwork_Elements\E(B\E[m are
compatible\\n\\n'
+ set -x
+ print $' Dependency: \E[7mCore\E(B\E[m and \E[7mNetwork_Elements\E(B\E[m are
compatible\\n\\n'
Dependency: Core and Network_Elements are compatible


+ print - 2013/06/27 - 11:12:59 :AUDIT: Dependency: $'\E[7mCore\E(B\E[m' and
$'\E[7mNetwork_Elements\E(B\E[m' are 'compatible\n\n'
+ 1>> /u2/workarea/swmgr/sms01/LOG/INSTALL_AUDIT.log
Memory fault

--
Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

< Previous Next >
This Thread
  • No further messages