version of prog

Hi,
What EXE_VERSION in makefile is for?
Do you plan to add a ‘pidin version’ or ‘psin version’ feature?
Will the missing infos in psin (such as timers) available in 6.2?

Thanks,
Alain.

Since someone brought it up, I give a really big ME TOO in support of pidin
version messages. In QNX4 that was an invaluable options when connecting to
a customer system to diagnose a problem. Since we did have a number of
versions of our software out there.

Here’s another big hint, since the string displayed by ‘sin ve’ originated
in the running executable, the executable had the ability to also display
STATUS INFORMATION. Do you know how incredibly valuable it is to get status
information from a running process from any ASCII keyboard in the network?
Think about it!

“Alain Bonnefoy” <alain.bonnefoy@icbt.com> wrote in message
news:3CA94D53.3040700@icbt.com

Hi,
What EXE_VERSION in makefile is for?
Do you plan to add a ‘pidin version’ or ‘psin version’ feature?
Will the missing infos in psin (such as timers) available in 6.2?

Thanks,
Alain.

Thanks Bill and AFAIR, ‘sin ve’ was able to give the version of the
running process OR the version of the executable file by something like
‘sin ve file /…/the_exe_file’.

cheers,
Alain.

Bill Caroselli (Q-TPS) wrote:

Since someone brought it up, I give a really big ME TOO in support of pidin
version messages. In QNX4 that was an invaluable options when connecting to
a customer system to diagnose a problem. Since we did have a number of
versions of our software out there.

Here’s another big hint, since the string displayed by ‘sin ve’ originated
in the running executable, the executable had the ability to also display
STATUS INFORMATION. Do you know how incredibly valuable it is to get status
information from a running process from any ASCII keyboard in the network?
Think about it!

“Alain Bonnefoy” <> alain.bonnefoy@icbt.com> > wrote in message
news:> 3CA94D53.3040700@icbt.com> …

Hi,
What EXE_VERSION in makefile is for?
Do you plan to add a ‘pidin version’ or ‘psin version’ feature?
Will the missing infos in psin (such as timers) available in 6.2?

Thanks,
Alain.

Alain Bonnefoy <alain.bonnefoy@icbt.com> wrote:

Thanks Bill and AFAIR, ‘sin ve’ was able to give the version of the
running process OR the version of the executable file by something like
‘sin ve file /…/the_exe_file’.

Nope, that capability didn’t exist. “sin ve” walked the list of processes,
for everyone that had the “server” flag set, it would send it a message
asking for its version, and then dump the reply.

-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.

Bill, I think you were thinking of “sin fo inT”. It reports exe load/start
& file date-times.

Rob

“David Gibbs” <dagibbs@qnx.com> wrote in message
news:a8sc62$h2k$1@nntp.qnx.com

Alain Bonnefoy <> alain.bonnefoy@icbt.com> > wrote:
Thanks Bill and AFAIR, ‘sin ve’ was able to give the version of the
running process OR the version of the executable file by something like
‘sin ve file /…/the_exe_file’.

Nope, that capability didn’t exist. “sin ve” walked the list of
processes,
for everyone that had the “server” flag set, it would send it a message
asking for its version, and then dump the reply.

-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.

Not me. It was Alian that was looking for that feature.

I was simply suggesting that if you get to return a C-string, you can put
whatever you want in there.

“Rob” <rob@spamyouself.com> wrote in message
news:a8scq9$q06$1@inn.qnx.com

Bill, I think you were thinking of “sin fo inT”. It reports exe
load/start
& file date-times.

Rob

“David Gibbs” <> dagibbs@qnx.com> > wrote in message
news:a8sc62$h2k$> 1@nntp.qnx.com> …
Alain Bonnefoy <> alain.bonnefoy@icbt.com> > wrote:
Thanks Bill and AFAIR, ‘sin ve’ was able to give the version of the
running process OR the version of the executable file by something
like
‘sin ve file /…/the_exe_file’.

Nope, that capability didn’t exist. “sin ve” walked the list of
processes,
for everyone that had the “server” flag set, it would send it a message
asking for its version, and then dump the reply.

-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.

Bill Caroselli (Q-TPS) wrote:

Not me. It was Alian that was looking for that feature.

I was simply suggesting that if you get to return a C-string, you can put
whatever you want in there.

