Saturday, August 05, 2006

Take care of disk paritions filling up

One of our MySQL db servers was filling up the disk space pretty quickly due to normal reasons. Since we use 3Par for storage purposes, we created a larger partition and then linked the db directory to point to the new partition.

ln -s /path/to/new/mysql/data/partition/db_1 /path/to/mysql/data/db_1



The sequence of steps needed were:
  • create a new parition
  • initialize and clear filesystem with newfs before using for the first time.
  • Create appropriate entries in /etc/vfstab
  • Create the directory
  • mount (mount -a)
  • Copy data [tar cf - db_1 | ( cd /path/to/new/mysql/data/guestbook; tar xvf - )]
  • invoke "fuser -k /path/to/old/mysql/data" to view the processes using the filesystem you just unmounted
  • unmount the old partition
  • backup the data that was on old file system.
  • create a soft link that points to the new partition.
  • confirm
Some references
  • luxadm: Sun Enterprise Network Array (SENA) administration program
    • use it with the "-e" option for expert mode
    • get the "using luxadm" guide
    • example:
      • luxadm -e dump_map /devices/pci@1d,700000/SUNW,qlc@1/fp@0,0:fc


  • Adding filesystem under Solaris

0 Comments:

Post a Comment

<< Home