Start and stop SamFS

Start and stop SamFS

1. Open up the "samu" command interface and go to "s" screen.
2. Idle the library(s) by issuing a :idle eq# where eq# is the eq of the library for each library. i.e. – 50 first then 60 in the example below
3. Idle the drives individually by issuing a :idle eq# where eq# is the eq of the drives. i.e. – 51-52, 61-62 in the example below
4. Wait until the libraries indicate idle, and all activity has stopped on the tape drives and the "on" status is replaced with "off" or "DOWN" on all drives. 5. Quit out of samu by issuing "q"
6. At the root prompt: # "samd stop" ——> All versions
7. Allow a minute or two to allow all processes to stop.
8. Verify processes that should terminate have:

# ps -ef | grep sam- ——> On 3.5 and before ensure
all sam processes are stopped, if they are not, use a kill
statement on the processes still left.
——> On 4.0
some processes will still be running

9. To start or restart samfs again, at the root prompt:
——> On 3.5 and before, # "samd start"
——> On 4.0 and later, # "samd config"

SAMFS (ASM) sample archiver.cmd

# /etc/opt/SUNWsamfs/archiver.cmd
#: john core 02-28-2007
#######################################################
# test this file with archiver -lv
# any error in this file and archiving will STOP (honest)
#
# after editing, test, rem the wait command, run samd config,
# check logs and samu
#
# without this file archiver will use defaults and go to first BU device,
# 4 minute age – no log – order found interval 10 – 1 copy
#
# archive age default for first copy (1) is 4 minutes
# archive interval default is 10 minutes.
# interval is the END of one run and the start of the next run
# interval is NOT the start of one run and the start of the next run
# file systems defined in mcf automatically have an archive set
# too many archive sets can (and will) lead to data loss!
# too many archive sets can (and will) lead to archive backlogging!
# each archive set causes robotic arm movement
###########################################################
# Guidelines for archive sets:
# tape drives archive sets max FS Max files per FS
# 2-3 1 4 6 million
# 4-5 1 6 6 million
# 6-7 2 8 8 million
# 8-10 4 10 10 million
###########################################################
# units:
# s,m,h,d,w,y = seconds,minutes,hours,days,weeks,years
# b,k,M,G,T = bytes,kilobytes,megabytes,gigabytes,terabytes
###########################################################
# devices:
# tp,dt,xm,lt,xt = generic,4mm,8mm,dlt,exabyte
# li,sg,sf,mo = 3580,stk9840,stk9940,optical
# rb,ac,s9 = generic robot, ACL, STK97xx
###########################################################
# general directives (globals)
###########################################################
#wait # tell archiver to wait (for editing)
#interval = 10m # default is 10 minutes
archivemeta = off # use samfsdump in a cron job instead!
#startage 1h # time from fs to archive
#startcount 3000 # files needed before archive starts
#startsize 150g # wait till this size is accumulated
#examine = noscan # use continous archiving (default)
#examine = scan # scan based archiving (slow)
#examine = scandirs # scan based on directories
#examine = scaninodes # scan on inodes
#archmax = li 750M # set to 10% less than tape size (default 512M)

#logfile = /var/opt/SUNWsamfs/archiver/archiver.log # don\’t forget to touch this file
logfile = /var/adm/archiver.log # don\’t forget to touch this file

###########################################################
# fs directives (samfs1)
###########################################################

fs = samfs1 # begin samfs1
#logfile = /var/adm/samfs1.log # fs specific log (optional)
1 1s # backup copy 1 after this age (metadata)
2 10m # backup copy 2 after this age
#2 -release 10m # backup copy 2 after this age release disk cache
#2 -norealse 10m # backup copy 2 after this age retain disk cache
#3 100m # backup copy 3 (default 1 copy after 4 minutes)
no_archive tmp # do not archive this directory