Well, in QNX6 your reply from a read() of a “/my_resmgr/status” file,
can also return anything it wants. This makes cat a run-time status
reporting utility. This is actually the technique I preferred to use in
QNX4, where “sin ve” was available.

Rennie

Sure that everything can done by ourself but I think that knowing the
version of a program is a very basic information and can justify a
‘system’ tool to do it.

Alain.

Rennie Allen wrote:

Bill Caroselli (Q-TPS) wrote:

Not me. It was Alian that was looking for that feature.

I was simply suggesting that if you get to return a C-string, you can
put
whatever you want in there.



Well, in QNX6 your reply from a read() of a “/my_resmgr/status” file,
can also return anything it wants. This makes cat a run-time status
reporting utility. This is actually the technique I preferred to use
in QNX4, where “sin ve” was available.

Rennie

What I actually did was to return normal version information on the first
‘sin ve’ request. If the process received a second sin ve request within 5
seconds it returns certain status information. If it received a third
request within a third 5 seconds it returned different status information.
It sure would have been nice if ‘sin -P myProg ve’ just returned version for
my prog.

“Alain Bonnefoy” <alain.bonnefoy@icbt.com> wrote in message
news:3CB41E1C.7030401@icbt.com

Sure that everything can done by ourself but I think that knowing the
version of a program is a very basic information and can justify a
‘system’ tool to do it.

Alain.

Rennie Allen wrote:

Bill Caroselli (Q-TPS) wrote:

Not me. It was Alian that was looking for that feature.

I was simply suggesting that if you get to return a C-string, you can
put
whatever you want in there.



Well, in QNX6 your reply from a read() of a “/my_resmgr/status” file,
can also return anything it wants. This makes cat a run-time status
reporting utility. This is actually the technique I preferred to use
in QNX4, where “sin ve” was available.

Rennie

Alain Bonnefoy wrote:

Sure that everything can done by ourself but I think that knowing the
version of a program is a very basic information and can justify a
‘system’ tool to do it.

I think you misunderstand. I have no problem with a standard version
reporting mechanism, what I was referring to was the concept of
overloading the version reporting mechanism with status reporting.

Rennie

“Bill Caroselli (Q-TPS)” <QTPS@earthlink.net> wrote:

What I actually did was to return normal version information on the first
‘sin ve’ request. If the process received a second sin ve request within 5
seconds it returns certain status information. If it received a third
request within a third 5 seconds it returned different status information.
It sure would have been nice if ‘sin -P myProg ve’ just returned version for
my prog.

Actually, Bill, you probably could have done something more interesting
with the multi-line version stuff.

sin ver out-takes:

sys/Proc32 Proc 4.25N Sep 24 2001
sys/Proc32 Slib16 4.23G Oct 04 1996
sys/Slib32 Slib32 4.24B Aug 12 1997

//61/bin/Fsys.424W Fsys32 4.24W May 04 2001
//61/bin/Fsys.424W Floppy 4.24B Aug 19 1997

In both cases, first Proc32, has told sin “here’s an answer, but
ask me for another one”, in the 2nd case Fsys has done the same –
the process can actually tell sin it has multiple pieces of version
information to return, and get to return it multiple times.

e.g.: proc_ver.c: will give:

//61//dagibbs/proc_ver test 1.00A Apr 10 2002
//61/
/dagibbs/proc_ver test 1.00A Apr 10 2002


#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
#include <errno.h>
#include <sys/sys_msg.h>
#include <sys/kernel.h>
#include <sys/proxy.h>
#include <sys/psinfo.h>

struct ver_reply {
struct _sysmsg_hdr_reply rep;
struct _sysmsg_version_reply ver;
};

void main()
{
struct _sysmsg_hdr msg;
struct _sysmsg_hdr_reply reply = {ENOSYS, 0 };
struct ver_reply ver =
{ EOK, 0, “test”, DATE, 100, ‘A’, 0 };
int pid;
int flag = 1;

qnx_pflags( _PPF_SERVER, _PPF_SERVER, NULL, NULL );

while(1)
{
pid = Receive(0, &msg , sizeof (msg) );
printf(“message form %d, type: %d, subtype: %d\n”,
pid, msg.type, msg.subtype );
if ( (msg.type == _SYSMSG) && (msg.subtype == _SYSMSG_SUBTYPE_VERSION ) )
{
ver.ver.more = flag;
flag = !flag;
Reply( pid, &ver, sizeof(ver) );
} else
Reply(pid, &reply, sizeof(reply));

}
}

