• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 523
  • Last Modified:

Hi, All - urgent - my production box " /usr " filesystem is 93% - need to extend it

Hi All,

We have emergency issue - my production box " /usr " file is at 93% - need to extend it.

we r not using any volume manager or disksuite - thats what the problem - I just joined this organisation. I dont know how to hanlde it.

can any one, plz help me out

here I am copying the contents of /usr

============================
# df -k
Filesystem            kbytes    used   avail capacity  Mounted on
/dev/dsk/c1t0d0s0     192833   77242   96308    45%    /
/dev/dsk/c1t0d0s6    1490275 1325636  105028    93%    /usr
/proc                      0       0       0     0%    /proc
fd                         0       0       0     0%    /dev/fd
mnttab                     0       0       0     0%    /etc/mnttab
/dev/dsk/c1t0d0s3     963869  268062  637975    30%    /var
swap                 5377640      16 5377624     1%    /var/run
swap                 5377736     112 5377624     1%    /tmp

=========================================

===========================================
/usr
# du -s *
14170   4lib
2       5bin
2       X
2       adm
16838   apache
266     aset
57098   bin
4040    ccs
25934   demo
2       dict
212048  dt
15402   emulex
2       games
16158   include
247918  j2se
2       java
52548   java1.1
69478   java1.2
2916    kernel
6       kvm
175496  lib
542     local
16      lost+found
2       mail
2       man
10      net
2       news
48      oasys
2       old
2       openv
477916  openwin
608802  patches
23568   perl5
8670    platform
2       preserve
30      proc
2       pub
72712   sadm
83740   sbin
103146  share
5698    snadm
2       spool
2       src
2       tmp
1174    ucb
316     ucbinclude
1652    ucblib
766     vmsys
5102    xpg4
========================
===============================
/usr/j2se
# ls -ltr
total 9962
-rw-r--r--   1 root     bin      5053848 Aug  8  2001 src.jar
-rw-r--r--   1 root     bin        12024 Aug  8  2001 README.html
-rw-r--r--   1 root     bin         3599 Aug  8  2001 README
-rw-r--r--   1 root     bin        11268 Aug  8  2001 LICENSE
-rw-r--r--   1 root     bin         4003 Aug  8  2001 COPYRIGHT
drwxr-xr-x   3 bin      bin          512 Oct 22  2002 man
drwxr-xr-x   5 root     bin          512 Oct 22  2002 jre
drwxr-xr-x   3 root     bin          512 Oct 22  2002 include
drwxr-xr-x   3 root     bin         1024 Oct 22  2002 bin
drwxr-xr-x   3 root     bin          512 Oct 22  2002 lib

here I see, one jar file - looks big - i dont what is it - can i remove it
====================================

will be waiting for u r reply - urgent plz

i appreciate -

thanks
0
Pratap345
Asked:
Pratap345
  • 8
  • 3
  • 3
  • +2
4 Solutions
 
XoFCommented:
which OS release?

simplest way to extend is as follows:
- initialize disksuite (means: create metadbs on a free slice (~50MB should be enough)): metadb -a -c 3 -f /dev/dsk/<free slice>
- create a new metadevice, e.g. d10, a concat of c1t0d0s6 and a free slice: metainit d10 2 1 /dev/dsk/c1t0d0s6 1 /dev/dsk/<new_slice>
- modify the entry for /usr in /etc/vfstab


HTH,
-XoF-
0
 
CadburyKatCommented:
Hello,

First off, you need to get these disks under some volume management.  I would suggest Veritas Volume Manager.

Explore what is in /usr/dt my solaris 8 system is only 100 MB.


This nest step is a drastic manuver.

As an emergency act you could stop the graphical display (/etc/init.d/dtlogin) move (via tar) /usr/openwin off of /usr filesystem, and link its directory via ln.

This should give you about 500 MB.

There is also a method to growfs.  This is beyond my skillset.
0
 
XoFCommented:
oh, just read the rest of your posting:
Seems as if there are tons of patches in /usr/patch....
You can get rid of these...

HTH,
-XoF-
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
XoFCommented:
I'd suggest using disksuite instead of VxVM. The latter one has to be licensed (pretty expensive), the first one is delivered as part of Solaris (since Solaris 9).
To grow the fs after adding space do a
growfs -M /usr /dev/md/dsk/d10 (when using my example above)

