Results 1 to 4 of 4
  1. #1
    Member
    Join Date
    Mar 2005
    Location
    Canberra, Australia
    Posts
    38
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Script for Fixing Read Only Volumes

    Just thought I'd share the following script I wrote to fix read only volumes on my TSM Servers (this is a Windows command script). The only disadvantage is that I would like to run it through TSM as an Admin schedule - which I don't believe can be done with this kind of script?
    Code:
    @echo off
    REM
    REM	The following script reclaims readonly volumes
    REM
    
    
    set TSMID=adminid
    set TSMPASS=adminpassword
    set TSMSERVER=%COMPUTERNAME%
    
    set ROVOLS=C:\Temp\ReadOnlyVolumes.txt
    set LOG=C:\Temp\ReadOnlyVolumes.log
    
    cd C:\Progra~1\Tivoli\TSM\baclient
    
    C:\Progra~1\Tivoli\TSM\baclient\dsmadmc.exe -ID=%TSMID% -PASSWORD=%TSMPASS% -dataonly=yes -tcpserveraddress=%COMPUTERNAME% -outfile=%ROVOLS% "select volume_name, pct_utilized from volumes where access='READONLY' order by pct_utilized"
    for /f "tokens=1 " %%i in (%ROVOLS%) do (C:\Progra~1\Tivoli\TSM\baclient\dsmadmc.exe -ID=%TSMID% -PASSWORD=%TSMPASS% -tcpserveraddress=%COMPUTERNAME% "move data %%i wait=yes" >> %LOG%)
    TSM Server 5.5.0.0
    Windows 2003 x64 R2 SP2
    HP DL580 G5
    Quad Intel quad core 2.9GHz CPUs with 16GB RAM!

  2. #2
    Senior Member toxy13's Avatar
    Join Date
    Sep 2003
    Location
    Leipzig
    Posts
    739
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by Kramer View Post
    The only disadvantage is that I would like to run it through TSM as an Admin schedule - which I don't believe can be done with this kind of script?
    I think you can use a postschedule command to run you script!

  3. #3
    Senior Member THE_WIPET's Avatar
    Join Date
    May 2006
    Location
    Montreal
    Posts
    562
    Thanks
    0
    Thanked 1 Time in 1 Post

    Default

    a schedule task in you windows env could do it.

  4. #4
    Member
    Join Date
    Mar 2005
    Location
    Canberra, Australia
    Posts
    38
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I think the postschedule option would only work if I was to run this against my TSM server as a client node? In which case I could define a command schedule...

    Anyway for the moment I'm running it as Windows scheduled task - that way it can exit after 8 hours of processing (I currently have a HEAP of read only volumes as we are transitioning our library from LTO2 to LTO4).
    TSM Server 5.5.0.0
    Windows 2003 x64 R2 SP2
    HP DL580 G5
    Quad Intel quad core 2.9GHz CPUs with 16GB RAM!

Similar Threads

  1. Excessive read errors on archive volumes.
    By TSM_JE in forum Backup / Archive Discussion
    Replies: 2
    Last Post: 05-01-2009, 04:00 PM
  2. volumes being marked as read only
    By javajockey in forum Tape / Media Library
    Replies: 4
    Last Post: 03-12-2008, 12:28 AM
  3. Replies: 6
    Last Post: 05-01-2007, 06:01 PM
  4. Read Only volumes on disk
    By JOKOUS in forum Tape / Media Library
    Replies: 1
    Last Post: 02-28-2006, 12:40 PM
  5. After BOOT TSM can't write, just read volumes ...
    By zanker in forum Tape / Media Library
    Replies: 0
    Last Post: 05-17-2005, 04:39 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •