[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference azur::mcc

Title:DECmcc user notes file. Does not replace IPMT.
Notice:Use IPMT for problems. Newsletter location in note 6187
Moderator:TAEC::BEROUD
Created:Mon Aug 21 1989
Last Modified:Wed Jun 04 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:6497
Total number of notes:27359

1751.0. "PhaseIV AM usage of Phase4Address instance bugs" by SWORD1::ES (Eugene Shvartsman) Thu Oct 31 1991 15:11

When I'm calling PhaseIV AM with NODE4 entity built with Phase4Address instance,
where area portion of address is 0, then the AM will crush with the error:

	%SYSTEM-F-ACCVIO, access violation.

I am not saying that I'm doing something bright by making such call, but still
I din't expect the result. My expectation has been some kind of specialized
exception, or return of information about the node with this address in the
local area, but not crush.

BTW, if the local address portion is 0 too, in this case I will have the
specialized exception "Cluster Alias Not Supported", and returns me the address
of the node on which I have issued this mcc_call_access. But we don't have
a Cluster Alias on our cluster at all. So, I susspect, that some other exception
should be returned in this case, or better yet just the information about the
node on which this call has been made.

Best regards,
Gene
T.RTitleUserPersonal
Name
DateLines
1751.1need to see your AES entity specifierTOOK::JEAN_LEEFri Nov 01 1991 18:1514
    
    Hi,
           
    	Please help me to understand the circumstance better.
    
        Can you show me how you built the AES entity structure and the 
    	phase4address instance descriptor before the mcc_call_access?   
    	This will help me to determine whether the input AES entity
    	specifier is properly built or there is something that DNA4 
    	does not handle properly.
    
    	Thanks.
    
    	Jean 
1751.2here is the complete sourceSWORD1::ESEugene ShvartsmanFri Nov 01 1991 20:58155
Jean,

Below you will find to files: one is complete source code and another is the
.COM file which I use to compile and link this program.

This program will prompt you for area and local address.

If you enter for them something reasonable, say 55 and 837 as for SWORD1,
you will receive nice dump of identifier attributes.

If you enter 0 and 0, you will receive the specialized exception 372 -
"Cluster Alias Not Supported", and the address of the node on which you have
used this program, assuming that it is the PhaseIV node.

If you enter 0 and anything between 1 and 1023, responce will depend on the
values in your local database on god knows what else, but so far I have got
the following (for different local address values):

       %SYSTEM-F-ACCVIO, access violation.

       EXCEPTION Invalid Login Information= 307 :
                SYMBOL = DN4_INVAL_LOGIN,
                TEXT = "Access control information invalid at Node",

      EXCEPTION Not Currently Reachable = 320 :
                SYMBOL = DN4_NOT_CURR_REACH,
                TEXT = "Node not currently accessible.",

It seems to me that access violation will occur when you do have perfectly
valid entry in you local database and you are able to access such node without
any problem if you supply area value.

Best regards,
Gene

#include <stdio.h>

#include <mcc_descrip.h>
#include <mcc_vea_def.h>
#include <mcc_interface_def.h>
#include <mcc_msg.h>

#include <mcc_dna4_am_node4_svc_if.h>

main()
{
#define OUT_P_SIZE	1024

    int area;
    int loc_addr;
    int step;
    MCC_T_CVR status;
    MCC_T_UNSLONG wildtype;
    MCC_T_UNSLONG time_dt;
    MCC_T_Phase4Address phase4_address;
    MCC_T_UNSLONG verb = MCC_K_VERB_SHOW;
    MCC_T_UNSLONG attribute = MCC_K_ATTR_PRT_IDENTIFIER;
    MCC_T_IDCode class;
    char out_p_buffer[OUT_P_SIZE];
    MCC_T_Descriptor desc;
    MCC_A_AES p_in_entity;
    MCC_A_AES p_out_entity;
    MCC_T_Descriptor *p_time_stamp;
    MCC_A_HANDLE p_handle;

#define MAXSTEP 5

    printf("Enter area: ");
    fscanf(stdin, "%d", &area);
    printf("Enter local address: ");
    fscanf(stdin, "%d", &loc_addr);

    phase4_address.p4a_r_fill_0.p4a_W_Phase4Address =
				(unsigned short) (area * 1024 + loc_addr);

    desc.mcc_w_maxstrlen	= sizeof(MCC_T_Phase4Address);
    desc.mcc_b_dtype		= DSC_K_DTYPE_WU;
    desc.mcc_b_class		= DSC_K_CLASS_S;
    desc.mcc_a_pointer		= (unsigned char *) (&phase4_address);
    desc.mcc_w_curlen		= desc.mcc_w_maxstrlen;
    desc.mcc_b_flags		= 0;
    desc.mcc_b_ver		= MCC_K_VER_DESCRIPTOR;
    desc.mcc_l_id		= MCC_K_DN4_NI_NODE_ADDR;
    desc.mcc_l_dt		= MCC_K_DT_PHASE4ADDRESS;
    desc.mcc_a_link		= MCC_K_NULL_PTR;

    step = 1;
    do switch (step++) {
      case 1:
	p_in_entity = MCC_K_NULL_PTR;
	class = MCC_K_CLASS_DECNET_NODE;
	wildtype = MCC_K_AES_NOT_WILD;
	status = mcc_aes_create(&p_in_entity, &class, &desc, &wildtype);
	break;

      case 2:
	p_out_entity = MCC_K_NULL_PTR;
	status = mcc_aes_create(&p_out_entity, &class, &desc, &wildtype);
	break;

      case 3:
	p_time_stamp = MCC_K_NULL_PTR;
	time_dt = MCC_K_DT_BIN_ABS_TIM;
	status = mcc_time_create(&p_time_stamp, &time_dt,
				MCC_K_NULL_PTR,		/* init_time_len */
				MCC_K_NULL_PTR);	/* init_time_val */
	break;

      case 4:
	p_handle = MCC_K_NULL_PTR;
	status = mcc_ahs_create(&p_handle);
	break;

      case 5:
	desc.mcc_w_maxstrlen	= OUT_P_SIZE;
	desc.mcc_b_dtype	= DSC_K_DTYPE_T;
	desc.mcc_b_class	= DSC_K_CLASS_S;
	desc.mcc_a_pointer	= (unsigned char *) out_p_buffer;
	desc.mcc_w_curlen	= desc.mcc_w_maxstrlen;
	desc.mcc_b_flags	= 0;
	desc.mcc_b_ver		= MCC_K_VER_DESCRIPTOR;
	desc.mcc_l_id		= 0;
	desc.mcc_l_dt		= MCC_K_DT_ILV;
	desc.mcc_a_link		= MCC_K_NULL_PTR;

	status = mcc_call_access(&verb,
				p_in_entity,
				&attribute,
				MCC_K_NULL_PTR,	/* time_spec: do it NOW */
				MCC_K_NULL_PTR,		/* p_in_q */
				MCC_K_NULL_PTR,		/* p_in_p */
				p_handle,
				p_out_entity,
				p_time_stamp,
				&desc,			/* out_p */
				MCC_K_NULL_PTR);	/* out_q_p */

	if ((status == MCC_S_RESPONSE) ||
		(status = MCC_S_COMMON_EXCEPTION) ||
		(status = MCC_S_SPECIALIZED_EXCEPTION) )
	    status = mcc_ilv_dump(&desc);		/* dump out_p */
    } while ((step <= MAXSTEP) && (status == MCC_S_NORMAL));

    if (status != MCC_S_NORMAL)
	printf("\nBad status %d on step %d", status, step-1);

    exit(1);
}

$ cc/list/show=inc/stan=port/debug/noopt 'P1'
$ LINK /deb 'P1', SYS$INPUT/OPTIONS
sys$library:MCC_KERNEL_INIT.OBJ
SYS$SHARE:VAXCRTL/SHARE
SYS$SHARE:MCC_KERNEL_SHR/SHARE
$ EXIT