COMPILATION LISTING OF SEGMENT restructure_mrds_db Compiled by: Multics PL/I Compiler, Release 29, of July 28, 1986 Compiled at: Honeywell Multics Op. - System M Compiled on: 10/16/86 1340.7 mst Thu Options: optimize map 1 /****^ *********************************************************** 2* * * 3* * Copyright, (C) Honeywell Information Systems Inc., 1982 * 4* * * 5* *********************************************************** */ 6 7 restructure_mrds_db: rmdb: proc; 8 9 10 11 /****^ HISTORY COMMENTS: 12* 1) change(85-12-03,Spitzer), approve(85-12-03,MCR7311), 13* audit(86-09-15,Gilcrease), install(86-10-16,MR12.0-1187): 14* initialize added ctl_info fields, change hardcoded path to 15* mrds_data_$rmdb_info_directory. Add -force/-no_force and -relation_type 16* control arguments. 17* END HISTORY COMMENTS */ 18 19 20 /* 21* . BEGIN_DESCRIPTION 22* This command is used to enter the restructure_mrds_db (rmdb) 23* subsystem. It sets up a subsystem environment as determined by 24* control arguments and then enters the subsystem by calling 25* ssu_$listen. 26* . END_DESCRIPTION 27* 28* Known Bugs: 29* 30* Other Problems: 31* 32* . HISTORY 33* 82-03-09 Davids: Written 34* 35* 82-04-27 Davids: to create a new directory under the user 36* . supplied temp dir or the pdir and use that new 37* . dir as the temp dir. This allows cleanups to be 38* . very simple, safe and complete - just delete 39* . the created temp dir. 40* 41* 82-05-03 Davids: modified so that the request ready_db is called 42* . via ssu_$execute_string if a database path is 43* . supplied on the rmdb command line. 44* 45* 82-06-01 Davids: modified so that abbrev is off by default 46* 47* 82-06-07 Davids: modified so that negative quiesce_wait_times are 48* . handled correctly as are times larger than those 49* . that can fit in a fixed bin variable (>131071). 50* . Also so that -profile imples -abbrev and so that 51* 52* . if a wait time is supplied but a database path 53* . is not an error is reported. 54* 55* 82-06-09 Harvey: modified so that iteration will always be done 56* . by ssu_. 57* 58* 82-06-22 Davids: removed some declared by never referenced 59* . variables, declared some variables that were 60* . being implicitly declared and changed some line 61* . formats to prevent wrap-arround. 62* 63* 82-07-15 Davids: modified so that the prompt_string is not 64* . assigned from the arg if the arg is longer than 65* . the prompt string. instead it is assign from a 66* . substr. This prevents a stringsize condition. 67* 68* 82-10-19 Harvey: modified to allow db path to be anywhere on the 69* . rmdb command line without the -pn argument. 70* 71* 83-05-24 Davids: Modified call to rmdb_free_db in the internal proc 72* clean_up to include the rmdb_control.saved_res_version_ptr argument 73* 74* 83-10-04 Benjamin: Added call to ssu_$add_request_table. 75* 76* 84-09-10 Thanh Nguyen: Modified call ssu_requests_$standard_requests 77* to ssu_request_tables_$standard_requests. 78* 79* 84-10-23 Paul Benjamin: Changed to only call free_db if rmdb readied it to 80* begin with. Added call to ssu_$add_info_dir. 81* 82* 85-01-23 Paul Benjamin: Fixed the bug where the temp_dir always has ring 83* brackets of 4,4. Now uses (V,V) where V = validation level. 84**/ 85 86 /* COMMAND ARGUMENTS (based) */ 87 88 dcl arg char (arg_len) based (arg_ptr); 89 90 /* EXTERNAL STATIC */ 91 92 dcl error_table_$bad_arg fixed bin (35) external static; 93 dcl error_table_$badcall fixed bin (35) external static; 94 dcl error_table_$bad_conversion fixed bin (35) external static; 95 dcl error_table_$bigarg fixed bin (35) external static; 96 dcl error_table_$inconsistent fixed bin (35) ext static; 97 dcl error_table_$noarg fixed bin (35) external static; 98 dcl error_table_$not_act_fnc fixed bin (35) external static; 99 dcl iox_$user_input ptr external static; 100 dcl mrds_data_$rmdb_info_directory char (168) ext static; 101 dcl rmdb_rq_tb_$rmdb_rq_tb_ fixed bin (35) external static; 102 dcl ssu_et_$subsystem_aborted fixed bin (35) external static; 103 dcl ssu_info_directories_$standard_requests char (168) external; 104 dcl ssu_request_tables_$standard_requests bit (36) aligned external static; 105 dcl sys_info$max_seg_size fixed bin (35) external static; 106 107 /* ENTRIES */ 108 109 dcl absolute_pathname_ entry (char (*), char (*), fixed bin (35)); 110 dcl active_fnc_err_ entry options (variable); 111 dcl com_err_ entry () options (variable); 112 dcl cu_$af_arg_count entry (fixed bin, fixed bin (35)); 113 dcl cu_$arg_ptr entry (fixed bin, ptr, fixed bin (21), fixed bin (35)); 114 dcl cu_$level_get entry (fixed bin); 115 dcl cv_dec_check_ entry (char (*), fixed bin (35)) returns (fixed bin (35)); 116 dcl delete_$path entry (char (*), char (*), bit (6), char (*), fixed bin (35)); 117 dcl expand_pathname_ entry (char (*), char (*), char (*), fixed bin (35)); 118 dcl expand_pathname_$add_suffix entry (char (*), char (*), char (*), char (*), fixed bin (35)); 119 dcl get_group_id_ entry () returns (char (32)); 120 dcl get_pdir_ entry () returns (char (168)); 121 dcl hcs_$append_branchx entry (char (*), char (*), fixed bin (5), (3) fixed bin (3), char (*), fixed bin (1), 122 fixed bin (1), fixed bin (24), fixed bin (35)); 123 dcl hcs_$initiate entry (char (*), char (*), char (*), fixed bin (1), 124 fixed bin (2), ptr, fixed bin (35)); 125 dcl hcs_$make_seg entry (char (*), char (*), char (*), fixed bin (5), ptr, fixed bin (35)); 126 dcl mdbm_util_$cleanup_temp_dir entry (char (*), fixed bin (35)); 127 dcl mdbm_util_$xref_destroy entry (ptr, char (*), char (*), char (*), fixed bin (35)); 128 dcl rmdb_free_db entry (char (168), ptr, char (500), fixed bin (35)); 129 dcl ssu_$add_info_dir entry (ptr, char (*), fixed bin, fixed bin (35)); 130 dcl ssu_$add_request_table entry (ptr, ptr, fixed bin, fixed bin (35)); 131 dcl ssu_$create_invocation entry (char (*), char (*), ptr, ptr, char (*), ptr, fixed bin (35)); 132 dcl ssu_$destroy_invocation entry (ptr); 133 dcl ssu_$execute_line entry (ptr, ptr, fixed bin (21), fixed bin (35)); 134 dcl ssu_$execute_string entry (ptr, char (*), fixed bin (35)); 135 dcl ssu_$listen entry (ptr, ptr, fixed bin (35)); 136 dcl ssu_$print_blast entry (ptr, ptr, fixed bin, char(*) var, fixed bin(35)); 137 dcl ssu_$print_message entry options (variable); 138 dcl ssu_$set_abbrev_info entry (ptr, ptr, ptr, bit (1) aligned); 139 dcl ssu_$set_prompt entry (ptr, char (64) varying); 140 dcl ssu_$set_prompt_mode entry (ptr, bit (*)); 141 dcl unique_chars_ entry (bit (*)) returns (char (15)); 142 143 /* CONDITIONS */ 144 145 dcl cleanup condition; 146 dcl size condition; 147 148 /* INTERNAL AUTOMATIC */ 149 150 dcl abbrev_processing bit (1); /* true if abbrev processing is to be done */ 151 dcl abbrev_profile_dname char (168); /* directory name of profile to use for abbrev processing */ 152 dcl abbrev_profile_ename char (32); /* entry name of profile to use for abbrev processing */ 153 dcl abbrev_profile_expected bit (1); /* true if profile path expected as the next argument */ 154 dcl abbrev_profile_path char (168); /* profile path argument */ 155 dcl abbrev_profile_ptr ptr; /* pointer to abbrev profile */ 156 dcl abbrev_profile_supplied bit (1); /* true if profile path supplied */ 157 dcl arg_len fixed bin (21); /* length of an argument */ 158 dcl arg_ptr ptr; /* pointer to an argument */ 159 dcl code fixed bin (35); /* standard error code */ 160 dcl db_path char (168); /* database path supplied as an argument */ 161 dcl db_path_expected bit (1); /* true if a database path is expected as the next argument */ 162 dcl db_path_supplied bit (1); /* true if a database path is supllied as an argument */ 163 dcl error_message char (500); /* error message returned from rmdb_ready_db and rmdb_free_db */ 164 dcl force_sw bit (1) aligned; /* if create the db without the query */ 165 dcl i fixed bin; /* loop index */ 166 dcl nargs fixed bin; /* number of arguments the command was called with */ 167 dcl prompt_string char (64) varying; /* prompt string argument supplied by the caller */ 168 dcl prompt_string_expected bit (1); /* true if a prompt string is expected as the next argument */ 169 dcl prompt_string_supplied bit (1); /* true if a prompt string has been supplied as an argument */ 170 dcl prompting bit (1); /* true if prompting is to be done */ 171 dcl quiesce_wait_time fixed bin; /* how many seconds the caller will wait 172* to try to quiesce the database, supplied as an argument */ 173 dcl quiesce_wait_time_expected bit (1); /* true if a wait time is expected as the next argument */ 174 dcl quiesce_wait_time_supplied bit (1); /* true if a wait time has been supplied as an argument */ 175 dcl ready_request_string char (512) varying;/* string passed to ready_db request */ 176 dcl relation_type char (32); 177 dcl relation_type_expected bit (1) aligned; /* true if a relation type is expected as the next argument */ 178 dcl relation_type_supplied bit (1) aligned; /* true if a relation type has been supplied as an argument */ 179 dcl relation_modes char (256); 180 dcl request_string_expected bit (1); /* true if a request sring is expected as the next argument */ 181 dcl request_string_len fixed bin (21); /* length of the request string */ 182 dcl request_string_ptr ptr; /* pointer to the requerst string */ 183 dcl request_string_supplied bit (1); /* true if a request string has been supplied */ 184 dcl ring_array (3) fixed bin (3); /* ring brackets for the tem_dir_sub_dir_name dir */ 185 dcl sci_ptr ptr; /* subsystem control info pointer */ 186 dcl temp_dir_abs_path char (168); /* absoutute path to the user supplied temp dir or the pdir */ 187 dcl temp_dir_path char (168); /* temp dir path - needed if process dir does not have enough 188* quota to set up working space for very large databases */ 189 dcl temp_dir_path_expected bit (1); /* true if a temp dir path is expected as the next argument */ 190 dcl temp_dir_path_supplied bit (1); /* true if a temp dir path has been supplied as an argument */ 191 dcl temp_dir_sub_dir_name char (32); /* name of the dir created under the temp_dir_abs_path which 192* will house all the temp segments */ 193 dcl validation_level fixed bin; /* the user's current validation level */ 194 dcl 01 rmdb_control like rmdb_ctl; /* automatic copy of the rmdb_ctl structure */ 195 196 /* CONSTANTS */ 197 198 dcl BLAST_MESSAGE char (72) varying init ( 199 "Type ""help rmdb"" to review new features in restructure_mrds_db."); 200 dcl LAST_IN_SEQUENCE fixed bin internal static options (constant) init (9999); 201 /* passed to ssu to put standard_requests stuff last */ 202 dcl MAX_PROMPT_STRING_LEN fixed bin internal static options (constant) init (64); 203 /* maximum length of the prompt string */ 204 dcl OFF bit (1) internal static options (constant) init ("0"b); 205 dcl ON bit (1) internal static options (constant) init ("1"b); 206 dcl PROC_NAME char (4) internal static options (constant) init ("rmdb"); 207 /* use the shorter of the two names to keep messages short */ 208 209 /* BUILTINS */ 210 211 dcl addr builtin; 212 dcl char builtin; 213 dcl empty builtin; 214 dcl index builtin; 215 dcl null builtin; 216 dcl rtrim builtin; 217 dcl substr builtin; 218 dcl verify builtin; 219 220 /* BASED */ 221 222 dcl work_area area (sys_info$max_seg_size) based (rmdb_control.work_area_ptr); 223 224 /* INCLUDE FILES */ 225 1 1 /* BEGIN INCLUDE FILE ... access_mode_values.incl.pl1 1 2* 1 3* Values for the "access mode" argument so often used in hardcore 1 4* James R. Davis 26 Jan 81 MCR 4844 1 5* Added constants for SM access 4/28/82 Jay Pattin 1 6* Added text strings 03/19/85 Chris Jones 1 7**/ 1 8 1 9 1 10 /* format: style4,delnl,insnl,indattr,ifthen,dclind10 */ 1 11 dcl ( 1 12 N_ACCESS init ("000"b), 1 13 R_ACCESS init ("100"b), 1 14 E_ACCESS init ("010"b), 1 15 W_ACCESS init ("001"b), 1 16 RE_ACCESS init ("110"b), 1 17 REW_ACCESS init ("111"b), 1 18 RW_ACCESS init ("101"b), 1 19 S_ACCESS init ("100"b), 1 20 M_ACCESS init ("010"b), 1 21 A_ACCESS init ("001"b), 1 22 SA_ACCESS init ("101"b), 1 23 SM_ACCESS init ("110"b), 1 24 SMA_ACCESS init ("111"b) 1 25 ) bit (3) internal static options (constant); 1 26 1 27 /* The following arrays are meant to be accessed by doing either 1) bin (bit_value) or 1 28* 2) divide (bin_value, 2) to come up with an index into the array. */ 1 29 1 30 dcl SEG_ACCESS_MODE_NAMES (0:7) init ("null", "W", "E", "EW", "R", "RW", "RE", "REW") char (4) internal 1 31 static options (constant); 1 32 1 33 dcl DIR_ACCESS_MODE_NAMES (0:7) init ("null", "A", "M", "MA", "S", "SA", "SM", "SMA") char (4) internal 1 34 static options (constant); 1 35 1 36 dcl ( 1 37 N_ACCESS_BIN init (00000b), 1 38 R_ACCESS_BIN init (01000b), 1 39 E_ACCESS_BIN init (00100b), 1 40 W_ACCESS_BIN init (00010b), 1 41 RW_ACCESS_BIN init (01010b), 1 42 RE_ACCESS_BIN init (01100b), 1 43 REW_ACCESS_BIN init (01110b), 1 44 S_ACCESS_BIN init (01000b), 1 45 M_ACCESS_BIN init (00010b), 1 46 A_ACCESS_BIN init (00001b), 1 47 SA_ACCESS_BIN init (01001b), 1 48 SM_ACCESS_BIN init (01010b), 1 49 SMA_ACCESS_BIN init (01011b) 1 50 ) fixed bin (5) internal static options (constant); 1 51 1 52 /* END INCLUDE FILE ... access_mode_values.incl.pl1 */ 226 227 2 1 /* BEGIN - mrds_rmdb_ctl.incl.pl1 */ 2 2 2 3 2 4 2 5 /****^ HISTORY COMMENTS: 2 6* 1) change(82-03-26,Davids), approve(), audit(), install(): 2 7* created 2 8* 2) change(82-05-26,Davids), approve(), audit(), install(): 2 9* added db_model_ptr 2 10* 3) change(82-06-09,Harvey), approve(), audit(), install(): 2 11* deleted ssu_ routines ptr storage 2 12* 4) change(82-08-20,Davids), approve(), audit(), install(): 2 13* added the relmgr like reference and included the rmdb_relmgr_entries 2 14* include file 2 15* 5) change(83-05-24,Davids), approve(), audit(), install(): 2 16* added the saved_res_version_ptr element 2 17* 6) change(84-10-23,Benjamin), approve(), audit(), install(): 2 18* added flags (just database_readied_by_rmdb for now). 2 19* 7) change(85-11-08,Spitzer), approve(85-11-08,MCR7311), 2 20* audit(86-09-02,Blair), install(86-10-16,MR12.0-1187): 2 21* added crossref_file_info. 2 22* END HISTORY COMMENTS */ 2 23 2 24 2 25 dcl 01 rmdb_ctl based (rmdb_ctl_ptr), 2 26 02 version fixed bin, 2 27 02 rmdb_version char (16) varying, 2 28 02 absolute_db_path char (168), 2 29 02 temp_dir_path char (168), 2 30 02 work_area_ptr ptr, 2 31 02 db_model_ptr ptr, 2 32 02 saved_res_version_ptr ptr, 2 33 02 crossref_file_info, 2 34 03 iocb_ptr ptr, 2 35 03 name char (32), 2 36 02 relmgr_entries like rmdb_relmgr_entries, 2 37 02 flags, 2 38 03 database_readied_by_rmdb bit (1) unal, 2 39 03 unused bit (35) unal; 2 40 2 41 dcl RMDB_CTL_VERSION_1 fixed bin init (1) internal static options (constant); 2 42 2 43 dcl rmdb_ctl_ptr ptr; 2 44 2 45 3 1 /* START OF: rmdb_relmgr_entries.incl.pl1 * * * * * * * * * * * * * * * * */ 3 2 3 3 3 4 /****^ HISTORY COMMENTS: 3 5* 1) change(82-08-20,Davids), approve(), audit(), install(): 3 6* written 3 7* 2) change(86-01-28,Spitzer), approve(86-01-28,MCR7311), 3 8* audit(86-09-15,Gilcrease), install(86-10-16,MR12.0-1187): 3 9* add get_tuples_by_spec, put_tuple, put_tuples, create_cursor entry points. 3 10* 3) change(86-08-21,Blair), approve(86-08-21,MCR7311), 3 11* audit(86-09-15,Gilcrease), install(86-10-16,MR12.0-1187): 3 12* Back out the entries get_tuples_by_spec and put_tuples since they aren't 3 13* sufficiently well tested to be reliable. Replace with get_tuple_id and 3 14* get_tuple_by_id. 3 15* END HISTORY COMMENTS */ 3 16 3 17 3 18 dcl 01 rmdb_relmgr_entries based (rmdb_relmgr_entries_ptr), 3 19 02 create_relation entry (char (*), char (*), ptr, ptr, bit (36) aligned, 3 20 bit (36) aligned, fixed bin (35)), 3 21 02 delete_relation entry (char (*), char (*), fixed bin (35)), 3 22 02 open entry (char (*), char (*), bit (36) aligned, fixed bin (35)), 3 23 02 close entry (bit (36) aligned, fixed bin (35)), 3 24 02 create_index entry (bit (36) aligned, ptr, bit (36) aligned, fixed bin (17), 3 25 bit (36) aligned, fixed bin (35)), 3 26 02 delete_index entry (bit (36) aligned, bit (36) aligned, fixed bin (35)), 3 27 02 put_tuple entry (ptr, ptr, bit (36) aligned, fixed bin (35)), 3 28 02 get_tuple_id entry (ptr, ptr, ptr, ptr, fixed bin (35)), 3 29 02 get_tuple_by_id entry (ptr, bit (36) aligned, ptr, ptr, ptr, fixed bin (35)), 3 30 02 create_cursor entry (bit (36) aligned, ptr, ptr, fixed bin (35)); 3 31 3 32 dcl rmdb_relmgr_entries_ptr ptr; 3 33 3 34 /* END OF: rmdb_relmgr_entries.incl.pl1 * * * * * * * * * * * * * * * * */ 2 46 2 47 2 48 2 49 /* END - mrds_rmdb_ctl.incl.pl1 */ 228 229 4 1 /* BEGIN INCLUDE FILE ... ssu_prompt_modes.incl.pl1 */ 4 2 /* Created: 15 February 1982 by G. Palter */ 4 3 4 4 /* Values for use in calls to ssu_$set_prompt_mode to control prompting by the subsystem listener */ 4 5 4 6 dcl PROMPT bit (1) static options (constant) initial ("0"b); 4 7 dcl DONT_PROMPT bit (1) static options (constant) initial ("1"b); 4 8 4 9 dcl PROMPT_AFTER_NULL_LINES bit (2) static options (constant) initial ("01"b); 4 10 dcl DONT_PROMPT_AFTER_NULL_LINES bit (2) static options (constant) initial ("00"b); 4 11 4 12 dcl PROMPT_IF_TYPEAHEAD bit (3) static options (constant) initial ("000"b); 4 13 dcl DONT_PROMPT_IF_TYPEAHEAD bit (3) static options (constant) initial ("001"b); 4 14 4 15 /* For example: 4 16* call ssu_$set_prompt_mode (sci_ptr, PROMPT | DONT_PROMPT_AFTER_NULL_LINES | DONT_PROMPT_IF_TYPEAHEAD); */ 4 17 4 18 /* END INCLUDE FILE ... ssu_prompt_modes.incl.pl1 */ 230 231 232 /* 233* Determine the number of arguments that this command was called 234* with, it may be called with any number. Also determine if this 235* command was called as a command or an active function. An active 236* function call is an error, it should be reported and then the 237* system exited. Since nothing has been done no cleanup is needed. 238**/ 239 240 241 242 call cu_$af_arg_count (nargs, code); 243 if code ^= error_table_$not_act_fnc 244 then do; 245 if code = 0 246 then call active_fnc_err_ (error_table_$badcall, PROC_NAME, 247 "^/This command cannot be called as an active function"); 248 else call com_err_ (code, PROC_NAME, 249 "^/An error occured while trying to determine the number of arguments"); 250 goto exit_rmdb; 251 end; 252 253 254 255 256 257 258 259 /* 260* Assign initial values. 261**/ 262 263 rmdb_control.version = RMDB_CTL_VERSION_1; /* set the version of rmdb_ctl structure */ 264 rmdb_control.rmdb_version = "2.0"; /* the version of the subsystem */ 265 rmdb_control.absolute_db_path = ""; /* no path is known yet */ 266 rmdb_control.temp_dir_path = ""; /* no temp_dir path is known */ 267 rmdb_control.work_area_ptr = null; /* no work area has been set up yet */ 268 rmdb_control.db_model_ptr = null; /* since the path is not known there is no pointer */ 269 /* the relmgr_entries will be set in rmdb_ready_db */ 270 /* and will not be used until after they are set */ 271 rmdb_control.crossref_file_info.iocb_ptr = null; /* iocb to keyed vfile containing th db crossreference */ 272 rmdb_control.crossref_file_info.name = ""; /* entryname of crossreference file */ 273 274 db_path_supplied = OFF; /* flags indicating what information */ 275 prompt_string_supplied = OFF; /* the user supplied */ 276 abbrev_profile_supplied = OFF; 277 request_string_supplied = OFF; 278 relation_type_supplied = OFF; 279 quiesce_wait_time_supplied = OFF; 280 temp_dir_path_supplied = OFF; 281 282 prompting = ON; /* states that by default are on for the subsystem */ 283 284 abbrev_processing = OFF; /* states that are off */ 285 286 db_path_expected = OFF; /* No user arguments are expected yet */ 287 prompt_string_expected = OFF; 288 abbrev_profile_expected = OFF; 289 request_string_expected = OFF; 290 relation_type_expected = OFF; 291 force_sw = OFF; 292 quiesce_wait_time_expected = OFF; 293 temp_dir_path_expected = OFF; 294 295 relation_modes = ""; 296 sci_ptr = null (); 297 298 /* 299* loop through all the user supplied arguments 1 at a time. Control 300* arguments expecting an argument set a flag indicating that that 301* argument is next, this is so that the call to cu_$arg_ptr and its 302* error handling occurs in only 1 place. The first argument is 303* special cased in that if it is not a control argument it is 304* assumed to be the database path. There are 3 kinds of arguments: 305* 306* . arguments that control the state of the subsystem, i.e. 307* . prompting on or off 308* . arguments that set values to modify the subsystem, i.e. 309* . set a new prompting string. these may also change the 310* . state of the subsystem, i.e. setting a new prompt 311* . string also turns prompting on 312* . arguments that are the new values, i.e. "new prompt:" 313* 314* Arguments may occur in any order and may be over ruled by later 315* arguments, i.e. the profile path associated with the last 316* -profile control argument will be the profile used by the 317* subsystem. 318**/ 319 320 321 322 do i = 1 to nargs; 323 call cu_$arg_ptr (i, arg_ptr, arg_len, code); 324 if code ^= 0 325 then do; 326 call com_err_ (code, PROC_NAME, "Could not get argument ^i", i); 327 goto exit_rmdb; 328 end; 329 330 if i = 1 & index (arg, "-") ^= 1 331 then db_path_expected = ON; 332 333 if db_path_expected | prompt_string_expected | abbrev_profile_expected | 334 request_string_expected | quiesce_wait_time_expected | temp_dir_path_expected | 335 relation_type_expected 336 then do; /* arguments for the control arguments */ 337 if index (arg, "-") = 1 & ^(verify (arg, "-0123456789.") = 0 & quiesce_wait_time_expected) 338 /* if a control argument is expecting an argument and */ 339 /* another control argument appears it should be reported */ 340 /* as an error, negative numbers for a wait time should */ 341 /* not be confused as a control argument */ 342 then call report_missing_args; /* expected flags are global */ 343 else 344 if db_path_expected 345 then do; 346 db_path_expected = OFF; 347 db_path_supplied = ON; 348 db_path = arg; 349 end; 350 else 351 if prompt_string_expected 352 then do; 353 prompt_string_expected = OFF; 354 prompt_string_supplied = ON; 355 if arg_len <= MAX_PROMPT_STRING_LEN 356 then prompt_string = arg; 357 else do; 358 prompt_string = substr (arg, 1, MAX_PROMPT_STRING_LEN); 359 call com_err_ (error_table_$bigarg, PROC_NAME, 360 "Prompt string ^a is longer than the maximum allowed length of ^i" 361 || "^/Prompt will be truncated to ^a^/", 362 arg, MAX_PROMPT_STRING_LEN, prompt_string); 363 end; 364 end; 365 else 366 if abbrev_profile_expected 367 then do; 368 abbrev_profile_expected = OFF; 369 abbrev_profile_supplied = ON; 370 abbrev_profile_path = arg; 371 end; 372 else 373 if relation_type_expected 374 then do; 375 relation_type_expected = OFF; 376 relation_type_supplied = ON; 377 relation_type = arg; 378 if i = nargs 379 then relation_modes = ""; 380 else do; 381 call cu_$arg_ptr (i+1, arg_ptr, arg_len, code); 382 if index (arg, "-") ^= 1 383 then do; 384 relation_modes = arg; 385 i = i + 1; 386 end; 387 end; 388 end; 389 else 390 if request_string_expected 391 then do; 392 request_string_expected = OFF; 393 request_string_supplied = ON; 394 request_string_ptr = arg_ptr; 395 request_string_len = arg_len; 396 end; 397 else 398 if quiesce_wait_time_expected 399 then do; 400 quiesce_wait_time_expected = OFF; 401 quiesce_wait_time_supplied = ON; 402 on size begin; 403 call com_err_ (error_table_$bad_conversion, PROC_NAME, 404 "^/The size of the quiesce wait time ^a " || 405 "is larger than the maximum of 131071.", arg); 406 goto exit_rmdb; 407 end; 408 (size): quiesce_wait_time = cv_dec_check_ (arg, code); 409 revert size; 410 if code ^= 0 411 then do; 412 call com_err_ (error_table_$bad_conversion, PROC_NAME, 413 "Could not convert ^a into an integer representing the quiesce wait-time", 414 arg); 415 goto exit_rmdb; 416 end; 417 if quiesce_wait_time < 0 418 then do; 419 call com_err_ (error_table_$bad_conversion, PROC_NAME, 420 "^/The quiesce wait time ^a is negative, wait times must be >= 0.", arg); 421 goto exit_rmdb; 422 end; 423 end; 424 else 425 if temp_dir_path_expected 426 then do; 427 temp_dir_path_expected = OFF; 428 temp_dir_path_supplied = ON; 429 temp_dir_path = arg; 430 end; 431 end; 432 /* control arguments which expect arguments */ 433 else 434 if arg = "-prompt" | arg = "-pmt" 435 then do; 436 prompt_string_expected = ON; 437 prompting = ON; /* for this case it also sets a state */ 438 end; 439 else 440 if arg = "-profile" | arg = "-pf" 441 then do; 442 abbrev_profile_expected = ON; 443 abbrev_processing = ON; /* for this case it also sets a state */ 444 end; 445 else 446 if arg = "-pathname" | arg = "-pn" 447 then db_path_expected = ON; 448 else 449 if arg = "-request" | arg = "-rq" 450 then request_string_expected = ON; 451 else 452 if arg = "-quiesce_wait_time" | arg = "-qwt" 453 then quiesce_wait_time_expected = ON; 454 else 455 if arg = "-temp_dir" | arg = "-td" 456 then temp_dir_path_expected = ON; 457 /* control arguments which set states */ 458 else 459 if arg = "-no_prompt" | arg = "-npmt" 460 then prompting = OFF; 461 else 462 if arg = "-force" | arg = "-fc" 463 then force_sw = ON; 464 else 465 if arg = "-no_force" | arg = "-nfc" 466 then force_sw = OFF; 467 else 468 if arg = "-relation_type" | arg = "-rt" 469 then relation_type_expected = ON; 470 else 471 if arg = "-abbrev" | arg = "-ab" 472 then abbrev_processing = ON; 473 else 474 if arg = "-no_abbrev" | arg = "-nab" 475 then abbrev_processing = OFF; 476 else 477 if index (arg, "-") ^= 1 /* database path */ 478 then do; 479 db_path_supplied = ON; 480 db_path = arg; 481 end; 482 /* unknown control argument */ 483 else do; 484 call com_err_ (error_table_$bad_arg, PROC_NAME, "Argument ^i (^a) is unrecognized", i, arg); 485 goto exit_rmdb; 486 end; 487 end; 488 489 490 491 492 /* 493* Once all the arguments have been processed a check must be made 494* to be sure that all control argument arguments have been 495* supplied. Note that in general it is not necessary for a database 496* path to have been supplied unless the -path control arg was used. 497* If report_missing_args returns then no arguments were missing and 498* everything is ok. If an argument is missing report_missing_args 499* will report it and goto exit_rmdb. 500**/ 501 502 503 call report_missing_args; /* expected flags are global */ 504 505 /* 506* If a quiesce_wait_time was supplied but a database path was not 507* supplied it will be considered as an inconsistent set of arguments 508* and an error will be reported. 509**/ 510 511 if quiesce_wait_time_supplied & ^db_path_supplied 512 then do; 513 call com_err_ (error_table_$inconsistent, PROC_NAME, 514 "^/A wait time can be supplied only if a database to be readied is also supplied"); 515 goto exit_rmdb; 516 end; 517 518 /* 519* Creates a temporary directory in the user supplied temporary dir 520* or pdir if the user did not supply a temporary dir. This makes it 521* easy to cleanup after the invocation - just delete the entire 522* temp dir. 523* 524* Creates a temporary segment in the new temporary dir to be used 525* as a work area for the rmdb requests. 526* 527* The system routine get_temp_segment has not been used because it 528* always creates the segments in the pdir and the mrds routine 529* mu_temp_segments has not been used because it requires an open 530* data base. 531* 532* Note that from this point on any errors which will cause this 533* command to return to the user will have to first call the 534* clean_up procedure. Likewise a cleanup condition handler must be 535* established incase it is signaled after this point. 536**/ 537 538 539 540 on cleanup call clean_up; 541 542 if ^temp_dir_path_supplied 543 then temp_dir_abs_path = get_pdir_ (); 544 else do; 545 call absolute_pathname_ (temp_dir_path, temp_dir_abs_path, code); 546 if code ^= 0 547 then do; 548 call com_err_ (code, PROC_NAME, 549 "^/Could not determine the absolute path of the given temp_dir path (^a)", temp_dir_path); 550 goto cleanup_and_exit_rmdb; 551 end; 552 end; 553 554 temp_dir_sub_dir_name = unique_chars_ (OFF) || ".rmdb"; 555 call cu_$level_get (validation_level); 556 ring_array (*) = validation_level; 557 call hcs_$append_branchx (temp_dir_abs_path, temp_dir_sub_dir_name, SMA_ACCESS_BIN, 558 ring_array, get_group_id_ (), 1, 0, 0, code); 559 if code ^= 0 560 then do; 561 call com_err_ (code, PROC_NAME, 562 "^/Could not create the temp dir ^a>^a, in the temporary directory ^a", 563 temp_dir_abs_path, temp_dir_sub_dir_name, temp_dir_abs_path); 564 goto cleanup_and_exit_rmdb; 565 end; 566 567 rmdb_control.temp_dir_path = rtrim (temp_dir_abs_path) || ">" || temp_dir_sub_dir_name; 568 569 call hcs_$make_seg (rmdb_control.temp_dir_path, unique_chars_ ("0"b) || ".rmdb", "", 570 RW_ACCESS_BIN, rmdb_control.work_area_ptr, code); 571 if code ^= 0 572 then do; 573 call com_err_ (code, PROC_NAME, "^/Could not make a scratch segment in the dir ^a", temp_dir_abs_path); 574 goto cleanup_and_exit_rmdb; 575 end; 576 577 work_area = empty (); 578 579 /* 580* Create the subsystem invocation. 581**/ 582 583 584 585 call ssu_$create_invocation (PROC_NAME, (rmdb_control.rmdb_version), addr (rmdb_control), 586 addr (rmdb_rq_tb_$rmdb_rq_tb_), mrds_data_$rmdb_info_directory, sci_ptr, code); 587 if code ^= 0 588 then do; 589 call com_err_ (code, PROC_NAME, "Could not invoke the rmdb subsystem"); 590 goto cleanup_and_exit_rmdb; 591 end; 592 593 594 /* Add the standard request table supplied by ssu_, to get things like do, if, 595* answer, exec_com, etc. */ 596 597 call ssu_$add_request_table (sci_ptr, addr (ssu_request_tables_$standard_requests), LAST_IN_SEQUENCE, code); 598 599 if code ^= 0 600 then goto cleanup_and_exit_rmdb; 601 602 /* And the info segs for 'em */ 603 604 call ssu_$add_info_dir (sci_ptr, ssu_info_directories_$standard_requests, LAST_IN_SEQUENCE, code); 605 606 if code ^= 0 607 then goto cleanup_and_exit_rmdb; 608 609 /* 610* If a database path has been supplied then the database must be 611* readied for restructuring. 612* 613* The request level routine rmdb_rq_ready_db is called (via ssu_) 614* instead of the subroutine level rmdb_ready_db because the 615* subroutine level does not know about ssu_ and there exists the 616* possiblility that ready will have to call an rmdb request in 617* order to make an inconsistent db consistent. 618* 619* If the caller did not supply a maximum amount of time to wait for 620* the data base to be quiesced a default wait time of 10 seconds is 621* used. 622**/ 623 624 625 626 if db_path_supplied 627 then do; 628 ready_request_string = "ready_db " || rtrim (db_path); 629 630 if quiesce_wait_time_supplied 631 then ready_request_string = ready_request_string || " -quiesce_wait_time " || rtrim (char (quiesce_wait_time)); 632 633 if relation_type_supplied 634 then ready_request_string = ready_request_string || " -relation_type " || rtrim (relation_type) || " " || rtrim (relation_modes); 635 636 if force_sw 637 then ready_request_string = ready_request_string || " -force"; 638 639 call ssu_$execute_string (sci_ptr, (ready_request_string), code); 640 if code ^= 0 641 then goto cleanup_and_exit_rmdb; 642 end; 643 644 /* 645* abbrev processing is off by default. ssu will interpret a null 646* abbrev_profile_ptr to mean that the user's default profile 647* should be used. If a profile path is specified a pointer to it 648* is obtained to pass to ssu. 649**/ 650 651 652 653 if abbrev_processing 654 then do; 655 abbrev_profile_ptr = null (); 656 if abbrev_profile_supplied 657 then do; 658 call expand_pathname_$add_suffix (abbrev_profile_path, "profile", 659 abbrev_profile_dname, abbrev_profile_ename, code); 660 if code ^= 0 661 then do; 662 call com_err_ (code, PROC_NAME, "Could not expand the profile path ^a", 663 abbrev_profile_path); 664 goto cleanup_and_exit_rmdb; 665 end; 666 call hcs_$initiate (abbrev_profile_dname, abbrev_profile_ename, "", 667 0, 0, abbrev_profile_ptr, code); 668 if abbrev_profile_ptr = null () 669 then do; 670 call com_err_ (code, PROC_NAME, "Could not initiate the profile at ^a>^a", 671 abbrev_profile_dname, abbrev_profile_ename); 672 goto cleanup_and_exit_rmdb; 673 end; 674 end; 675 call ssu_$set_abbrev_info (sci_ptr, abbrev_profile_ptr, null (), "1"b); 676 end; 677 678 679 /* 680* If the user supplies a prompt string than this string is given to 681* ssu, normally ssu will use the subsystem name. Note that seting 682* the prompt string and having prompts are independent. The user 683* may set a prompt string and turn prompts off (perhaps to be 684* turned on later). 685**/ 686 /* Set up and execute print_blast. */ 687 688 call ssu_$print_blast (sci_ptr, codeptr (rmdb), 3, BLAST_MESSAGE, code); 689 690 691 if prompt_string_supplied 692 then call ssu_$set_prompt (sci_ptr, prompt_string); 693 694 if ^prompting 695 then call ssu_$set_prompt_mode (sci_ptr, DONT_PROMPT); 696 697 698 /* 699* If the user supplied a request string it is executed here. Note 700* that most errors during the execution of the request are not 701* considered as fatal errors for the whole subsystem. The error is 702* merely reported. The exception is the subsystem_aborted error 703* which does cause the subsystem to be aborted and is probably 704* caused by a quit in the request string. 705**/ 706 707 708 709 if request_string_supplied 710 then do; 711 call ssu_$execute_line (sci_ptr, request_string_ptr, request_string_len, code); 712 if code = ssu_et_$subsystem_aborted 713 then goto cleanup_and_exit_rmdb; 714 else if code ^= 0 715 then call ssu_$print_message (sci_ptr, code); 716 end; 717 718 /* 719* the call to ssu_$listen essentially puts the user at subsystem 720* request level. If listen returns with the subsystem aborted error 721* it means that either the user requested to quit or some other 722* subsystem error occured which was reported by the subsystem 723* before it returned. If some other error occured it must be 724* reported. 725* 726* Regardless of how listen returns the command must clean itself up 727* before returning to the caller. 728**/ 729 730 731 call ssu_$listen (sci_ptr, iox_$user_input, code); 732 if code ^= ssu_et_$subsystem_aborted 733 then call com_err_ (code, PROC_NAME, "Subsystem aborted abnormally"); 734 735 736 737 738 739 740 741 742 743 cleanup_and_exit_rmdb: 744 call clean_up; 745 746 exit_rmdb: 747 return; 748 749 report_missing_args: proc; 750 751 /* 752* If any of the expected flags is set it indicates that an argument 753* to a control arg has not been supplied. Report the omission to 754* the caller and exit the command. If this procedure does a return 755* it means that no arguments were missing. 756**/ 757 758 /* GLOBAL 759* 760* db_path_expected true if the next argument should be a database path 761* prompt_string_expected true if the next argument should be a prompt string 762* abbrev_profile_expected true if the next argument should be a profile path 763* relation_type_expected true if the next argument should be a relation type 764* request_string_expected true if the next argument should be a request string 765* quiesce_wait_time_expected true if the next argument should be a wait time 766* temp_dir_path_expected true if the next argument should be a temp dir path */ 767 768 769 if db_path_expected 770 then do; 771 call com_err_ (error_table_$noarg, PROC_NAME, 772 "The -pathname (-pn) control arg was given but no pathname was supplied"); 773 goto exit_rmdb; 774 end; 775 776 if prompt_string_expected 777 then do; 778 call com_err_ (error_table_$noarg, PROC_NAME, 779 "The -prompt (-pmt) control arg was given but no prompt was supplied"); 780 goto exit_rmdb; 781 end; 782 783 if abbrev_profile_expected 784 then do; 785 call com_err_ (error_table_$noarg, PROC_NAME, 786 "The -profile (-pf) control arg was given but no profile was supplied"); 787 goto exit_rmdb; 788 end; 789 790 if request_string_expected 791 then do; 792 call com_err_ (error_table_$noarg, PROC_NAME, 793 "The -request (-rq) control arg was given but no request string was supplied"); 794 goto exit_rmdb; 795 end; 796 797 if quiesce_wait_time_expected 798 then do; 799 call com_err_ (error_table_$noarg, PROC_NAME, 800 "The -quiesce_wait_time (-qwt) control arg was given but no wait time was supplied"); 801 goto exit_rmdb; 802 end; 803 804 if temp_dir_path_expected 805 then do; 806 call com_err_ (error_table_$noarg, PROC_NAME, 807 "The -temp_dir (-td) control arg was given but no temp dir path was supplied"); 808 goto exit_rmdb; 809 end; 810 811 if relation_type_expected 812 then do; 813 call com_err_ (error_table_$noarg, PROC_NAME, 814 "The -relation_type (-rt) control arg was given but no relation types was supplied"); 815 goto exit_rmdb; 816 end; 817 818 return; 819 820 end report_missing_args; 821 822 clean_up: proc; 823 824 /* 825* To exit this command the rmdb subsystem must be destroyed if it 826* has been invoked, the readied database must be freed and the temp 827* dir that was created under the users temp dir (or the pdir) must 828* be deleted. 829**/ 830 831 /* GLOBAL 832* 833* code standard error code 834* PROC_NAME the name of this command 835* rmdb_control control info structure 836* sci_ptr subsystem control info pointer */ 837 838 /* AUTOMATIC */ 839 840 dcl temp_dir_dir char (168); /* path to either the pdir or the user supplied temp dir */ 841 dcl temp_dir_name char (32); /* name of the rmdb created temp dir undet temp_dir_dir */ 842 843 844 845 846 847 if sci_ptr ^= null () 848 then call ssu_$destroy_invocation (sci_ptr); 849 850 if rmdb_control.absolute_db_path ^= "" /* this is set only if a data base has been readied */ 851 & rmdb_control.flags.database_readied_by_rmdb/* only free it if we readied it */ 852 then do; 853 call rmdb_free_db (rmdb_control.absolute_db_path, rmdb_control.saved_res_version_ptr, error_message, code); 854 if code ^= 0 855 then call com_err_ (code, PROC_NAME, error_message); 856 end; 857 858 if rmdb_control.crossref_file_info.iocb_ptr ^= null 859 then call mdbm_util_$xref_destroy (rmdb_control.crossref_file_info.iocb_ptr, 860 rmdb_control.temp_dir_path, rmdb_control.crossref_file_info.name, (""), (0)); 861 862 if rmdb_control.temp_dir_path ^= "" 863 then do; 864 call expand_pathname_ (rmdb_control.temp_dir_path, temp_dir_dir, temp_dir_name, code); 865 if code ^= 0 866 then call com_err_ (code, PROC_NAME, "^/Could not expand the temp_dir path."); 867 else do; 868 call mdbm_util_$cleanup_temp_dir (rmdb_control.temp_dir_path, (0)); 869 call delete_$path (temp_dir_dir, temp_dir_name, "101000"b, "rmdb", code); 870 if code ^= 0 871 then call com_err_ (code, PROC_NAME, "^/Could not delete the temporary directory ^a", 872 rmdb_control.temp_dir_path); 873 end; 874 end; 875 876 return; 877 878 end clean_up; 879 880 end restructure_mrds_db; SOURCE FILES USED IN THIS COMPILATION. LINE NUMBER DATE MODIFIED NAME PATHNAME 0 10/16/86 1143.2 restructure_mrds_db.pl1 >special_ldd>install>MR12.0-1187>restructure_mrds_db.pl1 226 1 04/11/85 1452.6 access_mode_values.incl.pl1 >ldd>include>access_mode_values.incl.pl1 228 2 10/16/86 1139.6 mrds_rmdb_ctl.incl.pl1 >special_ldd>install>MR12.0-1187>mrds_rmdb_ctl.incl.pl1 2-46 3 10/16/86 1140.2 rmdb_relmgr_entries.incl.pl1 >special_ldd>install>MR12.0-1187>rmdb_relmgr_entries.incl.pl1 230 4 04/13/82 1620.2 ssu_prompt_modes.incl.pl1 >ldd>include>ssu_prompt_modes.incl.pl1 NAMES DECLARED IN THIS COMPILATION. IDENTIFIER OFFSET LOC STORAGE CLASS DATA TYPE ATTRIBUTES AND REFERENCES (* indicates a set context) NAMES DECLARED BY DECLARE STATEMENT. BLAST_MESSAGE 001475 automatic varying char(72) initial dcl 198 set ref 198* 688* DONT_PROMPT 000020 constant bit(1) initial unaligned dcl 4-7 set ref 694* LAST_IN_SEQUENCE 000002 constant fixed bin(17,0) initial dcl 200 set ref 597* 604* MAX_PROMPT_STRING_LEN 000001 constant fixed bin(17,0) initial dcl 202 set ref 355 358 359* OFF 000070 constant bit(1) initial unaligned dcl 204 set ref 274 275 276 277 278 279 280 284 286 287 288 289 290 291 292 293 346 353 368 375 392 400 427 458 464 473 554* ON constant bit(1) initial unaligned dcl 205 ref 282 330 347 354 369 376 393 401 428 436 437 442 443 445 448 451 454 461 467 470 479 PROC_NAME 000005 constant char(4) initial unaligned dcl 206 set ref 245* 248* 326* 359* 403* 412* 419* 484* 513* 548* 561* 573* 585* 589* 662* 670* 732* 771* 778* 785* 792* 799* 806* 813* 854* 865* 870* RMDB_CTL_VERSION_1 constant fixed bin(17,0) initial dcl 2-41 ref 263 RW_ACCESS_BIN 000025 constant fixed bin(5,0) initial dcl 1-36 set ref 569* SMA_ACCESS_BIN 000000 constant fixed bin(5,0) initial dcl 1-36 set ref 557* abbrev_processing 000114 automatic bit(1) unaligned dcl 150 set ref 284* 443* 470* 473* 653 abbrev_profile_dname 000115 automatic char(168) unaligned dcl 151 set ref 658* 666* 670* abbrev_profile_ename 000167 automatic char(32) unaligned dcl 152 set ref 658* 666* 670* abbrev_profile_expected 000177 automatic bit(1) unaligned dcl 153 set ref 288* 333 365 368* 442* 783 abbrev_profile_path 000200 automatic char(168) unaligned dcl 154 set ref 370* 658* 662* abbrev_profile_ptr 000252 automatic pointer dcl 155 set ref 655* 666* 668 675* abbrev_profile_supplied 000254 automatic bit(1) unaligned dcl 156 set ref 276* 369* 656 absolute_db_path 6 001252 automatic char(168) level 2 packed unaligned dcl 194 set ref 265* 850 853* absolute_pathname_ 000044 constant entry external dcl 109 ref 545 active_fnc_err_ 000046 constant entry external dcl 110 ref 245 addr builtin function dcl 211 ref 585 585 585 585 597 597 arg based char unaligned dcl 88 set ref 330 337 337 348 355 358 359* 370 377 382 384 403* 408* 412* 419* 429 433 433 439 439 445 445 448 448 451 451 454 454 458 458 461 461 464 464 467 467 470 470 473 473 476 480 484* arg_len 000255 automatic fixed bin(21,0) dcl 157 set ref 323* 330 337 337 348 355 355 358 359 359 370 377 381* 382 384 395 403 403 408 408 412 412 419 419 429 433 433 439 439 445 445 448 448 451 451 454 454 458 458 461 461 464 464 467 467 470 470 473 473 476 480 484 484 arg_ptr 000256 automatic pointer dcl 158 set ref 323* 330 337 337 348 355 358 359 370 377 381* 382 384 394 403 408 412 419 429 433 433 439 439 445 445 448 448 451 451 454 454 458 458 461 461 464 464 467 467 470 470 473 473 476 480 484 char builtin function dcl 212 ref 630 cleanup 000100 stack reference condition dcl 145 ref 540 code 000260 automatic fixed bin(35,0) dcl 159 set ref 242* 243 245 248* 323* 324 326* 381* 408* 410 545* 546 548* 557* 559 561* 569* 571 573* 585* 587 589* 597* 599 604* 606 639* 640 658* 660 662* 666* 670* 688* 711* 712 714 714* 731* 732 732* 853* 854 854* 864* 865 865* 869* 870 870* com_err_ 000050 constant entry external dcl 111 ref 248 326 359 403 412 419 484 513 548 561 573 589 662 670 732 771 778 785 792 799 806 813 854 865 870 crossref_file_info 140 001252 automatic structure level 2 unaligned dcl 194 cu_$af_arg_count 000052 constant entry external dcl 112 ref 242 cu_$arg_ptr 000054 constant entry external dcl 113 ref 323 381 cu_$level_get 000056 constant entry external dcl 114 ref 555 cv_dec_check_ 000060 constant entry external dcl 115 ref 408 database_readied_by_rmdb 222 001252 automatic bit(1) level 3 packed unaligned dcl 194 set ref 850 db_model_ptr 134 001252 automatic pointer level 2 dcl 194 set ref 268* db_path 000261 automatic char(168) unaligned dcl 160 set ref 348* 480* 628 db_path_expected 000333 automatic bit(1) unaligned dcl 161 set ref 286* 330* 333 343 346* 445* 769 db_path_supplied 000334 automatic bit(1) unaligned dcl 162 set ref 274* 347* 479* 511 626 delete_$path 000062 constant entry external dcl 116 ref 869 empty builtin function dcl 213 ref 577 error_message 000335 automatic char(500) unaligned dcl 163 set ref 853* 854* error_table_$bad_arg 000010 external static fixed bin(35,0) dcl 92 set ref 484* error_table_$bad_conversion 000014 external static fixed bin(35,0) dcl 94 set ref 403* 412* 419* error_table_$badcall 000012 external static fixed bin(35,0) dcl 93 set ref 245* error_table_$bigarg 000016 external static fixed bin(35,0) dcl 95 set ref 359* error_table_$inconsistent 000020 external static fixed bin(35,0) dcl 96 set ref 513* error_table_$noarg 000022 external static fixed bin(35,0) dcl 97 set ref 771* 778* 785* 792* 799* 806* 813* error_table_$not_act_fnc 000024 external static fixed bin(35,0) dcl 98 ref 243 expand_pathname_ 000064 constant entry external dcl 117 ref 864 expand_pathname_$add_suffix 000066 constant entry external dcl 118 ref 658 flags 222 001252 automatic structure level 2 packed unaligned dcl 194 force_sw 000532 automatic bit(1) dcl 164 set ref 291* 461* 464* 636 get_group_id_ 000070 constant entry external dcl 119 ref 557 557 get_pdir_ 000072 constant entry external dcl 120 ref 542 hcs_$append_branchx 000074 constant entry external dcl 121 ref 557 hcs_$initiate 000076 constant entry external dcl 123 ref 666 hcs_$make_seg 000100 constant entry external dcl 125 ref 569 i 000533 automatic fixed bin(17,0) dcl 165 set ref 322* 323* 326* 330 378 381 385* 385 484* index builtin function dcl 214 ref 330 337 382 476 iocb_ptr 140 001252 automatic pointer level 3 dcl 194 set ref 271* 858 858* iox_$user_input 000026 external static pointer dcl 99 set ref 731* mdbm_util_$cleanup_temp_dir 000102 constant entry external dcl 126 ref 868 mdbm_util_$xref_destroy 000104 constant entry external dcl 127 ref 858 mrds_data_$rmdb_info_directory 000030 external static char(168) unaligned dcl 100 set ref 585* name 142 001252 automatic char(32) level 3 packed unaligned dcl 194 set ref 272* 858* nargs 000534 automatic fixed bin(17,0) dcl 166 set ref 242* 322 378 null builtin function dcl 215 ref 267 268 271 296 655 668 675 675 847 858 prompt_string 000535 automatic varying char(64) dcl 167 set ref 355* 358* 359* 691* prompt_string_expected 000556 automatic bit(1) unaligned dcl 168 set ref 287* 333 350 353* 436* 776 prompt_string_supplied 000557 automatic bit(1) unaligned dcl 169 set ref 275* 354* 691 prompting 000560 automatic bit(1) unaligned dcl 170 set ref 282* 437* 458* 694 quiesce_wait_time 000561 automatic fixed bin(17,0) dcl 171 set ref 408* 417 630 quiesce_wait_time_expected 000562 automatic bit(1) unaligned dcl 173 set ref 292* 333 337 397 400* 451* 797 quiesce_wait_time_supplied 000563 automatic bit(1) unaligned dcl 174 set ref 279* 401* 511 630 ready_request_string 000564 automatic varying char(512) dcl 175 set ref 628* 630* 630 633* 633 636* 636 639 relation_modes 000777 automatic char(256) unaligned dcl 179 set ref 295* 378* 384* 633 relation_type 000765 automatic char(32) unaligned dcl 176 set ref 377* 633 relation_type_expected 000775 automatic bit(1) dcl 177 set ref 290* 333 372 375* 467* 811 relation_type_supplied 000776 automatic bit(1) dcl 178 set ref 278* 376* 633 request_string_expected 001077 automatic bit(1) unaligned dcl 180 set ref 289* 333 389 392* 448* 790 request_string_len 001100 automatic fixed bin(21,0) dcl 181 set ref 395* 711* request_string_ptr 001102 automatic pointer dcl 182 set ref 394* 711* request_string_supplied 001104 automatic bit(1) unaligned dcl 183 set ref 277* 393* 709 ring_array 001105 automatic fixed bin(3,0) array dcl 184 set ref 556* 557* rmdb_control 001252 automatic structure level 1 unaligned dcl 194 set ref 585 585 rmdb_ctl based structure level 1 unaligned dcl 2-25 rmdb_free_db 000106 constant entry external dcl 128 ref 853 rmdb_relmgr_entries based structure level 1 unaligned dcl 3-18 rmdb_rq_tb_$rmdb_rq_tb_ 000032 external static fixed bin(35,0) dcl 101 set ref 585 585 rmdb_version 1 001252 automatic varying char(16) level 2 dcl 194 set ref 264* 585 rtrim builtin function dcl 216 ref 567 628 630 633 633 saved_res_version_ptr 136 001252 automatic pointer level 2 dcl 194 set ref 853* sci_ptr 001110 automatic pointer dcl 185 set ref 296* 585* 597* 604* 639* 675* 688* 691* 694* 711* 714* 731* 847 847* size 000106 stack reference condition dcl 146 ref 402 409 ssu_$add_info_dir 000110 constant entry external dcl 129 ref 604 ssu_$add_request_table 000112 constant entry external dcl 130 ref 597 ssu_$create_invocation 000114 constant entry external dcl 131 ref 585 ssu_$destroy_invocation 000116 constant entry external dcl 132 ref 847 ssu_$execute_line 000120 constant entry external dcl 133 ref 711 ssu_$execute_string 000122 constant entry external dcl 134 ref 639 ssu_$listen 000124 constant entry external dcl 135 ref 731 ssu_$print_blast 000126 constant entry external dcl 136 ref 688 ssu_$print_message 000130 constant entry external dcl 137 ref 714 ssu_$set_abbrev_info 000132 constant entry external dcl 138 ref 675 ssu_$set_prompt 000134 constant entry external dcl 139 ref 691 ssu_$set_prompt_mode 000136 constant entry external dcl 140 ref 694 ssu_et_$subsystem_aborted 000034 external static fixed bin(35,0) dcl 102 ref 712 732 ssu_info_directories_$standard_requests 000036 external static char(168) unaligned dcl 103 set ref 604* ssu_request_tables_$standard_requests 000040 external static bit(36) dcl 104 set ref 597 597 substr builtin function dcl 217 ref 358 sys_info$max_seg_size 000042 external static fixed bin(35,0) dcl 105 ref 577 temp_dir_abs_path 001112 automatic char(168) unaligned dcl 186 set ref 542* 545* 557* 561* 561* 567 573* temp_dir_dir 000100 automatic char(168) unaligned dcl 840 set ref 864* 869* temp_dir_name 000152 automatic char(32) unaligned dcl 841 set ref 864* 869* temp_dir_path 60 001252 automatic char(168) level 2 in structure "rmdb_control" packed unaligned dcl 194 in procedure "rmdb" set ref 266* 567* 569* 858* 862 864* 868* 870* temp_dir_path 001164 automatic char(168) unaligned dcl 187 in procedure "rmdb" set ref 429* 545* 548* temp_dir_path_expected 001236 automatic bit(1) unaligned dcl 189 set ref 293* 333 424 427* 454* 804 temp_dir_path_supplied 001237 automatic bit(1) unaligned dcl 190 set ref 280* 428* 542 temp_dir_sub_dir_name 001240 automatic char(32) unaligned dcl 191 set ref 554* 557* 561* 567 unique_chars_ 000140 constant entry external dcl 141 ref 554 569 validation_level 001250 automatic fixed bin(17,0) dcl 193 set ref 555* 556 verify builtin function dcl 218 ref 337 version 001252 automatic fixed bin(17,0) level 2 dcl 194 set ref 263* work_area based area dcl 222 set ref 577* work_area_ptr 132 001252 automatic pointer level 2 dcl 194 set ref 267* 569* 577 NAMES DECLARED BY DECLARE STATEMENT AND NEVER REFERENCED. A_ACCESS internal static bit(3) initial unaligned dcl 1-11 A_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 DIR_ACCESS_MODE_NAMES internal static char(4) initial array unaligned dcl 1-33 DONT_PROMPT_AFTER_NULL_LINES internal static bit(2) initial unaligned dcl 4-10 DONT_PROMPT_IF_TYPEAHEAD internal static bit(3) initial unaligned dcl 4-13 E_ACCESS internal static bit(3) initial unaligned dcl 1-11 E_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 M_ACCESS internal static bit(3) initial unaligned dcl 1-11 M_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 N_ACCESS internal static bit(3) initial unaligned dcl 1-11 N_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 PROMPT internal static bit(1) initial unaligned dcl 4-6 PROMPT_AFTER_NULL_LINES internal static bit(2) initial unaligned dcl 4-9 PROMPT_IF_TYPEAHEAD internal static bit(3) initial unaligned dcl 4-12 REW_ACCESS internal static bit(3) initial unaligned dcl 1-11 REW_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 RE_ACCESS internal static bit(3) initial unaligned dcl 1-11 RE_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 RW_ACCESS internal static bit(3) initial unaligned dcl 1-11 R_ACCESS internal static bit(3) initial unaligned dcl 1-11 R_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 SA_ACCESS internal static bit(3) initial unaligned dcl 1-11 SA_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 SEG_ACCESS_MODE_NAMES internal static char(4) initial array unaligned dcl 1-30 SMA_ACCESS internal static bit(3) initial unaligned dcl 1-11 SM_ACCESS internal static bit(3) initial unaligned dcl 1-11 SM_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 S_ACCESS internal static bit(3) initial unaligned dcl 1-11 S_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 W_ACCESS internal static bit(3) initial unaligned dcl 1-11 W_ACCESS_BIN internal static fixed bin(5,0) initial dcl 1-36 rmdb_ctl_ptr automatic pointer dcl 2-43 rmdb_relmgr_entries_ptr automatic pointer dcl 3-32 NAMES DECLARED BY EXPLICIT CONTEXT. clean_up 004321 constant entry internal dcl 822 ref 540 743 cleanup_and_exit_rmdb 004050 constant label dcl 743 ref 550 564 574 590 599 606 640 664 672 712 exit_rmdb 004054 constant label dcl 746 ref 250 327 406 415 421 485 515 773 780 787 794 801 808 815 report_missing_args 004055 constant entry internal dcl 749 ref 337 503 restructure_mrds_db 001034 constant entry external dcl 7 rmdb 001024 constant entry external dcl 7 ref 688 688 NAME DECLARED BY CONTEXT OR IMPLICATION. codeptr builtin function ref 688 688 STORAGE REQUIREMENTS FOR THIS PROGRAM. Object Text Link Symbol Defs Static Start 0 0 5634 5776 5046 5644 Length 6406 5046 142 373 566 0 BLOCK NAME STACK SIZE TYPE WHY NONQUICK/WHO SHARES STACK FRAME rmdb 1099 external procedure is an external procedure. on unit on line 402 104 on unit on unit on line 540 64 on unit report_missing_args internal procedure shares stack frame of external procedure rmdb. clean_up 166 internal procedure is called by several nonquick procedures. STORAGE FOR AUTOMATIC VARIABLES. STACK FRAME LOC IDENTIFIER BLOCK NAME clean_up 000100 temp_dir_dir clean_up 000152 temp_dir_name clean_up rmdb 000114 abbrev_processing rmdb 000115 abbrev_profile_dname rmdb 000167 abbrev_profile_ename rmdb 000177 abbrev_profile_expected rmdb 000200 abbrev_profile_path rmdb 000252 abbrev_profile_ptr rmdb 000254 abbrev_profile_supplied rmdb 000255 arg_len rmdb 000256 arg_ptr rmdb 000260 code rmdb 000261 db_path rmdb 000333 db_path_expected rmdb 000334 db_path_supplied rmdb 000335 error_message rmdb 000532 force_sw rmdb 000533 i rmdb 000534 nargs rmdb 000535 prompt_string rmdb 000556 prompt_string_expected rmdb 000557 prompt_string_supplied rmdb 000560 prompting rmdb 000561 quiesce_wait_time rmdb 000562 quiesce_wait_time_expected rmdb 000563 quiesce_wait_time_supplied rmdb 000564 ready_request_string rmdb 000765 relation_type rmdb 000775 relation_type_expected rmdb 000776 relation_type_supplied rmdb 000777 relation_modes rmdb 001077 request_string_expected rmdb 001100 request_string_len rmdb 001102 request_string_ptr rmdb 001104 request_string_supplied rmdb 001105 ring_array rmdb 001110 sci_ptr rmdb 001112 temp_dir_abs_path rmdb 001164 temp_dir_path rmdb 001236 temp_dir_path_expected rmdb 001237 temp_dir_path_supplied rmdb 001240 temp_dir_sub_dir_name rmdb 001250 validation_level rmdb 001252 rmdb_control rmdb 001475 BLAST_MESSAGE rmdb THE FOLLOWING EXTERNAL OPERATORS ARE USED BY THIS PROGRAM. alloc_char_temp cat_realloc_chars call_ext_out_desc call_ext_out call_int_this call_int_other return_mac tra_ext_1 enable_op shorten_stack ext_entry int_entry size_check_fx1 op_empty_ THE FOLLOWING EXTERNAL ENTRIES ARE CALLED BY THIS PROGRAM. absolute_pathname_ active_fnc_err_ com_err_ cu_$af_arg_count cu_$arg_ptr cu_$level_get cv_dec_check_ delete_$path expand_pathname_ expand_pathname_$add_suffix get_group_id_ get_pdir_ hcs_$append_branchx hcs_$initiate hcs_$make_seg mdbm_util_$cleanup_temp_dir mdbm_util_$xref_destroy rmdb_free_db ssu_$add_info_dir ssu_$add_request_table ssu_$create_invocation ssu_$destroy_invocation ssu_$execute_line ssu_$execute_string ssu_$listen ssu_$print_blast ssu_$print_message ssu_$set_abbrev_info ssu_$set_prompt ssu_$set_prompt_mode unique_chars_ THE FOLLOWING EXTERNAL VARIABLES ARE USED BY THIS PROGRAM. error_table_$bad_arg error_table_$bad_conversion error_table_$badcall error_table_$bigarg error_table_$inconsistent error_table_$noarg error_table_$not_act_fnc iox_$user_input mrds_data_$rmdb_info_directory rmdb_rq_tb_$rmdb_rq_tb_ ssu_et_$subsystem_aborted ssu_info_directories_$standard_requests ssu_request_tables_$standard_requests sys_info$max_seg_size LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC LINE LOC 198 001014 7 001023 242 001042 243 001053 245 001057 248 001105 250 001130 263 001131 264 001133 265 001137 266 001142 267 001145 268 001147 271 001150 272 001151 274 001154 275 001155 276 001156 277 001157 278 001160 279 001161 280 001162 282 001163 284 001165 286 001166 287 001167 288 001170 289 001171 290 001172 291 001173 292 001174 293 001175 295 001176 296 001201 322 001203 323 001213 324 001230 326 001232 327 001262 330 001263 333 001306 337 001324 343 001346 346 001350 347 001351 348 001353 349 001357 350 001360 353 001362 354 001363 355 001365 358 001400 359 001405 364 001450 365 001451 368 001453 369 001454 370 001456 371 001462 372 001463 375 001465 376 001466 377 001470 378 001474 381 001503 382 001522 384 001536 385 001541 388 001542 389 001543 392 001545 393 001546 394 001550 395 001551 396 001553 397 001554 400 001556 401 001557 402 001561 403 001575 406 001630 408 001633 409 001662 410 001663 412 001665 415 001720 417 001721 419 001723 421 001756 423 001757 424 001760 427 001762 428 001763 429 001765 431 001771 433 001772 436 002003 437 002005 438 002006 439 002007 442 002017 443 002021 444 002022 445 002023 448 002036 451 002051 454 002064 458 002077 461 002111 464 002124 467 002136 470 002151 473 002164 476 002176 479 002201 480 002203 481 002207 484 002210 485 002247 487 002250 503 002252 511 002253 513 002257 515 002303 540 002304 542 002326 545 002340 546 002360 548 002362 550 002412 554 002413 555 002443 556 002453 557 002465 559 002550 561 002552 564 002611 567 002612 569 002651 571 002734 573 002736 574 002766 577 002767 585 002773 587 003046 589 003051 590 003075 597 003076 599 003115 604 003117 606 003144 626 003146 628 003150 630 003202 633 003262 636 003366 639 003403 640 003434 653 003437 655 003441 656 003443 658 003445 660 003477 662 003501 664 003531 666 003532 668 003575 670 003601 672 003635 675 003636 688 003657 691 003713 694 003726 709 003745 711 003747 712 003764 714 003770 731 004006 732 004021 743 004050 746 004054 749 004055 769 004056 771 004060 773 004104 776 004105 778 004107 780 004133 783 004134 785 004136 787 004162 790 004163 792 004165 794 004211 797 004212 799 004214 801 004240 804 004241 806 004243 808 004267 811 004270 813 004272 815 004316 818 004317 822 004320 847 004326 850 004341 853 004351 854 004366 858 004412 862 004451 864 004456 865 004502 868 004532 869 004550 870 004606 876 004641 ----------------------------------------------------------- Historical Background This edition of the Multics software materials and documentation is provided and donated to Massachusetts Institute of Technology by Group BULL including BULL HN Information Systems Inc. as a contribution to computer science knowledge. This donation is made also to give evidence of the common contributions of Massachusetts Institute of Technology, Bell Laboratories, General Electric, Honeywell Information Systems Inc., Honeywell BULL Inc., Groupe BULL and BULL HN Information Systems Inc. to the development of this operating system. Multics development was initiated by Massachusetts Institute of Technology Project MAC (1963-1970), renamed the MIT Laboratory for Computer Science and Artificial Intelligence in the mid 1970s, under the leadership of Professor Fernando Jose Corbato. Users consider that Multics provided the best software architecture for managing computer hardware properly and for executing programs. Many subsequent operating systems incorporated Multics principles. Multics was distributed in 1975 to 2000 by Group Bull in Europe , and in the U.S. by Bull HN Information Systems Inc., as successor in interest by change in name only to Honeywell Bull Inc. and Honeywell Information Systems Inc. . ----------------------------------------------------------- Permission to use, copy, modify, and distribute these programs and their documentation for any purpose and without fee is hereby granted,provided that the below copyright notice and historical background appear in all copies and that both the copyright notice and historical background and this permission notice appear in supporting documentation, and that the names of MIT, HIS, BULL or BULL HN not be used in advertising or publicity pertaining to distribution of the programs without specific prior written permission. Copyright 1972 by Massachusetts Institute of Technology and Honeywell Information Systems Inc. Copyright 2006 by BULL HN Information Systems Inc. Copyright 2006 by Bull SAS All Rights Reserved