0

I have RM/COBOL Runtime - Version 7.10.00 running on a CentOS 6.5 box (VM)

This CentOS allows SSH access to certain domain users by authenticating their group with the local domain controller. These users get a home directory which is automatically created in /home/domainname/username, whereas normal local users reside in /home/username

The relevant Cobol files seem to reside in

/usr/bin/runcobol <- a file
/usr/bin/rmcobolso <- a directory, which seems to be empty according to ls -a

Anyway, here is my basic problem. When a normal user runs the command

# runcobol

...which is just a basic check to see if the command works...
He/she receives the response:

RM/COBOL Runtime - Version 7.10.00 for Linux (Intel).
Configured for 50 users.
Copyright (c) 1985, 1986-2000 by Liant Software Corp.  All rights reserved.
Registration Number: 7H-1054-00367-0050

Usage:    RUNCOBOL name [options]
Options:  [A=arguments] [B=buffersize] [C=configfile] [D] [I] [K]
          [L=libname] [M] [S=switches] [T=sortsize] [V] [X=configmod]

When one of my domain users runs the command

# runcobol

He/she receives the response:

Segmentation fault

What could be causing this problem?

Edit.1:

strace runcobol from domain user. Last few lines included:

open("/usr/lib/libnss_winbind.so.2", O_RDONLY) = -1 ENOENT (No such file or direc
stat64("/usr/lib", {st_mode=S_IFDIR|0555, st_size=4096, ...}) = 0
munmap(0xf76fa000, 48317)               = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++

These are just the last few lines. The 20 lines preceeding this all seem to be looking for this libnss_winbind.so.2 file, which DOES exist on my server in /usr/lib64/libnss_winbind.so.2 (Yes, I'm running CentOS 6.5 64-bit). From the first line of strace runcobol

[test.user.co@co1tu-sv-conta bin]$ strace runcobol
execve("/usr/bin/runcobol", ["runcobol"], [/* 26 vars */]) = 0
[ Process PID=14369 runs in 32 bit mode. ]

So, I'm guessing, but not sure, that I have a 64-bit version of libnss_winbind.so.2 installed, but runcobol is looking for a 32-bit version. So why does my normal user have no problem with runcobol? Well, looking at the strace for the normal user, it doesn't seem to go looking for libnss_winbind.so.2 at all. I guess this makes sense, since winbind has something to do with samba and domain authentication, which the local user isn't doing.

At this point I'm kind of stuck again as I don't have a lot of experience debugging in linux. I see three options from my limited guessing:

  1. Find and install a 32-bit version of libnss_winbind.so.2 in one of the locations that runcobol is looking for. I have no idea which package to install for that on my 64-bit CentOS 6.5

  2. Get runcobol to run without looking for libnss_winbind.so.2. I'm not sure why it is looking to run with that since the user is already authenticated and in the CentOS system. I am not using any domain resources after authentication, so it doesn't even seem like a necessary step.

  3. libnss_winbind.so.2 is a red herring and has nothing to do with the segmentation fault.

Edit.2

Results of gdb runcobol then run:

From local user

Reading symbols from /usr/bin/runcobol...(no debugging symbols found)...done.
(gdb) run
Starting program: /usr/bin/runcobol

RM/COBOL Runtime - Version 7.10.00 for Linux (Intel).
Configured for 50 users.
Copyright (c) 1985, 1986-2000 by Liant Software Corp.  All rights reserved.
Registration Number: 7H-1054-00367-0050

Usage:    RUNCOBOL name [options]
Options:  [A=arguments] [B=buffersize] [C=configfile] [D] [I] [K]
          [L=libname] [M] [S=switches] [T=sortsize] [V] [X=configmod]

Program exited with code 0373.
Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.132.el6_5.4.i686

From domain user

Reading symbols from /usr/bin/runcobol...(no debugging symbols found)...done.
(gdb) run
Starting program: /usr/bin/runcobol

Program received signal SIGSEGV, Segmentation fault.
0x0805cc37 in OSINITIALIZE ()
Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.132.el6_5.4.i686
  • Sounds like a bug in runcobol; it probably doesn't like something about the environment that it is run in when you execute it as a domain user. You could try to debug it with gdb and strace, maybe that'll give a hint what the actual problem is. – Martin von Wittich Oct 7 '14 at 14:56
  • I was hoping it was something simple like 1. A configuration file for 'rubcobol', 2. A path setting for the domain user – Daniel Oct 7 '14 at 15:01
  • Yeah, sorry, but without investigating the cause for the segfault you probably won't find a solution. Yes, the issue may be very simple (for example a missing environment variable or something), but without debugging the issue you probably won't find it. – Martin von Wittich Oct 7 '14 at 15:08
  • OK I ran an strace from a normal user and from a domain user, and the domain user definitely seems to be following a different path. – Daniel Oct 7 '14 at 15:27
  • I just posted new info in the original question under Edit.1 If you can help me out more that would be great. – Daniel Oct 7 '14 at 15:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.