Tree for file system

hi frndzz,
I want to represent the file system using a jtree?please send the code fragment...............
and also how to know which operating system under the app is running in java?
Thanks in advance

Hello,
These tips may help:
List the names of all files in a particular directory
http://www.java-tips.org/java-se-tips/java.io/list-the-names-of-all-files-in-a-particular-directory.html
How to follow a directory structure
http://www.java-tips.org/java-se-tips/java.io/how-to-follow-a-directory-structure.html
How do I list all drives - filesystem roots - on my system
http://www.java-tips.org/java-se-tips/java.io/how-do-i-list-all-drives---filesystem-roots---on-my-system.html

Similar Messages

  • Is possible control tape library slot 1 - 10 for file system backup

    hi ..
    i am new to osb , i just install and setup osb , i have a question as below , hope expert can help me
    env: testing
    rhel 5.5
    tape library with 20 slot
    file system backup
    1. is possible osb only use slot 1 - 10 for file system backup ? amanda can control slot x - slot y for the configuration .
    2. how do i label the tape for slot 1 - slot 10 by obtool ? how to control osb auto load the tape for next backup ? where to check the log say that next tape is tape-02 ?
    thanks ..

    hi dcooksey
    how do i use list for a tape drive...for example, if you want tape drive A to only use slots 1-10 from obtool or webtool ?
    becoz i new to backup solution & osb ( i always use ghost or acronis to clone the image ) , my thinking as below , pls correct me if i am wrong
    slot 1 - 10 for daily backup
    slot 11-16 for full system backup
    slot 17 - 20 reserve ( this tape only use for full system backup before perform any application upgrade patches , )
    daily backup mon - fri ( 2 week ) ( no backup on saturday and sunday ) , server application offline
    full system backup friday ( 1 , 14 on calendar ) every 2 week perform full system backup after daily backup completed
    for upgrade application ,
    perform full system backup after daily backup , then release the server to application team to perform upgrading .
    so how to set my media family for the above setting ? the slot configuration is control by media family ?
    hope you can help ...

  • URM Adapter for File System issue.

    Hi, I am just starting out on using the URM Adapter for File System and I have a few questions about issues I am facing.
    1.     When I try to create multiple searches and map them to Folders/Retention Categories in URM, it does not work. I am able to map one search via one URM source to one Folder/Retention Category (without my custom attribute from question 1). However in Adapter’s Search Preview I am able to perform a search on the documents successfully. Would different searches require different URM sources in Adapter?
    2.     Does the adapter work with other Custom Attributes? I have added an attribute in addition and in the same way as "URMCrawlTimeGMT" is added in Oracle Secure Enterprise Search (I created a custom Document Service and Pipeline to add a metadata value) and in the URM Adapter’s config.properties file and when I create a search in Adapter based on the custom attribute, it does not map the documents into URM. I am however able to search the documents in Adapter’s Search Preview window with the custom attribute displaying correctly.
    Any help with this topic would be really appreciated. Thank you.
    Regards,
    Amar

    Hi Srinath,
    Thanks for the response, as to your questions,
    1. I am not sure how to enable Records Manager in adapter mode. But I am able to login to the Records Manager web page after starting it up through StartManagedWebLogic.cmd URM_server1.
    2. The contents of the file system should be searchable in Records Manager, and should be able to apply retention policies to the documents in the file system, I do not need to have SES, but apparently the adapter needs to have SES as a pre requisite.
    Upon further investigation I found that in the AGENT_DATA table the values being inserted were "User ID"(UA_KEY) and NULL(UA_VALUE), so I just made the UA_VALUE column nullable and I was able to pass that step. Is this the wrong approach to fix the issue.
    Could you please let me know about enabling Records Manager in adapter mode, I am not able to find documentation online, I have been through the Adapter installation and administration guides. Thank you once again.
    Regards,
    Amar

  • Unix shell: Environment variable works for file system but not for ASM path

    We would like to switch from file system to ASM for data files of Oracle tablespaces. For the path of the data files, we have so far used environment variables, e.g.,
    CREATE TABLESPACE BMA DATAFILE '${ORACLE_DB_DATA}/bma.dbf' SIZE 2M AUTOEXTEND ON;
    This works just fine (from shell scripts, PL/SQL packages, etc.) if ORACLE_DB_DATA denotes a file system path, such as "/home/oracle", but doesn’t work if the environment variable denotes an ASM path like "\+DATA/rac/datafile". I assume that it has something to do with "+" being a special character in the shell. However, escaping "\+" didn’t work. I tried with both bash and ksh.
    Oracle managed files (e.g., set DB_CREATE_FILE_DEST to +DATA/rac/datafile) would be an option. However, this would require changing quite a few scripts and programs. Therefore, I am looking for a solution with the environment variable. Any suggestions?
    The example below is on a RAC Attack system (http://en.wikibooks.org/wiki/RAC_Attack_-OracleCluster_Database_at_Home). I get the same issues on Solaris/AIX/HP-UX on 11.2.0.3 also.
    Thanks,
    Martin
    ==== WORKS JUST FINE WITH ORACLE_DB_DATA DENOTING FILE SYSTEM PATH ====
    collabn1:/home/oracle[RAC1]$ export ORACLE_DB_DATA=/home/oracle
    collabn1:/home/oracle[RAC1]$ sqlplus "/ as sysdba"
    SQL*Plus: Release 11.2.0.1.0 Production on Fri Aug 24 20:57:09 2012
    Copyright (c) 1982, 2009, Oracle. All rights reserved.
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options
    SQL> CREATE TABLESPACE BMA DATAFILE '${ORACLE_DB_DATA}/bma.dbf' SIZE 2M AUTOEXTEND ON;
    Tablespace created.
    SQL> !ls -l ${ORACLE_DB_DATA}/bma.dbf
    -rw-r----- 1 oracle asmadmin 2105344 Aug 24 20:57 /home/oracle/bma.dbf
    SQL> drop tablespace bma including contents and datafiles;
    ==== DOESN’T WORK WITH ORACLE_DB_DATA DENOTING ASM PATH ====
    collabn1:/home/oracle[RAC1]$ export ORACLE_DB_DATA="+DATA/rac/datafile"
    collabn1:/home/oracle[RAC1]$ sqlplus "/ as sysdba"
    SQL*Plus: Release 11.2.0.1.0 Production on Fri Aug 24 21:08:47 2012
    Copyright (c) 1982, 2009, Oracle. All rights reserved.
    Connected to:
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
    With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
    Data Mining and Real Application Testing options
    SQL> CREATE TABLESPACE BMA DATAFILE '${ORACLE_DB_DATA}/bma.dbf' SIZE 2M AUTOEXTEND ON;
    CREATE TABLESPACE BMA DATAFILE '${ORACLE_DB_DATA}/bma.dbf' SIZE 2M AUTOEXTEND ON
    ERROR at line 1:
    ORA-01119: error in creating database file '${ORACLE_DB_DATA}/bma.dbf'
    ORA-27040: file create error, unable to create file
    Linux Error: 2: No such file or directory
    SQL> -- works if I substitute manually
    SQL> CREATE TABLESPACE BMA DATAFILE '+DATA/rac/datafile/bma.dbf' SIZE 2M AUTOEXTEND ON;
    Tablespace created.
    SQL> drop tablespace bma including contents and datafiles;

    My revised understanding is that it is not a shell issue with replacing +, but an Oracle problem. It appears that Oracle first checks whether the path starts with a "+" or not. If it does not (file system), it performs the normal environment variable resolution. If it does start with a "+" (ASM case), Oracle does not perform environment variable resolution. Escaping, such as "\+" instead of "+" doesn't work either.
    To be more specific regarding my use case: I need the substitution to work from SQL*Plus scripts started with @script, PL/SQL packages with execute immediate, and optionally entered interactively in SQL*Plus.
    Thanks,
    Martin

  • Issues with setting appropriate ownership for file system

    Hi All,
    We are using ACFS File system. For some of the mount point we have set to change ownership according to requirement in rc.local file So that all permissions remain intact when the server restarts. But the permissions are not taking into account. Only after the rc.local is executed ASM disks are mounted I guess. Is there any where else can we write scripts to change ownership of mount points for ACFS so that when the disks are mounted proper Unix permissions are setup.
    Thanks & Regards,
    Vikas Krishna

    To configure raw devices if you are using Red Hat Enterprise Linux 4.0:
    To confirm that raw devices are enabled, enter the following command:
    # chkconfig --list
    Scan the output for raw devices. If you do not find raw devices, then use the following command to enable the raw device service:
    # chkconfig --level 345 rawdevices on
    After you confirm that the raw devices service is running, you should change the default ownership of raw devices. When you restart a Red Hat Enterprise Linux 4.0 system, ownership and permissions on raw devices revert by default to the root user. If you are using raw devices with this operating system for your Oracle Clusterware files, then you need to override this default.
    To ensure correct ownership of these devices when the operating system is restarted, create a new file in the /etc/udev/permissions.d directory, called oracle.permissions, and enter the raw device permissions information. Using the example device names discussed in step 5 of the previous section, the following is an example of the contents of /etc/udev/permissions.d/oracle.permissions:
    # OCR
    raw/raw[12]:root:oinstall:0640
    # Voting Disks
    raw/raw[3-5]:oracle:oinstall:0640
    # ASM
    raw/raw[67]:oracle:dba:0660
    After creating the oracle.permissions file, the permissions on the raw devices are set automatically the next time the system is restarted. To set permissions to take effect immediately, without restarting the system, use the chown and chmod commands:
    chown root:oinstall /dev/raw/raw[12]
    chmod 640 /dev/raw/raw[12]
    chown oracle:oinstall /dev/raw/raw[3-5]
    chmod 640 /dev/raw/raw[3-5]
    chown oracle:dba /dev/raw/raw[67]
    chmod 660 /dev/raw/raw[67]
    http://download.oracle.com/docs/cd/B19306_01/rac.102/b28759/preparing.htm#CHDGEEDC
    Edited by: Babu Baskar on Apr 18, 2010 1:33 PM

  • 888k Error in ULS Logs for File System Cache

    Hello,
    We have a SharePoint 2010 farm in a three-tier architecture with multiple WFEs and APP servers.
    Roughly once a week we will have a number of WFEs seize up and jump to 100% CPU usage. Usually they come in pairs; two servers will jump to 100% at the same time while all the other servers are fine in the 20% - 50% range.
    Corresponding to the 100% CPU spike, the following appear in the ULS logs:
    "File system cache monitor encoutered error, flushing in memory cache: System.IO.InternalBufferOverflowException: Too many changes at once in directory:C:\ProgramData\Microsoft\SharePoint\Config\<GUID>\."
    When these appear, the ULS logs will show hundreds back-to-back flooding the logs.
    I have yet to figure out how to stop these and bring the CPU usage down while the incident is happening, and how to prevent them in the future.
    While the incident is happening, I have tried clearing the configuration cache, shutting the timer jobs down on each server, deleting all the files but config.ini in the folder listed above, changing config.ini to 1, and restarting the timer. The CPU will
    drop momentarily during this process, but as soon as all the timer jobs are restarted the CPUs jump back to 100% on the same servers.
    This week as part of my weekly maintenance I thought I'd be proactive and clear the cache even though the behavior wasn't happening, and all CPUs were normal. As soon as I finished, the CPU on two servers that were previously fine jumped to 100% and wouldn't
    come down. Needless to say, users complain of latency when servers are at 100% CPU.
    So I am frustrated. The only thing I have found that works when the CPUs jump to 100% with these errors are a reboot. Nothing else, including IISReset and stopping/starting the admin and timer job services work. Being Production systems, reboots during the
    middle of the day are bad.
    Any ideas? I have scoured the Internet resources on this error and have come up relatively empty-handed. All the articles reference clearing the configuration cache, which, in my instance, does not get rid of these issues, and can even trigger them.
    Thanks,
    Joseph Irvine

    Take a look at http://support.microsoft.com/kb/952167 for the list of recommended exclusions per Microsoft.
    Trevor Seward
    Follow or contact me at...
    &nbsp&nbsp
    This post is my own opinion and does not necessarily reflect the opinion or view of Microsoft, its employees, or other MVPs.

  • File Size capped at 32bit for File System Data soruce?

    I have a report that uses the "File System Data" source. I am using it to find files older then 30 days of type BAK or TRAN. That all works well but the "File Size" field does not display the correct information. For example I have a file that is 191GB or 205,192,528,384 Bytes, but the report displays it as 4,294,967,295 this corresponds with the max for a 32bit INT. Can anyone confirm that this is a limitation of the driver? Is there are 64bit CRDB_FILESYSTEM.DLL?
    Regards

    Hi Thomas
    What version of CR are you using? Please look for the version in the Help | About screen of the designer.
    - Ludek
    Senior Support Engineer AGS Product Support, Global Support Center Canada
      Follow me on
    Twitter

  • Disallow for file system access

    Hi All,
    I would like to not permit to access to file system, how can i do that with permission object. I saw only examples how to set contraints on location where it can access.
    Regards

    I'm sorry but i dont understand the problem. (Maybe someone else will)
    So you have told me that when you pass null to an file permission object, that you find out the mask is "NONE"?
    You want to stop users accessing some files?
    You need to build code that will stop the user accessing certain files
    You want to know if you can put restrictions on the whole VM(What is VM?) or just the context?
    I believe this Link could be helpful for you.

  • Intermedia text search error for file system

    I would like to search a text from a file. store in the file system. I have done the following procedures but when i create i get error.
    BEGIN
    CTX_DDL.CREATE_PREFERENCE('search_docroot_pref','FILE_DATASTORE');
    CTX_DDL.SET_ATTRIBUTE('search_docroot_pref','path','c:/temp/abc');
    END;
    Now when i create INDEX with following syntex
    CREATE INDEX mysearch_ind ON mytable(mycolumn) INDEXTYPE IS
    CTXSYS.context parameters('datastore search_docroot_pref');
    I get the following errors.
    ERROR at line 1:
    ORA-29855: error occurred in the execution of ODCIINDEXCREATE routine
    ORA-20000: interMedia Text error:
    DRG-50704: Net8 listener is not running or cannot start external procedures
    ORA-28575: unable to open RPC connection to external procedure agent
    ORA-06512: at "CTXSYS.DRUE", line 126
    ORA-06512: at "CTXSYS.TEXTINDEXMETHODS", line 54
    ORA-06512: at line 1
    Can any body tell me where i am wrong.
    Thanks,

    Hi
    I was aslo facing same problem.My net8 connection and listner is aslo ok. but getting same errors.
    Raju

  • How to represent a tree (like file system dirs) in object?

    I am parsing a dynamic set of nodes at runtime. The nodes below a "known" node are all dynamic, in that they can be any number of nodes at any number of depth. I am basically doing what DOM does, in that I want to take these nodes below the "known" node, and create a simple object in memory. I am using xml pull parser though, so I am not using any sort of DOM/SAX/SAX2 parsing and do not want to use anything outside of my own object or one that is in the JDK 1.3 or later API. I see TreeSet and TreeMap, but I don't see much in the way of parent/child(ren) methods. I would think that each node can have a parent node, as well as any number of children.
    Is there an object like this (simple, small bit of code preferrably) that I can download/use, or does someone have a snippet in mind they can post that would be a valid object to represent an xml/dir tree the way I need?
    Thanks.

    I've seen this kind of think implemented very easily. You basically need a TreeNode object, which has a collection of children (which are also TreeNodes).
    You can use a Vector or Hashtable or some such for the children. I would also suggest maintaining a "parent" reference in each child.
    At that point, you simply implement the getters and setters that you want.
    Chances are you will also want to maintain some info about each node. You can be very specific (say providing a name and one or two other attributes), or you could introduce another collection: properties.
    I suggest you implement some kind of toString(), which lets you print out your tree.
    Finally, you may decide that you want to support access by path or relative path. It's useful, but paths are a pain in the butt - trickier code to get right.
    My estimate: A few hours for the basics, and then tweak it as you go.

  • Search event logs for file system access

    I'm looking to create a script that will allow me to search Windows 2012 security event logs for access to specific folders.  Ideally it would allow the granularity to search for read access events (4663) and specify specific users to view.  One
    example would be to show events for drive F:\ where the folder name is JSmith (including subfolders) and the username is not JSmith.
    I've tried something like this, but can't see how to filter.
    Get-EventLog security | ? {$_.Message.contains("F:\JSmith")}

    Is the match explicit?  How can I use wildcard?  How can I exclude events?
    I recommend asking a search engine and doing some initial research. Here's a starter:
    https://technet.microsoft.com/en-us/library/hh849682.aspx
    http://blogs.msdn.com/b/powershell/archive/2009/06/11/windows-event-log-in-powershell-part-ii.aspx
    http://blogs.technet.com/b/ashleymcglone/archive/2013/08/28/powershell-get-winevent-xml-madness-getting-details-from-event-logs.aspx
    http://blogs.technet.com/b/heyscriptingguy/archive/2011/01/24/use-powershell-cmdlet-to-filter-event-log-for-easy-parsing.aspx
    https://richardspowershellblog.wordpress.com/2009/03/08/get-winevent/
    Don't retire TechNet! -
    (Don't give up yet - 13,225+ strong and growing)

  • What is SMB/CIFS? Why does window ask for File System Authentication

    Set up: G5 dual processor tower w 2.5 GB sdram running OS 10.4.11
    Connected to MacBookPro 2.4 GHz IntelCore 2 Duo w 4 GB 667 MHz DDR2 SDRAM running OS 10.5.4
    via Airport.
    MacBookPro does not show up on Network from G5.
    But G5 tower is connected from MacBookPro.
    An alias appears on Network list from G5 with the identity "Mac001B638898Ba8". When it is clicked on to connect a window appears asking to enter the workgroup or domain and user name (both filled in automatically) and a password.
    No password I have ever used works when entered in the password box.
    What is going on? There is no Win machine anywhere near here that I have knowledge of.
    Thank you.

    You did not uninstall the original version and there may be some reference to a DVD based installed stored somewhere. The so-called repair install doesn't work, anyway. uninstall first, then reinstall. You may also need to manually delete the caps.db in C:\Program Files (x86)\common fiels\Adobe\caps. Notee that due to a bug in CS3 you may need to run this twice, that is uninstall, delete the ccaps.db, reinstall, uninstall again without deleting the caps.db, then reinstall a 2nd time or else you may see licensing errors.
    Mylenium

  • Maown - file system monitor for shared group directories

    Maown Info Page
    I needed a way to manage ownership and permissions of files in a shared directory. ACLs and "chmod g+s" alone were not enough so I wrote maown.
    Maown is a file system monitor written in C. It uses inotify to recursively watch a directory tree for file creation and attribute modification. It automatically chowns files to user:group and adjusts group permissions to match user permissions.
    The package includes a daemon with a simple configuration file. Each line in the configuration file specifies a user, a group and a list of directories to monitor:
    <user> <group> <directory> [<directory>...]
    Last edited by Xyne (2012-05-21 02:35:24)

    Maown has been replaced with Autochown.

  • In ODI where we maintain the folders for a file system

    Hi all
    For file system,I have to maintain different type of folders in Dev server.for example
    Input,Process,Error,Log,etc..Where we going to maintain these folders in the devlopment server?
    Can you be clear about the File system is maintained in the ODI environment?If pleease give any specified PDF.
    Regards
    suresh

    Hi Suresh
    To try to help you, could you give more details about what exactly you need?
    I couldn't understood what you need to know....
    Cezar Santos
    [www.odiexperts.com|www.odiexperts.com]

  • Required "/" (root) file system size on UNIX for Solution Manager.

    Hello SAP Gurus,
       I am setting up SAP Solution Manager 3.2 on HP-UX. It is asking me about 350MB free sapce on "/" file system for Central Instance installation and about 120MB free sapce on "/" file system for Database Instance installation.
       I am installaing everything on to shared disk which mounted under /usr/sap. Why it needs free sapce in "/" file system. Is there any workaround to get rid of this requirement, as I have very less free sapce on "/" file system and I don't want to take the risks involved in increasing this size.
       Are there any SAP recommended sizes for "/" file system?
       I stuck in the middle of setting up SAP landscape on HP-UX (11.23). I searched through the Installation documents but I couldn't find any thing helpful in this regard. It is urgent requirement to set up this so please let me know any solution or workaround ASAP.
       Any help is greatly appriciated.
    Thanks in advance.
    Regards,
    cvr/

    Hi Vaibhav.
    Normally "canonical path not available for (folder name)" means:
    1. Wrong username/password. Please double check you credentials.
    2. The resource cannot be linked from the portal server. Please be sure that you can connect to the next ports in windows server from the Unix Server:
    a. NetBIOS Session Service TCP 139 This port is used to connect file shares for example.
    b. TCP 445 The SMB (Server Message Block) protocol is used among other things for file sharing in Windows NT/2000/XP. In windows NT it ran on top of NetBT (NetBIOS over TCP/IP), which used the famous ports 137, 138 (UDP) and 139 (TCP). In Windows 2000/XP/2003, Microsoft added the possibility to run SMB directly over TCP/IP, without the extra layer of NetBT. For this they use TCP port 445.
    I hope these things help somebody.
    Best Regards,
    Jheison A. Urzola H.

Maybe you are looking for

  • How to use your Apple Id account on mac apps without a credit card?

    I'm quite new with this whole apple business as I've never used Apple products before. But now that i got a new macbook, the mac app store says I have an update for my iPhoto. I want to download the update using my newly created Apple ID but I do not

  • Single Frame Displays on External Monitor

    I have been searching online for the past three hours, trying to find a solution to this. I have found threads describing similar problems, however, I have done everything suggested in those threads, and nothing seems to work. I am at my wit's end. T

  • Syntax error in query expression

    I am receiving the following error message: Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'customerid_cus='. for the following code: If IsEmpty(Request.Form("company_cus")) Then rs_company.Source = "SELE

  • 1602 Series AP Support Mesh

    Does anyone know if the 1602 AP can support mesh?? Sent from Cisco Technical Support iPhone App

  • Getting an iPhone 5 fixed/replaced on someones behalf

    Hi, Not sure if this has been asked before but a quick google search came up with nothing... My cousin has got a faulty iPhone 5... The issue is her Power button not working correctly... Since she is still in school and can not make it to the nearest