From:	MERC::"uunet!CRVAX.SRI.COM!RELAY-INFO-VAX" 30-MAY-1992 21:45:58.25
To:	info-vax@kl.sri.com
CC:	
Subj:	Backup saveset block size

>Apologies if this is a FAQ...I'm having difficulty restoring VMS BACKUP
>save sets that I've downloaded via FTP.  So far, I've tried restoring
>three or four different save sets, using the command "BACKUP
><infile>/SAVE_SET <directory>", and am always getting the error message,
>"%BACKUP-E-INVBLKSIZE, invalid block size in save set".  I've tried
>using various values (2048, 8192, 32256, etc.) with the /BLOCK_SIZE
>qualifier; didn't make any difference.  I am downloading the files in
>IMAGE (binary) format, using a mVAX 3600 running VMS V5.4-2.
>
>Please e-mail any replies to me; I'll summarize to the net if it seems
>worthwhile.
>--
>Kimberly B. Churchwell, Prog./Analyst, Okla. State U.  | TANSTAAFL, but
>Osteopathic College--churchwell@vms.ocom.okstate.edu   | even so, I never
>BIX--kchurchwell  AOL--KChurchwel  CIS--72170,1552     | quit hoping.
>

You will need a program (DEC does not supply one) which will reblock the file. 
 You can eitehr get one by anonymous ftp from a VMS archieve site or use the 
program enclosed below.

You can do a BACKUP/LIST filename/SAVE/NOASSIST to find out the actual block 
size you shulld block it.  At the error message type QUIT.  If you do not give 
/NOASSIST, the "operator" will get the error message.

the /BLOCK_SIZE qulaifier is applicable only for output savesets, not input 
savesets.

  Sanjay Kapur    (SK54)              |Internet:    Sanjay.Kapur@sunysb.edu
  Systems Staff, Computing Services,  |Bitnet:      SKAPUR@USB
  State University of New York,       |SPAN/HEPnet: 44132::SKAPUR
  Stony Brook, NY 11794-2400        |Phone:+1-516 632 8029, FAX:+1-516 632 8046

      INCLUDE '($FABDEF)'
      INCLUDE '($RMEDEF)'
      RECORD /FABDEF/ MYFAB
      INTEGER*4 LENGTH, STATUS, SYS$OPEN, SYS$CLOSE, SYS$MODIFY, BLKSIZ
      BYTE FILENAME(80)
      MYFAB.FAB$B_BID = FAB$C_BID
      MYFAB.FAB$B_BLN = FAB$C_BLN
      MYFAB.FAB$L_FNA = %LOC(FILENAME)
      MYFAB.FAB$B_FAC = FAB$M_PUT
      MYFAB.FAB$L_FOP = IOR(FAB$M_ESC,MYFAB.FAB$L_FOP)
      MYFAB.FAB$L_CTX = IOR(RME$C_SETRFM,MYFAB.FAB$L_CTX)
      MYFAB.FAB$W_IFI = 0
      TYPE *,'REBLOCK -- change block size of VMS binary files'
1     TYPE 5, 'New blocksize: '
5     FORMAT(1X,A,$)
      ACCEPT *, BLKSIZ
      IF(BLKSIZ .LT. 1 .OR.BLKSIZ .GT. 32767) THEN
        TYPE *,' Blocksize must be between 1 and 32767 inclusive.'
        GOTO 1
      ENDIF
      TYPE *, 'Enter filename(s) with Ctl-Z or blank line to terminate'
10    TYPE 5, 'Filename: '
      READ(5,20,END=999) LENGTH, (FILENAME(I), I = 1, LENGTH)
20    FORMAT(Q, 80A1)
      IF (LENGTH .EQ. 0) GO TO 999
      MYFAB.FAB$B_FNS = LENGTH
      STATUS = SYS$OPEN(MYFAB, %VAL(0),%VAL(0))
      IF (IAND(STATUS, 7) .NE. 1) TYPE *, ' OPEN ERROR. STATUS = ', status
      MYFAB.FAB$W_MRS = BLKSIZ
      STATUS = SYS$MODIFY(MYFAB, %VAL(0), %VAL(0))
      IF (IAND(STATUS, 7) .NE. 1) TYPE *, ' MODIFY ERROR. STATUS = ', status
      STATUS = SYS$CLOSE(MYFAB, %VAL(0), %VAL(0))
      IF (IAND(STATUS, 7) .NE. 1) TYPE *, ' CLOSE ERROR. STATUS = ', status
      GOTO 10
999   END

