Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How To increase file System Size 1

Status
Not open for further replies.

bhawani123

IS-IT--Management
Nov 1, 2000
152
0
0
IN
Hello Guys,

How to increase file system size in solaris 7 system?Is there any way like swap area increament?
Currently I have 2.5Gb total space in /export/home file system and I want to make this 3.5gb.My 1.0GB is free in /usr file system and I want to append this free size in
/export/home file system area.
I have ultra 10 and ultra 60 System.

Regd,
Ajay Lohani
 
Depends how partition table is arranged, can you show us a output of the partition table ?

Regards,

Carlos Almeida,
 
Hello cfsalmeida,
I am sending partition table.

Part Tag Flag Cylinders Size Blocks
0 root wm 0 - 264 80.87MB (265/0/0) 165625
1 root wm 265 - 618 108.03MB (354/0/0) 221250
2 backup wm 0 - 6700 2.00GB (6701/0/0) 4188125
3 home wm 1956 - 4869 889.28MB (2914/0/0) 1821250
4 usr wm 619 - 1955 408.02MB (1337/0/0) 835625
5 swap wu 4870 - 5320 137.63MB (451/0/0) 281875
6 usr wm 5321 - 6700 421.14MB (1380/0/0) 862500
7 unassigned wm 0 0 (0/0/0) 0


Partion Number 3 is mounted as /export/home and partion Number 4 is mounted as /usr.
I want to append some free area(100MB) of /usr to /export/home.

Regd,
Ajay Lohani
 
Because &quot;/usr&quot; is contiguos to &quot;/export/home&quot; and assuming you are not using SDS, you can bring machine to single user mode (boot from cdrom with -s flag), and backup &quot;/usr&quot;, then change partition table with format and only change partiontion 3 and 4 take the space you need from begin of partition 3 (/usr) and add that to end of partition 4 (&quot;/export/home&quot;); then bacause we cannot shrink a file system you need to re-create (/usr) filesystem with &quot;newfs -m 1 <device>&quot;, and restore (&quot;/usr) from the previous backup,you can now go to multi-user mode, and then just expand the (&quot;/home/export&quot;) filesystem with &quot;mkfs&quot; with undocumented flags -G and/or -M
#/usr/lib/fs/ufs/mkfs -G -M /export/home <device> newsize
specifying -M if filesystem is mounted and the new size is in 512 byte blocks (if you are bad at math, &quot;just like me :)&quot;), you can give &quot;newsize&quot; as a big number like 9999999999 and mkfs will make the math for you because 9999999999 is out of range. and that's it !, I never had problems expanding a ufs filesystem online with &quot;mkfs&quot;, but just in case don't forget to make also a backup of &quot;/export/home&quot; before start.

Hope it helps,

Regards,

Carlos Almeida,


 
sorry .... my mistake I don't see at first the cylinder numbers (partition 4 is not contiguos to partition 3), you cannot use the procedure I describe in the other post...,

Regards,

Carlos Almeida,
 
So after (&quot;/export/home&quot;) partition 3, is a swap partition right ? partition 5, can you add swap in other disk ?, if yes you are done !, just remove swap and add in other disk, then with format change partition table to add cylinders from swap to the end of (&quot;/export/home&quot;) partition 3, and then expand &quot;/export/home&quot;) with
#/usr/lib/fs/ufs/mkfs -G -M /export/home <newsize>

if you dont have another place to add the removed swap, you can use the extra space in (/usr), and recreate swap space as a file in &quot;/usr&quot;

Regards,

Carlos Almeida,

Sorry about this one I only check that partition 3 and 4 are not contiguos after a &quot;submit&quot; the other post...
 
we can not increase a file system size in solaris.but if you want to do use ODS ( avialable free from SUN ,SUNWmd ).
or a costely solution is using Veritas Volume manager.
( commands in disksuite -- growfs and veritas is vxresize )
 
yes, we can increase a ufs flesystem size in Solaris, SDS command &quot;growfs&quot;, just call in background &quot;/usr/lib/fs/ufs/mkfs&quot;, with flags -G -M the only pre-requisite is space needs to be contigous in the partition table, in SDS or Volume manager we don't have this limitation because SDS use metadevices, in this thread if you notice all slices are taken, so SDS will have no use , it will always need to shrink a filesystem to arrange space or to expand to a contigous filesystem or to create a SDS metadevice to join to other metadevice.

Regards,

Carlos Almeida,
 
Thank you very much cfsalmeida,

Regd,
Ajay Lohani
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top