Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

pthreds vs gthreds anyone?

47 views
Skip to first unread message

Steve M. Fabac Jr.

unread,
May 2, 2015, 4:51:33 PM5/2/15
to
I've been working to compile open-vm-tools under SCO with the
intention of adding the tools to a 5.0.6 VM running under
VM Player 5.0.

I know, I know, 5.0.7v exists and has SCO supplied VM Tools
but this is for a client running old old software not needing anything fancy.

The problem: This 5.0.6 VM needs only to run during business hours and be
automatically shut down before the Windows host backup runs after hours
at the end of each day.

I've set a cron job that runs "shutdown -y -g0" 20 minutes before the
Windows backup kicks off. Windows backup completes and tries to power Windows
down but can't as the 5.0.6VM is still powered up at "power down or
press any key to reboot."

My intention was to see if the open-vm=tools has the functionality to
power down the 5.0.6VM. (Maybe look into APC PowerChute which I know
will power off a 5.0.6 system when it shuts down on power loss.)

I've worked through the problems running ./configure in the open-vm-tools
directory but threads has me stumped:

checking for fcvt... yes
checking for pthread_mutex_init in -lpthread... no
configure: error: libpthread not found. Please install the libc/libpthread devel
package(s).

I have FSU Pthreds installed and see in /usr/local/lib:

libgthreads.a -> /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/lib/libgthreads.a
libgthreads.so -> /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/lib/libgthreads.so
libmalloc.a -> /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/lib/libmalloc.a

and in /usr/local/include:

pthread -> /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/include/pthread
pthread.h -> /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/include/pthread.h


If I do
# nm /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/lib/libgthreads.a | less

I see (edited for mutex):

[25] | 4732| 85|FUNC |GLOB |0 |1 |pthread_mutexattr_init
[26] | 4636| 93|FUNC |GLOB |0 |1 |pthread_mutex_getprio_ceiling
[27] | 4452| 181|FUNC |GLOB |0 |1 |pthread_mutex_setprio_ceiling
[28] | 3544| 905|FUNC |GLOB |0 |1 |pthread_mutex_destroy
[29] | 4| 12|OBJT |GLOB |0 |COMMON |pthread_mutexattr_default
[30] | 3400| 141|FUNC |GLOB |0 |1 |pthread_mutex_init
[31] | 0| 0|NOTY |GLOB |0 |UNDEF |pthread_mutex_q_adjust
[32] | 0| 0|NOTY |GLOB |0 |UNDEF |pthread_q_wakeup
[33] | 2012| 1387|FUNC |GLOB |0 |1 |pthread_mutex_unlock
[34] | 816| 1195|FUNC |GLOB |0 |1 |pthread_mutex_trylock

And

# nm /opt/K/SKUNKWARE/FSUpthreads/3.9/usr/local/lib/libgthreads.so | less
[Index] Value Size Type Bind Other Shndx Name

[1] | 0| 0|FILE |LOCL |0 |ABS |../lib/libgthreads.so
[2] | 180| 0|SECT |LOCL |0 |1 |
[3] | 3604| 0|SECT |LOCL |0 |2 |
[4] | 10916| 0|SECT |LOCL |0 |3 |
[5] | 17348| 0|SECT |LOCL |0 |4 |

To confuser things furhter there are a lot of libgthread files
under /usr/lib from gwxlibs installed from
"Supplemental Graphics, Web and X11 Libraries"

libgthread-1.2.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread-1.2.la
libgthread-1.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread-1.la
libgthread-2.0.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread-2.0.la
libgthread-2.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread-2.la
libgthread.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.la
libgthread1.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread1.la
libgthread2.la -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread2.la
libgthread-1.2.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.1.2
libgthread-1.2.so.2 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.1.
libgthread-1.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.1.2
libgthread-2.0.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.0
libgthread-2.0.so.0 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.
libgthread-2.0.so.2 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.
libgthread-2.0.so.800 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.
libgthread-2.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.0
libgthread.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.0
libgthread.so.1 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.1.2
libgthread.so.1.2 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.1.2
libgthread.so.2.0 -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.0
libgthread1.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.1.2
libgthread2.so -> /opt/K/SCO/gwxlibs/2.1.0Ce/usr/lib/libgthread.so.2.0