#foo . -user john # archive set foo, all files owned by john
#foo . -group prog # archive set foo, all files group prog
#foo . -name \\.gif$ # archive set foo, all files named *.gif
#foo . minsize 2G # archive set foo, all files 2gig or greater

work work # archive set work files in directory work
1 1h # backup copy 1 after this age
2 5h # backup copy 2 after this age

samfs_all . # archive set samfs_all all files (all directives need to be last)
1 1h 6w # backup copy 1 after this age after 6w unarchive (toss)
2 5h # backup copy 2 after this age

fs = samfs2 # begin samfs2
all . # archive set all all files

###########################################################
# end fs directives
###########################################################

params # archive set parameters
#work.1 -disk-archive jimmy1 # disk archive (v4.2) jimmy1 in diskvols.conf
allsets -drives 2 # define for all
endparams # end archive set parameters

vsns # VSN associations
samfs1.1 mo optic-2A # 1st copy to optical device type mo
samfs1.2 lt TAPE01 # 2nd copy to TAPE01 device type lt
###samfs1.3 lt TAPE01 # 3rd copy to TAPE01 device type lt
# *bad* samfs1.2+3 go to the same tape
samfs2.1 mo optic-2A # 1st copy to optical device type mo
###samfs2.2 lt TAPE01 # 2nd copy to TAPE01 device type lt
work.1 mo optic-[3-9][A-Z] # 1st work copy to optic type mo
work.2 lt .* # 2nd work copy to any lt device
samfs_all.1 mo .* # 1st copy any device mo
samfs_all.2 lt .* # 2nd copy any device lt
qfs1.1 lt .*
all.1 lt .*
endvsns # end VSN associations

Reading and writing tapes, backups, and archives with tar

Reading and writing tapes, backups, and archives: The tar command

The tar command stands for "tape archive". It is the "standard" way to read
and write archives (collections of files and whole directory trees).

Often you will find archives of stuff with names like stuff.tar, or stuff.tar.gz. This
is stuff in a tar archive, and stuff in a tar archive which has been compressed using the
gzip compression program respectivly.

Chances are that if someone gives you a tape written on a UNIX system, it will be in tar format,
and you will use tar (and your tape drive) to read it.

Likewise, if you want to write a tape to give to someone else, you should probably use
tar as well.

Tar examples:

tar xv Extracts (x) files from the default tape drive while listing (v = verbose)
the file names to the screen.
tar tv Lists the files from the default tape device without extracting them.
tar cv file1 file2
Write files ‘file1’ and ‘file2’ to the default tape device.
tar cvf archive.tar file1 [file2…]
Create a tar archive as a file "archive.tar" containing file1,
file2…etc.
tar xvf archive.tar extract from the archive file
tar cvfz archive.tar.gz dname
Create a gzip compressed tar archive containing everything in the directory
‘dname’. This does not work with all versions of tar.
tar xvfz archive.tar.gz
Extract a gzip compressed tar archive. Does not work with all versions of tar.
tar cvfI archive.tar.bz2 dname
Create a bz2 compressed tar archive. Does not work with all versions of tar

Find files on tape from SAMFS (ASM) log file

save as samffot and changemod to 755. Edit archiver log location to suit your system

#!/bin/sh
#: john core 03-01-2007
## samffot – samfs find file on tape
####################################
if [ "$1" = "" ]
then
echo "usage: $0 filename"
exit
fi
DEV=`grep $1 /var/adm/archiver.log|tail -1|awk ‘{print $4}’`
TAPE=`grep $1 /var/adm/archiver.log|tail -1|awk ‘{print $5}’`
POS=`grep $1 /var/adm/archiver.log|tail -1|awk ‘{print $9}’|cut -f1 -d ‘.’`
echo "dev=${DEV} tape=${TAPE} pos=${POS}"

exit

ACSLS quick commands

ACSLS

login as acsss
————–
#cmd_proc -l

show all caps
————-
ACSSA> display cap *
ACSSA> display cap * -f priority

