grow /var size how


 
Thread Tools Search this Thread
Operating Systems Linux SuSE grow /var size how
# 1  
Old 01-23-2009
grow /var size how

Hi all,

I am using SLES 9 and have following partitions mounted

Quote:
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/system-root_lv
4.0G 527M 3.5G 13% /
tmpfs 8.0G 8.0K 8.0G 1% /dev/shm
/dev/sda3 204M 45M 160M 23% /boot
/dev/mapper/system-home_lv
30G 9.3G 21G 31% /home
/dev/mapper/system-opt_lv
4.0G 560M 3.5G 14% /opt
/dev/mapper/system-srv_lv
4.0G 34M 4.0G 1% /srv
/dev/mapper/system-tmp_lv
3.0G 243M 2.8G 8% /tmp
/dev/mapper/system-usr_lv
8.0G 2.8G 5.3G 35% /usr
/dev/mapper/system-var_lv
3.0G 850M 2.2G 28% /var
I would like to make /var 10G atleast.

fdisk -l
Quote:
Disk /dev/sda: 218.2 GB, 218238025728 bytes
255 heads, 63 sectors/track, 26532 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

Device Boot Start End Blocks Id System
/dev/sda1 1 8 64228+ de Dell Utility
/dev/sda2 9 792 6297480 8e Linux LVM
/dev/sda3 * 793 818 208845 83 Linux
/dev/sda4 819 26530 206531640 5 Extended
/dev/sda5 819 949 1052226 82 Linux swap
/dev/sda6 950 26530 205479351 8e Linux LVM
Quote:
/dev/system/root_lv / reiserfs acl,user_xattr 1 1
LABEL=boot /boot reiserfs acl,user_xattr 1 2
/dev/system/home_lv /home reiserfs defaults 1 2
/dev/system/opt_lv /opt reiserfs acl,user_xattr 1 2
/dev/system/srv_lv /srv reiserfs acl,user_xattr 1 2
/dev/system/tmp_lv /tmp reiserfs acl,user_xattr 1 2
/dev/system/usr_lv /usr reiserfs acl,user_xattr 1 2
/dev/system/var_lv /var reiserfs acl,user_xattr 1 2
/dev/sda5 swap swap acl,user_xattr

This system is doing RAID5(HW).

Can someone help me with this issue?

Thanks
# 2  
Old 01-23-2009
upengan78,

It seems that your using LVM. Can you provide the information of the following command so that we can help you.


1.#pvdisplay
2.#vgdisplay
3. #lvdisplay
# 3  
Old 01-23-2009
Quote:
Originally Posted by csorhand
upengan78,

It seems that your using LVM. Can you provide the information of the following command so that we can help you.
1.#pvdisplay

Quote:
pvdisplay
--- Physical volume ---
PV Name /dev/sda6
VG Name system
PV Size 195.96 GB / not usable 0
Allocatable yes
PE Size (KByte) 4096
Total PE 50165
Free PE 35829
Allocated PE 14336
PV UUID 7seGq8-rVpp-q0dq-JDMv-uyOu-hy68-wtpb6g

--- Physical volume ---
PV Name /dev/sda2
VG Name system
PV Size 6.00 GB / not usable 0
Allocatable yes
PE Size (KByte) 4096
Total PE 1537
Free PE 1537
Allocated PE 0
PV UUID mxzbCY-TNVU-lp5O-u8Ul-QxhV-9MNb-uqgP9t
2.#vgdisplay
Quote:
vgdisplay
--- Volume group ---
VG Name system
System ID
Format lvm2
Metadata Areas 2
Metadata Sequence No 10
VG Access read/write
VG Status resizable
MAX LV 255
Cur LV 7
Open LV 7
Max PV 255
Cur PV 2
Act PV 2
VG Size 201.96 GB
PE Size 4.00 MB
Total PE 51702
Alloc PE / Size 14336 / 56.00 GB
Free PE / Size 37366 / 145.96 GB
VG UUID YX3K1s-Azp0-brqJ-Se5A-zNWc-2Jbv-27mxs6

3. #lvdisplay

Quote:
lvdisplay
--- Logical volume ---
LV Name /dev/system/root_lv
VG Name system
LV UUID rcX1xI-7bET-3tXL-KOGL-Xxje-QjqY-AXAirk
LV Write Access read/write
LV Status available
# open 2
LV Size 4.00 GB
Current LE 1024
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:0

--- Logical volume ---
LV Name /dev/system/usr_lv
VG Name system
LV UUID xUJidw-nGZy-NbnQ-WI66-eNSH-Mlxj-xowXnF
LV Write Access read/write
LV Status available
# open 2
LV Size 8.00 GB
Current LE 2048
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:1

--- Logical volume ---
LV Name /dev/system/tmp_lv
VG Name system
LV UUID h5CMsf-zMZ1-Kf63-1sjl-Og27-9exV-s1fs3L
LV Write Access read/write
LV Status available
# open 2
LV Size 3.00 GB
Current LE 768
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:2

--- Logical volume ---
LV Name /dev/system/var_lv
VG Name system
LV UUID 0qnXiv-cg0h-6nl9-lTZg-bV5n-RDX7-oYADIL
LV Write Access read/write
LV Status available
# open 2
LV Size 3.00 GB
Current LE 768
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:3

--- Logical volume ---
LV Name /dev/system/srv_lv
VG Name system
LV UUID s3TRWS-kH3G-zh6n-SMoT-V7vy-OpXX-uENrmR
LV Write Access read/write
LV Status available
# open 2
LV Size 4.00 GB
Current LE 1024
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:4