Is it not nifty?

-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.

WOW! I never knew that one!

And I thought that I was a pretty good master of QNX4 gimmicks.

Thank a lot. I hope I’ll have a chance to use it one day.

“David Gibbs” <dagibbs@qnx.com> wrote in message
news:a928d0$1a2$1@nntp.qnx.com

“Bill Caroselli (Q-TPS)” <> QTPS@earthlink.net> > wrote:
What I actually did was to return normal version information on the
first
‘sin ve’ request. If the process received a second sin ve request
within 5
seconds it returns certain status information. If it received a third
request within a third 5 seconds it returned different status
information.
It sure would have been nice if ‘sin -P myProg ve’ just returned version
for
my prog.

Actually, Bill, you probably could have done something more interesting
with the multi-line version stuff.

sin ver out-takes:

sys/Proc32 Proc 4.25N Sep 24 2001
sys/Proc32 Slib16 4.23G Oct 04 1996
sys/Slib32 Slib32 4.24B Aug 12 1997

//61/bin/Fsys.424W Fsys32 4.24W May 04 2001
//61/bin/Fsys.424W Floppy 4.24B Aug 19 1997

In both cases, first Proc32, has told sin “here’s an answer, but
ask me for another one”, in the 2nd case Fsys has done the same –
the process can actually tell sin it has multiple pieces of version
information to return, and get to return it multiple times.

e.g.: proc_ver.c: will give:

//61//dagibbs/proc_ver test 1.00A Apr 10 2002
//61/
/dagibbs/proc_ver test 1.00A Apr 10 2002


#include <stdio.h
#include <unistd.h
#include <stdlib.h
#include <errno.h
#include <sys/sys_msg.h
#include <sys/kernel.h
#include <sys/proxy.h
#include <sys/psinfo.h

struct ver_reply {
struct _sysmsg_hdr_reply rep;
struct _sysmsg_version_reply ver;
};

void main()
{
struct _sysmsg_hdr msg;
struct _sysmsg_hdr_reply reply = {ENOSYS, 0 };
struct ver_reply ver =
{ EOK, 0, “test”, DATE, 100, ‘A’, 0 };
int pid;
int flag = 1;

qnx_pflags( _PPF_SERVER, _PPF_SERVER, NULL, NULL );

while(1)
{
pid = Receive(0, &msg , sizeof (msg) );
printf(“message form %d, type: %d, subtype: %d\n”,
pid, msg.type, msg.subtype );
if ( (msg.type == _SYSMSG) && (msg.subtype ==
_SYSMSG_SUBTYPE_VERSION ) )
{
ver.ver.more = flag;
flag = !flag;
Reply( pid, &ver, sizeof(ver) );
} else
Reply(pid, &reply, sizeof(reply));

}
}

Is it not nifty?

-David

QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.

There is something I don’t understand David. Are you talking about QNX4
or QRTP 6.1.
On my QRTP 6.1A, sin ve, sin ver, displays the same informations as sin!
How do you get these ones?

regards,
Alain.

David Gibbs wrote:

“Bill Caroselli (Q-TPS)” <> QTPS@earthlink.net> > wrote:

What I actually did was to return normal version information on the first
‘sin ve’ request. If the process received a second sin ve request within 5
seconds it returns certain status information. If it received a third
request within a third 5 seconds it returned different status information.
It sure would have been nice if ‘sin -P myProg ve’ just returned version for
my prog.


Actually, Bill, you probably could have done something more interesting
with the multi-line version stuff.

sin ver out-takes:

sys/Proc32 Proc 4.25N Sep 24 2001
sys/Proc32 Slib16 4.23G Oct 04 1996
sys/Slib32 Slib32 4.24B Aug 12 1997

//61/bin/Fsys.424W Fsys32 4.24W May 04 2001
//61/bin/Fsys.424W Floppy 4.24B Aug 19 1997

In both cases, first Proc32, has told sin “here’s an answer, but
ask me for another one”, in the 2nd case Fsys has done the same –
the process can actually tell sin it has multiple pieces of version
information to return, and get to return it multiple times.

e.g.: proc_ver.c: will give:

//61//dagibbs/proc_ver test 1.00A Apr 10 2002
//61/
/dagibbs/proc_ver test 1.00A Apr 10 2002


#include <stdio.h
#include <unistd.h
#include <stdlib.h
#include <errno.h
#include <sys/sys_msg.h
#include <sys/kernel.h
#include <sys/proxy.h
#include <sys/psinfo.h

