IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

permissions on created file when using the I/O adapter

  • 1.  permissions on created file when using the I/O adapter

    Posted Wed January 16, 2002 02:08 PM

    When using the operation File Write within the I/O adapter on a Unix machine, is there a way to specify the file permissions for this file.

    Currently when the file is created then I must go into the Unix environment and chmod the specific files. Is there an automatic way to accomplish this?

    Thanks in advance for your answer.

    -Michael E. Engelby
    Gelco Information Network


    #webMethods
    #Integration-Server-and-ESB
    #Adapters-and-E-Standards


  • 2.  RE: permissions on created file when using the I/O adapter

    Posted Thu January 17, 2002 08:29 AM

    By default the IO adapter writes the file out with user permissoins of rw and no permissions for the group or others. To fix this, you can modify the adaptermonitor script and change the ‘umask’ command appropriately.

    Modify:
    ${ACTIVE_HOME}/bin/adaptermonitor script.

    Originally, it came set to as follows:

    umask=0077

    (The last three bits are important. i.e, the 077)

    What this does is as follows: files created by any succeeding child
    processes spawned off would have the permissions as follows:

    700
    user: Read/Write/Execute
    group: No Read/No Write/No Execute
    others: No Read/No Write/No Execute

    You will need to modify the ${ACTIVE_HOME}/bin/adaptermonitor on every system
    running it to:

    umask=0007

    This changed the permissions of files created as follows:

    770
    user: Read/Write/Execute
    group: Read/Write/Execute
    others: No Read/No Write/No Execute


    #Adapters-and-E-Standards
    #webMethods
    #Integration-Server-and-ESB


  • 3.  RE: permissions on created file when using the I/O adapter

    Posted Fri March 08, 2002 01:54 AM

    You can write your own java code to call system command to do chmod for you such as.

    Runtime rt = Runtime.getRuntime();
    String cmd = "chmod o+rw "+ filename;
    Process p = rt.exec(cmd);


    #webMethods
    #Integration-Server-and-ESB
    #Adapters-and-E-Standards