show all cells
————–
ACSSA> display cell *
ACSSA> display cell * -status empty

show all tape drives
——————–
ACSSA> display drive * -f type
2007-02-14 10:51:22 Display Drive
Acs Lsm Panel Drive Type
0 0 0 0 CER-LTO
0 0 0 1 DLT7000
0 0 0 2 DLT8000

show all pools
————–
ACSSA> display pool *

show all ports
————–
ACSSA> display port *

show all volumes (lists tapes)
——————————
ACSSA> display volume *

show all cleaning tapes
———————–
ACSSA> q clean all
2007-02-14 10:54:04 Cleaning Cartridge Status
Identifier Home Location Max Usage Current Usage Status Type
CLN003 0, 0, 3, 0, 0 7 0 home DLTIII

mount a volume in a drive
————————-
(mount tape dlt082 on first drive)
ACSSA> mount dlt082 0,0,0,1

dismount a drive
—————-
ACSSA> q dr all
2007-02-14 11:05:18 Drive Status
Identifier State Status Volume Type
0, 0, 0, 0 online available CER-LTO
0, 0, 0, 1 online in use DLT080 DLT7000
0, 0, 0, 2 online available DLT8000
ACSSA> dis x 0,0,0,1 force
Dismount: Forced dismount of DLT080 from 0, 0, 0, 1

move a tape to the cap and remove it
————————————
ACSSA> display volume *
ACSSA> q dr all
if it’s mounted dismount
ACSSA> display cap *
2007-02-14 11:15:46 Display CAP
Acs Lsm Cap Status Priority State Mode Size
0 0 0 available 0 online manual 2
ACSSA> eject 0,0,0 dlt080
2007-02-14 11:16:15 81 CAP 0, 0,0: Remove cartridges from CAP.
2007-02-14 11:18:51 81 CAP 0, 0,0: Remove cartridges from CAP.
Use controll panel to get tape

StorEdge L9 timeout

reset the drivers

#devfsadm -v

Delete the jukebox using

#/usr/bin/nsr/nwadmin

Re-configure the jukebox with jbconfig

#/usr/sbin/nsr/jbconfig
1) Configure an AlphaStor/SmartMedia Jukebox.
2) Configure an Autodetected SCSI Jukebox.
3) Configure an Autodetected NDMP SCSI Jukebox.
4) Configure an SJI Jukebox.
5) Configure an STL Silo.

What kind of Jukebox are you configuring? [1] 2 These are the SCSI
Jukeboxes currently attached to your system:
1) /dev/scsi/changer/c6t0d0: Standard SCSI Jukebox, ADIC / FastStor 2
2) /dev/scsi/changer/c8t1d0: Standard SCSI Jukebox, ADIC / FastStor DLT

#reboot

Verify the jukebox after re-configuration

#/usr/sbin/nsr/nsrjb -j

StorEdge L25 L100 common error codes and part numbers

Tape Alert Flag: 46 – recycle power to fix
Tape Alert Flag: 37 – replace drive
Tape Alert Flag: 38 – – replace drive – or – upgrade firmware – or – replace system board

– Fault System Code: 4401 :Frame 1: Door 1 open (left door)

– Fault System Code: 4405 :Frame 1: Door 1 closed (left door)

– Fault System Code: 4405 :Frame 1: Door 1 closed (left door)

380-0892 LTO Gen 2 Low Voltage Differential (LVD) SCSI Drive for L25/L100
380-1196 LTO Gen 3 Low Voltage Differential (LVD) SCSI Drive for L25/L100
380-0811 LTO Gen 1 Low Voltage Differential (LVD) SCSI Drive for L25/L100
380-0682 SDLT 220 High Voltage Differential (HVD) Tape Drive
380-0820 SDLT320 Low Voltage Differential (LVD) Tape Drive
380-0980 SDLT600 Low Voltage Differential (LVD) drive