struct ver_reply {
struct _sysmsg_hdr_reply rep;
struct _sysmsg_version_reply ver;
};

void main()
{
struct _sysmsg_hdr msg;
struct _sysmsg_hdr_reply reply = {ENOSYS, 0 };
struct ver_reply ver =
{ EOK, 0, “test”, DATE, 100, ‘A’, 0 };
int pid;
int flag = 1;

qnx_pflags( _PPF_SERVER, _PPF_SERVER, NULL, NULL );

while(1)
{
pid = Receive(0, &msg , sizeof (msg) );
printf(“message form %d, type: %d, subtype: %d\n”,
pid, msg.type, msg.subtype );
if ( (msg.type == _SYSMSG) && (msg.subtype == _SYSMSG_SUBTYPE_VERSION ) )
{
ver.ver.more = flag;
flag = !flag;
Reply( pid, &ver, sizeof(ver) );
} else
Reply(pid, &reply, sizeof(reply));

}
}

Is it not nifty?

-David

Alain Bonnefoy <alain.bonnefoy@icbt.com> wrote:

There is something I don’t understand David. Are you talking about QNX4
or QRTP 6.1.
On my QRTP 6.1A, sin ve, sin ver, displays the same informations as sin!
How do you get these ones?

I’m talking about QNX4. Yes, it is in the QNX6 newsgroup – but
Bill talked about doing something under QNX4 using a timeing based
(2nd sin ve within 5s getting different info) and I posted a better
way of doing this.

There isn’t a “sin ver” for QNX6.

Thena again, there also is no equivalent (that I know of) of the
_PPF_SERVER flag that you could set to say that you would understand
and respond to “sin ver” (and other system messages) either.

-David

regards,
Alain.

David Gibbs wrote:

“Bill Caroselli (Q-TPS)” <> QTPS@earthlink.net> > wrote:

What I actually did was to return normal version information on the first
‘sin ve’ request. If the process received a second sin ve request within 5
seconds it returns certain status information. If it received a third
request within a third 5 seconds it returned different status information.
It sure would have been nice if ‘sin -P myProg ve’ just returned version for
my prog.


Actually, Bill, you probably could have done something more interesting
with the multi-line version stuff.

sin ver out-takes:

sys/Proc32 Proc 4.25N Sep 24 2001
sys/Proc32 Slib16 4.23G Oct 04 1996
sys/Slib32 Slib32 4.24B Aug 12 1997

//61/bin/Fsys.424W Fsys32 4.24W May 04 2001
//61/bin/Fsys.424W Floppy 4.24B Aug 19 1997

In both cases, first Proc32, has told sin “here’s an answer, but
ask me for another one”, in the 2nd case Fsys has done the same –
the process can actually tell sin it has multiple pieces of version
information to return, and get to return it multiple times.

e.g.: proc_ver.c: will give:

//61//dagibbs/proc_ver test 1.00A Apr 10 2002
//61/
/dagibbs/proc_ver test 1.00A Apr 10 2002


#include <stdio.h
#include <unistd.h
#include <stdlib.h
#include <errno.h
#include <sys/sys_msg.h
#include <sys/kernel.h
#include <sys/proxy.h
#include <sys/psinfo.h

struct ver_reply {
struct _sysmsg_hdr_reply rep;
struct _sysmsg_version_reply ver;
};

void main()
{
struct _sysmsg_hdr msg;
struct _sysmsg_hdr_reply reply = {ENOSYS, 0 };
struct ver_reply ver =
{ EOK, 0, “test”, DATE, 100, ‘A’, 0 };
int pid;
int flag = 1;

qnx_pflags( _PPF_SERVER, _PPF_SERVER, NULL, NULL );

while(1)
{
pid = Receive(0, &msg , sizeof (msg) );
printf(“message form %d, type: %d, subtype: %d\n”,
pid, msg.type, msg.subtype );
if ( (msg.type == _SYSMSG) && (msg.subtype == _SYSMSG_SUBTYPE_VERSION ) )
{
ver.ver.more = flag;
flag = !flag;
Reply( pid, &ver, sizeof(ver) );
} else
Reply(pid, &reply, sizeof(reply));

}
}

Is it not nifty?

-David


QNX Training Services
http://www.qnx.com/support/training/
Please followup in this newsgroup if you have further questions.