--- Logical volume ---
LV Name /dev/system/opt_lv
VG Name system
LV UUID wBTsy2-VZ2Y-F2GW-m1r7-Zg52-USpV-0FzLW5
LV Write Access read/write
LV Status available
# open 2
LV Size 4.00 GB
Current LE 1024
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:5

--- Logical volume ---
LV Name /dev/system/home_lv
VG Name system
LV UUID fD4e08-wecZ-QaiK-OKzn-AE5O-vBfV-7W58pm
LV Write Access read/write
LV Status available
# open 2
LV Size 30.00 GB
Current LE 7680
Segments 1
Allocation inherit
Read ahead sectors 0
Block device 253:6

FS is reiserfs, Also wondering if I can do this extention on the fly ! Smilie

Most importantly , Thank you !!
# 4  
Old 01-24-2009
upengan78,

You still have a lot of unused disk space.

You have two PV's combined space of "201.96 GB" in a VG called "system" and you have free 145.96 GB. You can try this command to extend the reiser without unmounting.

#lvextend -L+7G /dev/system/var_lv
#resize_reiserfs -s+7G -f /dev/system/var_lv

Note that the command set to 7 GB to /var as /var already has 3 GB(10GB that you want to allocate right?). Or if you want to make it bigger.

Cheers!
# 5  
Old 01-26-2009
Quote:
Originally Posted by csorhand
upengan78,

You still have a lot of unused disk space.

You have two PV's combined space of "201.96 GB" in a VG called "system" and you have free 145.96 GB. You can try this command to extend the reiser without unmounting.

#lvextend -L+7G /dev/system/var_lv
#resize_reiserfs -s+7G -f /dev/system/var_lv

Note that the command set to 7 GB to /var as /var already has 3 GB(10GB that you want to allocate right?). Or if you want to make it bigger.

Cheers!

csorhand, you are awsome! worked like charm! I have got now /var extended on the fly. Thanks for your kind help! I appreciate it.Smilie
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Fedora

/var/log/btmp size 2.2Gb daily

Hello, One Fedora server is facing the issue that daily /var/log/btmp grows to 2.2Gb or more. I need your help to determine the cause and isolate it. Thank you! (6 Replies)
Discussion started by: feroccimx
6 Replies

2. Shell Programming and Scripting

Csh , how to set var value into new var, in short string concatenation

i try to find way to make string concatenation in csh ( sorry this is what i have ) so i found out i can't do : set string_buff = "" foreach line("`cat $source_dir/$f`") $string_buff = string_buff $line end how can i do string concatenation? (1 Reply)
Discussion started by: umen
1 Replies

3. Red Hat

How to reduce inode size of /var?

Hi, inode size reached its 100% in /var Due to this i'am getting the error No space left on device my crond process is stopped and when i want to restart it it is showing the below error Starting crond: crond: can't open or create /var/run/crond.pid: No space left on device df -i o/p ... (3 Replies)
Discussion started by: Mohamed Thamim
3 Replies

4. Solaris

Difference between /var/log/syslog and /var/adm/messages

Hi, Is the contents in /var/log/syslog and /var/adm/messages are same?? Regards (3 Replies)
Discussion started by: vks47
3 Replies

5. AIX

/var/adm/wtmp - few entries & huge size.

Hi all. I have a strange case on one of my AIX boxes. /var/adm/wtmp on server01 is ~ 400MB large but it only has ~1200 lines. For example on server02 there are ~85000 lines and the file is ~158MB large. I check lines through 'last | wc -l'. But when I check line directly with 'wc -l... (2 Replies)
Discussion started by: robroy
2 Replies

6. UNIX for Dummies Questions & Answers

Help to Grow the Size of volume

I have a 146Gb drive and want to grow the size from 12G to the max available left. I think 20G is being used so I want to max out from 12 G to 126G. Is this possible? Can you help with the command. root@WRPDWI6k-BU # df -h Filesystem size used avail... (3 Replies)
Discussion started by: udubya
3 Replies

7. UNIX for Dummies Questions & Answers

Limiting User mailbox size in /var/spool

How can one limit the size of user mailboxes in /var/spool/mail? (0 Replies)
Discussion started by: proactiveaditya
0 Replies

8. Solaris

diff b/w /var/log/syslog and /var/adm/messages

hi sirs can u tell the difference between /var/log/syslogs and /var/adm/messages in my working place i am having two servers. in one servers messages file is empty and syslog file is going on increasing.. and in another servers message file is going on increasing but syslog file is... (2 Replies)
Discussion started by: tv.praveenkumar
2 Replies

9. Solaris

sometime /var/adm/messages size 0

Hi experts, sometimes i notice in my Solaris 9 /var/adm/messages size 0. It continues for 1/2 days then again /var/adm/messages is start filling up with logs!!! What could be reason behind it. and if its a problem what could be the solution. //purple (1 Reply)
Discussion started by: thepurple
1 Replies

10. Solaris

/var size is increasing day by day

Hi experts, I am facing a big problem. i use solaris 9. i found size of /var is increasing day by. snapshot of a yester moring- /dev/vx/dsk/var 15G 14G 1.1G 94% /var snapshot of a yesterday everning- /dev/vx/dsk/var 15G 14G 824M 95% /var I am... (11 Replies)
Discussion started by: thepurple
11 Replies
Login or Register to Ask a Question