How to Get Available/Used Disk/Partition Space Programmatically?

Is there any system call I can use?
Thank you very much for your attention and help
pam

[http://docs.sun.com/app/docs/doc/816-5167/statvfs-2?l=en&n=1&a=view|http://docs.sun.com/app/docs/doc/816-5167/statvfs-2?l=en&n=1&a=view]

Similar Messages

  • WARNING: Insufficient disk partition space.

    im trying to install J2EE SDK on a SunBlade 150 with Solaris 8. I get the following error message during the drivespace check:
    WARNNG: Insufficient disk partition space to install the items selected
    Im trying to install it in /opt/SUNWappserver/
    I have installed the recommended patch cluster for Solaris 8, so all of my patches are up to date. According to df -k, I have about 4.5 gigs left on that partition, so space is not the issue. I figured it must be a bug with the release.
    Does anyone know the fix for this?

    sure.....heres the info, sorry for the late reply, and thanks again for all of your help:
    Error Message when I try to install onto /opt/SunWAppserver/:
    Checking disk space...
    WARNING: Insufficient disk partition space to install the items selected.
    <Press ENTER to continue> {"<" goes back, "!" exits}
    A second attempt was made to install it in a different target, this time in /usr/j2eesdk/ with the same result.
    bash-2.03$ uname -a
    SunOS sunspot 5.8 Generic_108528-29 sun4u sparc SUNW,Sun-Blade-100
    bash$: df -k
    Filesystem kbytes used avail capacity Mounted on
    /dev/dsk/c0t0d0s0 958287 79005 821785 9% /
    /dev/dsk/c0t0d0s3 2997583 2171333 766299 74% /usr
    /proc 0 0 0 0% /proc
    fd 0 0 0 0% /dev/fd
    mnttab 0 0 0 0% /etc/mnttab
    /dev/dsk/c0t0d0s4 1977327 432350 1485658 23% /var
    swap 538760 24 538736 1% /var/run
    swap 539104 368 538736 1% /tmp
    /dev/dsk/c0t0d0s5 5020830 453250 4517372 10% /opt
    /dev/dsk/c0t0d0s6 20085817 2559013 17325946 13% /export/home
    Installed patches shown using showrev -p:
    Patches installed on system at time of attempt. (Latest install from recommended patch cluster for Solaris 8 released August 16th, 2004:
    109618-01 109889-01 110369-05 110370-03 110373-04 110374-08 110376-01 110833-01 110853-01 111791-01 112160-01 108528-13 108528-14 108528-29 111306-03 111793-01 112161-02 112167-01 110849-08 109873-11 108723-01 108875-10 108901-04 108974-17 109202-03 109454-01 109458-02 109657-06 109764-04 109793-09 109879-02 109898-05 109920-06 109928-04 110075-01 110285-01 110368-02 110371-03 110375-04 110379-01 110461-01 110820-07 110821-02 110822-01 110826-05 110827-02 110828-02 110829-02 110838-04 110840-02 110841-01 110842-05 110844-02 110845-03 110846-02 110847-02 110852-03 110854-02 110901-01 110955-02 111023-01 111267-02 111304-01 111321-02 111439-01 111588-01 112162-03 112163-01 112164-01 112170-01 112220-01 108725-07 108727-10 109872-01 109876-02 109893-02 109894-01 110851-02 110918-03 112169-01 109888-15 112438-01 108974-25 111023-03 108993-36 110724-01 108825-01 108899-01 108982-09 108983-08 108984-08 109091-04 109145-01 109147-12 109149-02 109277-02 109324-04 109326-06 109524-09 109576-01 109729-01 109783-01 109803-01 109805-04 109807-01 109809-01 109933-01 109994-01 110165-02 110283-05 110381-01 110382-01 110386-01 110387-03 110388-01 110662-06 110668-01 110710-01 110896-01 110898-03 110903-02 110905-02 110910-01 110912-03 110914-01 110934-04
    110945-04 110951-01 110957-02 111085-02 111098-01 111197-01 111225-02 111232-01 111234-01 111265-01 111299-03 111317-02 111319-01 111325-01 111368-01 111504-01 111624-01 111659-03 111804-02 111808-01 111831-01 111874-02 111881-01 111958-01 112039-01 112097-01 112138-01 112171-01 108964-06 108975-05 108985-03 108989-02 109043-02 109045-03 109077-06 109234-08 109896-07 109902-03 110385-03 110839-03 111796-03 111802-01 109003-01 109005-03 109007-06 109009-02 109011-01 109015-01 109017-01 109019-02 109021-01 109023-01 109027-01 109031-01 109033-01 109035-02 112396-02 108827-34 110934-07 113415-01 110386-03 109147-29 110934-16 111317-05 113648-03 115827-01 116602-01 108977-01 109785-01 109815-10 109877-01 109882-05 109883-02 109900-02 110380-03 110609-02 110615-03 110856-01 111018-01 111069-01 111293-04 111302-01 111310-01 111327-05 111431-01 108968-05 108972-04 108995-03 109885-08 110460-17 111295-01 108827-15 108993-05 108997-03 108999-01 109025-04 109029-02 111995-02 112001-02 111111-03 110380-04 108820-01 109223-01 109384-02 110458-02 110811-01 111308-01 111562-01 112218-01 112237-02 111297-01 111308-04 110815-01 112135-01 109159-01 111953-04 109134-26 112142-01 113261-01 110716-02 110286-05 108652-47 108652-64 108652-82 108823-01 108970-01
    109936-01 110916-02 111016-01 111111-01 111141-01 112050-01 109013-02 111075-02 111382-01 113128-02 108940-37 110605-02 108940-63 111760-02 109318-26 108962-01 108987-09 108987-13 110453-03 111741-02 111844-02 108714-05 108919-14 108949-07 109142-06 108714-08 109695-03 109887-10 111337-01 109165-11 109169-12 109354-13 110813-01 111231-04 108835-02 108909-12 109152-01 108869-11 109320-04 110611-01 110614-02 110088-02 109613-03 110326-02 110335-02 109582-02 109748-03 113242-01 109167-01 109470-02 109960-01 110407-02 110603-01 110457-04 108987-07 111852-01 110750-01 110320-01 112472-01 109931-02 108921-13 108923-01 108921-15 108921-21 108604-22 111359-02 108773-12 108773-17 108773-18 109881-02 111626-01 109766-02 110423-03 112082-02 109568-03 111548-01 111323-01 109238-02 110700-01 111393-02 109727-01 109890-01 111471-03 111481-01 110068-02 109862-01 114485-01 111332-04 108569-06 109037-01 109328-02 110269-01 110322-01 110511-03 109154-09 112137-01 111883-05 112172-02 112173-01 112174-01 109935-03 110389-04 110830-02 111049-02 110831-02 110832-01 110823-03 110824-02 110825-02 110835-03 110836-03 110837-03 110848-02 110900-02 111335-08 110794-02 111789-01 111790-05 109374-06 108605-22 111360-02 112249-01 111792-03 111822-01 110150-04 109754-05 111657-01 108576-25 109718-01 111415-04 111498-04 109460-06 108606-18 108606-28 111041-04 110819-03 108914-02 108954-02 110274-03 110797-02 110888-01 111275-01 111823-01 110723-04 110127-04 111606-02 110221-06 108813-08 108981-07 109529-06 109189-04 112187-01 109128-01 109679-01 109704-02 112003-03 110927-01 110953-02 108623-02 109639-02 109667-04 109922-02 109926-02 109892-03 109924-03 108806-07 110378-06 110986-02 111269-03 111313-01 111775-01 111777-01 111088-02 112159-01 110670-01 110943-01 109244-02 110939-01 110941-02 109607-01 109642-01 109813-01 110817-01 110907-01 111073-01 111794-01 111800-01 112158-01 112168-01 112334-01 109990-01 112165-01 108808-42 111400-01 111071-01 111570-01 108897-01 108609-01 110702-01 111596-02 112183-03 112077-02 108693-06 111661-01 111787-01 111500-04 108127-05 109660-01 109039-07 108701-10 108702-05 110645-02 109715-02 112178-01 109738-01 109584-21 110644-01 109585-11 111254-01 109586-09 110208-13 112034-03

  • How can I increase the C partition space?

    Hello! I have an internal hard drive used on my Windows 7computer and also has divided it into four partitions, C, D, E and F. Under Disk Management, I was able to shrink the E partition well. But when I went to extend the C partition
    space there, it just didn’t let me do that (that “Extend” option just cannot be chosen). How do I extend my C partition space successfully? 

    Hi,
    To use the "Extend Volum" option, you need a unallocated space available as a the snapshot below:
    Here's a guide for reference
    http://blogs.technet.com/b/mghazai/archive/2009/02/24/extend-system-boot-volume-on-windows-server-2008-windows-vista-win7-beta.aspx
    we should shrink the neighboring partition to release unallocated space
    if error persists, please paste the GUI snapshot of your disk management here for further analysis.
    Yolanda Zhu
    TechNet Community Support

  • In ABAP HR how to get job using position

    In ABAP HR how to get job using position (Using Infotype 1001)

    Hi anilkumar,
    1. u have the position
       u want the Job
    2. In hrp1001 table
       OTYPE = 'S' (for position)
       OBJID  = POSITION (AS ABOVE)
       SCLAS = 'C' (for finding job)
    <b>   SOBID = XXXXXX (here u will get the JOB)</b>
    regards,
    amit m.

  • How to get image using Http and how to save in Smulator

    Hi guys,
    Am working in black berry bold. i dont know how to get image using htp connection and one more thing i need to save this image in side simulator directory............. what are the specific API i should...
    Guide me.........

    If you want the input image size you need to pass it in as parameters.
    A discussion thread on this topic is:
    http://forums.adobe.com/thread/29948
    -- Daniel R. <[email protected]> http://danielr.neophi.com/

  • Hi out there. To capture a screen shot one uses: Command-Shift-3 or 4. I have done this for a long time. Now suddenly neither screen shot works anymore. Suggestions how to get this useful function back? Thanks, Georgx

    Hi out there. To capture a screen shot one uses: Command-Shift-3 or 4. I have done this for a long time. Now suddenly neither screen shot command works anymore. Suggestions how to get this useful function back? Thanks, Georgx

    Command-Shift-3 and 4 works just fine on several Macs that I have here.
    Try restarting your Mac....or post in the specific support area for your Mac model....for more advice.
    https://discussions.apple.com/index.jspa

  • How Do I Get Rid Of Disk Partitions/Images?

    Hey folks,
    When I bought my iMac flat panel from a friend, he partitioned the hard drive into 3 'disks' or disk images. The problem I'm having, is that I would like to get rid of one of them and use that storage for the main disk; the disk with the startup info. on it.
    How in the heck do I do this? I've located about 134, 765 articles on how to CREATE partitions, but none on how how to get rid of them, or combine them into others.
    Help?
    iMac flat panel   Mac OS X (10.4.8)  

    Hello and Welcome to Apple Discussions. 
    If you use only Apple's software then the only way is to Erase the drive with Disk Utility and set one partition only.
    Clearly this will erase all data on the drive.
    There are some 3rd party utilities that allow partitions to be removed/created without erasing the drive.
    Given the nature of what you are doing here; I'd recommend fully backing up all your data before doing anything of this nature.
    mrtotes

  • How can I delete a failed partition space?

    I tried to partition my disk for the first time, but unfortunately, it failed. Now there's a white space left for the supposed partition space. How can I retrieve it back? Help please.

    Would you post a screen shot so people can see what you are seeing? Make sure you cover any personal information using Preview. Post the screen shot in a Reply using the camera icon. Copy and paste doesn't work.
    Screen shots
    Open Disk Utility/Partition and select the drive?
    Do you have Boot Camp installed?

  • How to reuse the same disk (partition) for next ASM configuration?

    Hello All,
    I had successfully installed and configured ASM instance once, but I need to do a reinstallation and I would like to use the same disk (partition) as with previous ASM configuration.
    The disk path used was: /dev/rdsk/c1t3d0s7
    I have to regretfully admit that I may not have used the right ASM un-installation procedure. I ran installer and opted to de-install products. Consequently, I had removed ASM home. Now, when I running new ASM installation, everything goes fine until the screen where I should select disks for ASM configuration. Unfortunately, I see the /dev/rdsk/c1t3d0s7 with status > MEMBER < and I can't select it for the new ASM installation.
    I will really appreciate if anyone can let me know how to change status from MEMBER to CANDIDATE.
    Thank you for your time.
    DanielD

    Overwrite the first several MB of the partition with /dev/zero.
    So, use this command:
    # dd if=/dev/zero of=/dev/rdsk/c1t3d0s7 bs=1024k count=10
    That clears out the ASM header on the disk so that it looks like a clean disk again.
    -- John

  • How to get InitialContextFactory using RMI/IIOP without using weblogic.jar

    Hi Robert
    I know this is an old post. but I am interested in knowing how to get the
    initial context using RMI/IIOP without the use weblogic specific classes
    like weblogic.jndi.WLInitialContextFactory . If you have a code snippet that
    you can provide as an example, it would be just great.
    thanx in advance
    Daya Sharma
    See comments inline...
    Stewart Wachs wrote:
    I would like to get an initial context to Weblogic JNDI from a client.
    code snippet:
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFacorty");
    ht.put(Context.PROVIDER_URL, "t3://localhost:7001");
    try {
    Context ctx = new InitialContext(ht);
    catch(...) {
    This works fine when I include weblogic.jar (and other dependend weblogic
    jar's) in the classpath.
    Is there a way to access WL JNDI from a client without the weblogicclasses
    in the classpath?If you are using WLS 6.1, you could use RMI/IIOP to do this but in general,
    the
    answer is no, you will need at least some of the weblogic classes on the
    client.
    If not, is there a lightweight jar available for distribution for client
    JNDI connectivity?This is something in the works. In addition, a colleague and I are working
    on
    a white paper that describes the "Thin Client Options with WebLogic Server"
    that we hope to make available in the not too distant future...
    Are there any licencing issues with distributing the weblogic classes to
    clients that need to access WL JNDI?No. WLS is licensed by the server so you are free to distribute
    weblogic.jar
    to your clients.
    Hope this helps,
    Robert

    Take a look at the RMI/IIOP section of our whitepaper "Small Footprint
    Client options for BEA WebLogic Server" at:
    http://dev2dev.bea.com/resourcelibrary/whitepapers.jsp?highlight=whitepapers
    Daya Sharma wrote:
    Hi Robert
    I know this is an old post. but I am interested in knowing how to get the
    initial context using RMI/IIOP without the use weblogic specific classes
    like weblogic.jndi.WLInitialContextFactory . If you have a code snippet that
    you can provide as an example, it would be just great.
    thanx in advance
    Daya Sharma
    See comments inline...
    Stewart Wachs wrote:
    I would like to get an initial context to Weblogic JNDI from a client.
    code snippet:
    Hashtable ht = new Hashtable();
    ht.put(Context.INITIAL_CONTEXT_FACTORY,
    "weblogic.jndi.WLInitialContextFacorty");
    ht.put(Context.PROVIDER_URL, "t3://localhost:7001");
    try {
    Context ctx = new InitialContext(ht);
    catch(...) {
    This works fine when I include weblogic.jar (and other dependend weblogic
    jar's) in the classpath.
    Is there a way to access WL JNDI from a client without the weblogic
    classes
    in the classpath?
    If you are using WLS 6.1, you could use RMI/IIOP to do this but in general,
    the
    answer is no, you will need at least some of the weblogic classes on the
    client.
    If not, is there a lightweight jar available for distribution for client
    JNDI connectivity?
    This is something in the works. In addition, a colleague and I are working
    on
    a white paper that describes the "Thin Client Options with WebLogic Server"
    that we hope to make available in the not too distant future...
    Are there any licencing issues with distributing the weblogic classes to
    clients that need to access WL JNDI?
    No. WLS is licensed by the server so you are free to distribute
    weblogic.jar
    to your clients.
    Hope this helps,
    Robert

  • How to get the size of partition?

    The following SQL will get the rows of the fact table & aggregation. But how to get the size (MB) of the partition. select * from $system.discover_partition_stat That should be doable, because in BIDS, we can see the size of a partition, but from which
    view we can do that?

    This is the best bet you have SELECT * FROM SystemRestrictSchema($system.discover_partition_stat ,DATABASE_NAME = 'Adventure Works DW' ,CUBE_NAME = 'Adventure Works' ,MEASURE_GROUP_NAME = 'Internet Sales' ,PARTITION_NAME = 'Internet_Sales_2003') Refer
    this article: http://geekswithblogs.net/darrengosbell/archive/2008/12/02/ssas-are-my-aggregations-processed.aspxvinu

  • How to get available physical channels by DAQmx in VIs?

    I can get available DAQ devices by calling DAQmx System property. What should I do if I want to get all available physical channels in my VI?
    My NI DAQ version is 7.3, and my LabVIEW version is LabVIEW Professional 7.1.
    Thanks!

    There really isn't a great way to do this. I've attached a zip file with a couple of VIs that might give you a an idea or two about how you might want to go about it. Hope one of these helps!
    -Alan A.
    Attachments:
    Chanel Info.zip ‏23 KB

  • How to get data using JDOM

    Hi,
    I have this xml file stored in operator.xml
    <Operator>
         <Customer>
              <Name>sam</Name>
              <Street>albert str.</Street>
              <ZipCode>45454</ZipCode>
              <City>NY</City>
              <Country>USA</Country>
              <EMailAddress>[email protected]</EMailAddress>
              <MeterNumber>1000</MeterNumber>
              <MeasuringUnit>kWh</MeasuringUnit>
              <Reading>
              <Month>1</Month>
              <Value>900</Value>
              </Reading>
              <Reading>
              <Month>2</Month>
              <Value>725</Value>
              </Reading>
              <Reading>
              <Month>3</Month>
              <Value>950</Value>
              </Reading>
         </Customer>
    </Operator>I have the following getter statements in my code:
    String name=req.getName();
    int month=req.getMonth();Now, I want to get value for particular customer (by checking name for equality with getter) and for particular month( by checking for equality with getter).
    I have written the following statements:
    final String filename="operator.xml";
    SAXBuilder builder=new SAXBuilder(true);
    Document doc=builder.build(filename);
    Element root=doc.getRootElement();How to proceed further using JDOM. I am confused with getChild(), getChildText() etc.,
    thanks,

    Obtain values with the JDom XPath class selectSingleNode and selectNodes methods.
    SAXBuilder saxBuilder=new SAXBuilder("org.apache.xerces.parsers.SAXParser");
    org.jdom.Document jdomDocument=saxBuilder.build(new File("c:/input.xml"));
    org.jdom.Element zipcodeNode= (org.jdom.Element)(XPath.selectSingleNode(jdomDocument,"/Operator//Customer/zipCode"));

  • How to get or use "kTextFrameOversetChangeMsg" as serviceid?

    Hi all
    I've developed a small plugin for handling textframe overflow. I've used service ids "kBeforeSaveDocSignalResponderService", "kBeforeSaveAsDocSignalResponderService". But actually I've to run it, only when overflow occurs.
    Steven suggested to use "kTextFrameOversetChangeMsg". I tried, but I dont know exactly how to use it as service id. Could anyone suggest on this?
    thanks in advance
    A.Hakkim

    Thank u both. Pls suggest me how to get serviceid from "kTextFrameOversetChangedMsg".

  • How to Get Availability date? while doing MIGO

    Hi Guys ,
    Can any body tell me how can i get Availability Date while doing MIro ?
    1.I have to get Availability date
    2. and that Availability date is Production date + 8 days ?
    how can i implement this one ? is there any relevent user exits is there ?
    please give me some input?
    regards
    Prabhu

    Hi Guys ,
    Can any body tell me how can i get Availability Date while doing MIGO ?
    1.I have to get Availability date
    2. and that Availability date is Production date + 8 days ?
    how can i implement this one ? is there any relevent user exits ?
    please give me some input?
    regards
    Prabhu

Maybe you are looking for

  • Very urgent ----  logical componernt in solman

    Hi all, In solman we have created systems for the three systems in our landscape (DEV -> QAS -> PRD). Now in logical component do we need to create three logical component for each of this server or only one logical component and assign the server's

  • Setting attributes in jsp is not working

    i want to recieve the "stuBean" object in the servlet by setting it in following jsp page.In this jsp page i am retrieving that object sent by a servlet and then again i want to forward it to another servlet through this jsp page. And in the servlet

  • Red hue to iPhoto 08 prints?

    I just recently upgraded my MacPro's iPhoto to the new 08 version. All my images are shot with a Canon 20D and printed on a Canon i960. Since the upgrade, all the photographs that I print from iPhoto on photo paper (Canon's plus glossy) have a major

  • An attempt to attach an auto-named database ....\aspnetdb.mdf failed

    I've installed VWD 2005(Beta 2) and MS SQL Express and also followed the aspnet tour at http://beta.asp.net/guidedtour2. After trying new webcontrol (login control) and trying to execute the page, I've got an error such as below: An attempt to attach

  • Use of strategy 51

    Hi, We have a scenario where the finished material (GA_FINISH) is assembled as per the customer requirement A level below that we can produce & maintain in stock (GA_ASSLY) Process planned as follows GA_FINISH (use strategy 51) Create PIR for GA_FINI