HTH,
-XoF-
0
 
Pratap345Author Commented:
Hello All,

1. Can I get disksuite now, if so. how do i get in to it now. can i have guidence

is there any other solutions, plz let me know.

thanks for u r time, will be waiting

0
 
Pratap345Author Commented:
HI,

cd /usr/patches
drwxr-xr-x 113 root     other       2560 Oct 17  2002 8_Recommended
-r-xr-xr-x   1 root     other    74716191 Oct 22  2002 8_reco~1.zip

yeah, u r right, i have these files under " /usr/patches ", that zip i dont know what its doing in it.

can i remove it, or got to do any thing with.

plz advise

thanks
0
 
CadburyKatCommented:
You should remove the file 8_reco~1.zip
0
 
CadburyKatCommented:
Also,

I believe that someone used that file (8_reco~1.zip) and unziped the file into 8_Recommended

You can remove this also.

rm -f 8_reco~1.zip
rm -Rf 8_Recommended

In fact you could probably cd /usr and rm -Rf patches as this is the location someone arbitrarily decided to place this directory.

Disksuite may already be on your system.  To check enter:

pkginfo SUNWmd

There should be some disksuite packages listed.
0
 
XoFCommented:
> Can I get disksuite now, if so. how do i get in to it now. can i have guidence

well, if you had answered my question (which OS release?), I could tell ya more....

> drwxr-xr-x 113 root     other       2560 Oct 17  2002 8_Recommended
> -r-xr-xr-x   1 root     other    74716191 Oct 22  2002 8_reco~1.zip

