5 Replies Latest reply: Jul 5, 2011 5:23 AM by Dude! RSS

    umask

    479722
      Hi, is there anyway we can over come UMASK value assigned permission for one particular file generation activity ( my oracle util service created file is not able to delete by other users )

      file being created with -rw rr actually need -rw-rw-rw, appreciate your help.

      thanks
        • 1. Re: umask
          Dude!
          How about the following command:

          chmod a+w filename

          You can also redefine umask at the command prompt prior to creating the file, i.e.

          umask 0000

          then create the file.
          • 2. Re: umask
            479722
            Hi dude,
            Yes, I scheduled permission command but we need in real time as files are lot more than 1000 per hour.
            These files been created by a procedure over util process, let me test umask 0000 and revert.
            Thanks.
            • 3. Re: umask
              Dude!
              Perhaps it would be a better idea to fix or modify the program that creates all these files.
              • 4. Re: umask
                830567
                thanks dude, any guideline for pl/sql procedure change, below is sample for file creation

                CREATE DIRECTORY test_dir AS 'c:\';
                -- CREATE DIRECTORY test_dir AS '/tmp';

                DECLARE
                fileHandler UTL_FILE.FILE_TYPE;
                BEGIN
                fileHandler := UTL_FILE.FOPEN('test_dir', 'test_file.txt', 'W');
                UTL_FILE.PUTF(fileHandler, 'Writing TO a file\n');
                UTL_FILE.FCLOSE(fileHandler);
                EXCEPTION
                WHEN utl_file.invalid_path THEN
                raise_application_error(-20000, 'ERROR: Invalid PATH FOR file.');
                END;
                /
                • 5. Re: umask
                  Dude!
                  I think the SQL and PL/SQL at PL/SQL might be a better place to post questions about PL/SQL procedures.

                  You should also find some useful info searching in Google for "utl_file umask".

                  What I was thinking is to change the procedure that calls the function that actually creates the 1000 files per hour.