[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 387
  • Last Modified:

How do I rename an existing file system?

I am running Solaris 9 with two 20gig mirrored hard drives.  I need to rename an existing file system.  I want to rename export/home to /export.  How can I do this?  I need step by step instructions. See my current partiton table below.

Current partition table (original):
Total disk cylinders available: 39533 + 2 (reserved cylinders)

Part      Tag    Flag     Cylinders         Size            Blocks
  0       root    wm       0 -  8322        4.00GB    (8323/0/0)   8389584
  1       swap    wu    8323 - 10403        1.00GB    (2081/0/0)   2097648
  2     backup    wm       0 - 39532       19.00GB    (39533/0/0) 39849264
  3        usr    wm   10404 - 20562        4.88GB    (10159/0/0) 10240272
  4        var    wm   20563 - 32135        5.56GB    (11573/0/0) 11665584
  5       home    wm   32136 - 39490        3.54GB    (7355/0/0)   7413840
  6 unassigned    wm   39491 - 39532       20.67MB    (42/0/0)       42336
  7 unassigned    wm       0                0         (0/0/0)            0

# df -k  
Filesystem            kbytes    used   avail capacity  Mounted on
/dev/md/dsk/d30      4127894  708533 3378083    18%    /
/dev/md/dsk/d32      5038454 1008509 3979561    21%    /usr
/proc                      0       0       0     0%    /proc
mnttab                     0       0       0     0%    /etc/mnttab
fd                         0       0       0     0%    /dev/fd
/dev/md/dsk/d33      5739845  155301 5527146     3%    /var
swap                 1428456      24 1428432     1%    /var/run
swap                 1428432       0 1428432     0%    /tmp
/dev/md/dsk/d34      3647766  153828 3457461     5%    /export/home
/export/home/<name of dir>  3647766  153828 3457461     5%    /home/<name of dir>


0
dee43
Asked:
dee43
2 Solutions
 
jlevieCommented:
Edit /etc/vfstab and change the mount point for /dev/md/dsk/d34 from /export/home to /export. That's best done from a single user boot.
0
 
yuzhCommented:
jlevie is correct.

In single user mountYou need:
umount /export/home
and make sure /export is a empty dir, so that can mount  /dev/md/dsk/d34 on /export


If you have any software installed under /export/home you might need to modify the ENV
setting for using them.  (or you need to modify the scripts for runing the software)
0
 
cagriCommented:
Actually, as other friends explained, you do not "rename" filesystems on Solaris, but rather, mount them under different directories. Normally a filesystem does not have a name, and it can be mounted under any directory of your choice.

Btw, /export/home is the default directory for a number of applications, so I suggest, making and keeping a "home" folder under your newly mounted /export filesystem for just in case.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now