OK, looks like Solaris 8 (if there han't been an upgrade in the meantime)...
Solaris 8 should already ship with disksuite. You could try by calling the command "metastat". If you have it, disksuite is already installed... Then you could follow the instructions in my first post.
Besides, the files listed in /usr/patches are not necessary. The zip-file is a so-called patchcluster, which btw. is pretty old. The directory is the deflated content of the zip-file. Both - including the parent directory - can be deleted: "rm -rf /usr/patches". Note: This will not roll back installed patches, it's just the patch installer which will be deleted. So this operation won't have any impact to your system.

HTH,
-XoF-
0
 
NukfrorCommented:
25934   demo
52548   java1.1
69478   java1.2

I would look into the above directories as well.  You've technically got 3 versions of Java installed when you consider the above along with j2se directory as well.  Do you really need all three versions ?

To see what packages are contributing to the demo directory do the following:

cd /var/sadm/install
grep "/usr/demo/" contents

The version *last* field in the output line indicates which package name is consuming space in the subdirectory.  I seriously doubt you need anything with "demo" in its name.  Remove the offending packages with:

pkgrm <PKGname from grep output>
0
 
arthurjbCommented:
Talking about volume management systems at this point, is a little pointless, since there is almot nothing you can do to extend an existing disk partition if you don't already have a volume manager in use.

There are only 2 solutions at this point that may be useable, and only one if you cannot have any downtime.

The solution without downtime, is to find unimportant large files which can be deleted.

The file in /usr/patches can be deleted without causing system problems,
drwxr-xr-x 113 root     other       2560 Oct 17  2002 8_Recommended
-r-xr-xr-x   1 root     other    74716191 Oct 22  2002 8_reco~1.zip
cd /usr/patches
rm 8_reco~1.zip
rm -r 8_Recommended

deleting other stuff in /usr is a path to problems.  You said that you are new at the orginazation, so. don't know why there are 2 versions of java, it is possible that there are packages that don't work with the newer version.  If you remove stuff that is hard coded into some of your programs, things will break, and you will be spending a lot of time trying to recoved the deleted stuff...

Once you get you production box out of the critical range, then it is time to survey your equipment and determine your course of action.  Of course with out a history of the box, you don't know if it is critical or not, many folks like to live on the edge and believe that "Empty space is wasted space" and so set up their boxes to run in the 90-95% range.  If you find that the box normally runs in this range, than your time may be better spent planing for the long term health of the box, rather than fire fighting...

Setting up a volume management solution is a great idea, but if you don't have the free disk space, there is nothing you can do to extend the partitions.
 
Adding disks to increase the available space will require some downtime, and a plan for the disk space.  Not knowing the model of your server makes it hard to give advice on how to add disks...
0
 
XoFCommented:
> is a little pointless, since there is almot nothing you can do to extend an existing disk partition if you don't already have a volume manager in use.

NACK.

you can migrate a physical volume to a disksuite volume. That's the normal way disksuite is set up. The steps needed are described in one of my previous postings within this thread. The resulting metadevice might somehow be not performance optimized, since you aren't able to setup a stripe, but for just increasing the volume, a simple concatenation should do well.

> Adding disks to increase the available space will require some downtime

For the reasons mentioned above IMHO also not correct. If the system has hot-pluggable disks (FC or at least SCSI, which is hot pluggable in almost all cases), I cannot figure out any reason for a downtime.


regards,
-XoF-
0
 
arthurjbCommented:
>you can migrate a physical volume to a disksuite volume. That's the normal way disksuite is set up.

Yes, but if there is no available space on the existing drives, then you are just waisting time, since the migration will not buy you anything.

>If the system has hot-pluggable disks (FC or at least SCSI, which is hot pluggable in almost all cases), I cannot figure out any reason for a downtime.

Certainly, this is true, but if it is an older machine, or a desktop that they are using as a server (with ide drives) there will be some downtime.

My comments were based on this being a production box, and an emergency.  

The first step is to stablize the box, then if he needs to learn how to do disksuite, that should be another question, but trying to learn disksuite, especially since Sun removed metatool can be quite a challenge in an emergency, for someone new to Solaris...
0
 
XoFCommented:
> Yes, but if there is no available space on the existing drives, then you are just waisting time, since the migration will not buy you anything.

I don't really understand your argumentation. The original question
> " /usr " file is at 93% - need to extend it.
IMHO implies, that there's a possibility to provide more space in some way. If that possibility wasn't considered, this whole thread would be somehow useless....

Besides the question of knowledge, I only wanted to provide an alternative possibility to solve the problem (besides removing files). If that solution is beyond the OP's scope, should be the decision of Pratap345, shouldn't it?

Regarding this, I cannot find statements like "since there is almot nothing you can do to extend an existing disk partition if you don't already have a volume manager in use"  very helpful, that's why I wanted to stress, that disk expansion is nearly always possible - even without downtime in many cases.
The decision, which way might be the most practicable, is at Pratap345's.

> My comments were based on this being a production box, and an emergency.

well, dynamical resizing (read "resizing" as "growing") storage on demand during operation is daily business at large operating centers, since 24x7 doesn't allow for downtimes for such "simple" jobs...

Kind regards,

-XoF-
0
 
arthurjbCommented:
>I don't really understand your argumentation. The original question
>> " /usr " file is at 93% - need to extend it.
>IMHO implies, that there's a possibility to provide more space in some way. If that possibility wasn't considered, this whole thread would be somehow useless....

I guess that is one of the neat things about seeing the problems of others.  Where as you assumed that space is available, I assumed that the disk partitions were already fully assigned.  Without looking at the output of the format command, neither of us knows for sure.  Generally, folks don't leave unused disk space lying around...

>If that solution is beyond the OP's scope, should be the decision of Pratap345, shouldn't it?

Maybe, but just the question implies a lack of Solaris partition knowledge, and although I agree that proper disk management is the best long term solution, learning disksuite (or any other management solution) during an emergency, is tough.  Those of us who use disksuite on a regular basis don't think about the minor stuff that can cause major errors, a typo can cause complete data destruction...

Deleting the patch related stuff will most likely solve his immediate problem, and buy the time necessary to learn about the products needed for a long term solution.

I really enjoy Experts Exchange, and XoF has provided many great answers...
0
 
XoFCommented:
> Deleting the patch related stuff will most likely solve his immediate problem, and buy the time necessary to learn about the products needed for a long term solution.

Full ACK.

> Generally, folks don't leave unused disk space lying around...

yeah, but perhaps additional disks.... ;)

> Without looking at the output of the format command, neither of us knows for sure.

ACK.

> and XoF has provided many great answers...

well, I do what I can... thanx  ;)

regards,

-XoF-
0
 
XoFCommented:
No comment has been added to this question in more than 21 days, so it is now classified as abandoned.
I will leave the following recommendation for this question in the Cleanup topic area:

Split points: XoF & CadburyCat & Nukfror & arthurjb

Any objections should be posted here in the next 4 days. After that time, the question will be closed.

-XoF-
EE Cleanup Volunteer
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

  • 8
  • 3
  • 3
  • +2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now