So

./configure --without-xmlsecurity --without-pam --without-x

does not see the FSU Pthreads 3.9 files or FSU Pthreads fails the validation test
in configure and configure is too dumb to differentiate "not found" or "failed."

In fairness the configure message:
> checking build system type... i686-pc-sco3.2v5.0.7
> checking host system type... i686-pc-sco3.2v5.0.7
> checking build system type... (cached) i686-pc-sco3.2v5.0.7
> configure: WARNING: This is an untested and unsupported Operating System. Proceed at your own peril.

Should be all the clue I need to drop this effort.

But I'd invite any suggestions on how to patch the configure file or move(symlink) FSU Pthreads
files to standard locations that should satisfy the configure script.

--
Steve Fabac
S.M. Fabac & Associates
816/765-1670

Steve M. Fabac Jr.

unread,
May 6, 2015, 10:47:28 AM5/6/15
to
I received a direct e-mail from Bob Bailin
>
> Hi Steve,
>
> I'll keep this short because I don't know if this email works.
>
> It is possible on certain systems to use the built-in APM to shut
> off the power during shutdown by configuring one of the APM files,
> i.e., switching to state 0 powered the system off.
>
> This used to work on 5.0.6 but stopped working on 5.0.7 when we upgraded years ago.
>
> Let me know if you get this.
>
> Bob Bailin
> Hamden, CT

I responded to Bob's e-mail address but that bounced back after three days.
So I'm posting my testing with APM:


Bob,

Can you provide example of the APM configuration that used to work on 5.0.6?

I've done a man search on APM and tried some things but in the end, I see
the note: BIOS-APM unusable; APM segment mapping includes page 0. So it looks
like a no-go with APM on VMWarePlayer 5.0

Read on for what I tried.

I ran scoadmin -> Hardware/Kernel -> Power Management (PM) and select 1) below:


Power Management Initialization Program

1. Add Power Management modules to the kernel,
and Power Management utilities to the system
2. Remove Power Management modules from the kernel

Select an option or enter q to quit:

relinked the kernel and rebooted. When I execute pwrsh I see the following:

# /etc/pwr/bin/pwrsh -v
* status
status
status: pwr: Cannot call: /dev/pwr/pm (Power Management STREAMS): I/O error (error 5)
*
My reading on the man pages indicates that the following should work:

/etc/pwr/bin/pwrsh -v -c "state -o all"

but I see:

# /etc/pwr/bin/pwrsh -v -c "state -o all"
state -o all
state: Line 1: pwr: Cannot call: /dev/pwr/pm (Power Management STREAMS): I/O err
or (error 5)
#

This is being tested on the 5.0.6VM running under VMWare Player 5.0.1 build-894247

# /etc/pwr/bin/hasapm -c
Connected to BIOS-APM firmware at boot time
#

# /etc/pwr/bin/hasapm -A
A/C mains power (at boot time):
Running on A/C mains power (not batteries)
#

# /etc/pwr/bin/hasapm -P
Operational parameters:
16-bit Protected Mode supported
32-bit Protected Mode supported

# /etc/pwr/bin/hasapm -V
PM version 1.2 (0x102)

# /etc/pwr/bin/hasapm -u
BIOS-APM unusable; APM segment mapping includes page 0
#

From SCO osr507doc:

> Limitations
>
> BIOS-APM firmware from different manufacturers varies
> considerably in both operation and efficacy. What may
> be a safe or useful sequence of commands on one machine
> may be ineffectual or worse on another.
>
> If you see the warning:
>
> WARNING:uapm: uapm_mkpgtab - APM PM Mapping includes page 0
>
> displayed at boot-time, this version of the APM bios cannot
> cooperate with the operating system when making power management
> decisions. The driver can be removed from the link kit; the machine
> will continue to use power management, but will not inform the
> operating system when it does so.

I tried setting the VMWare "Cache System BIOS area" from "write Protect"
to "uncached" but that made no difference.
0 new messages