Permission to write georaster into filesystem

hi,
i have an oracle sdo_georaster problem. my procedure:
CREATE OR REPLACE PROCEDURE EXPORT_GEORASTER_FILE(
RID NUMBER,
IMG_FNAME VARCHAR,
FILETYP INTEGER,
P_LEVEL NUMBER,
CA_ULX NUMBER,
CA_ULY NUMBER,
CA_LRX NUMBER,
CA_LRY NUMBER
IS
GR SDO_GEORASTER;
FINALSTRING VARCHAR(500);
FT VARCHAR(20);
CA VARCHAR(300);
PLEVEL VARCHAR(40);
BEGIN
IF FILETYP = 0 THEN
FT := 'TIFF';
ELSIF FILETYP = 1 THEN
FT := 'BMP';
ELSIF FILETYP = 2 THEN
FT := 'PNG';
ELSE
FT := 'PNG';
END IF;
IF P_LEVEL IS NULL THEN
PLEVEL := 0;
ELSE
PLEVEL := NULL;
END IF;
IF CA_ULX IS NULL AND CA_ULY IS NULL AND CA_LRX IS NULL AND CA_LRY IS NULL THEN
CA := NULL;
ELSE
CA := 'CROPAREA=('|| CA_ULX || ', ' || CA_ULY || ', ' || CA_LRX || ', ' || CA_LRY ||')';
END IF;
FINALSTRING := 'PLEVEL = ' || P_LEVEL || ', ' || CA;
SELECT GEORASTER INTO GR FROM T99_GEORASTER WHERE ID = RID;
--SDO_GEOR.EXPORTTO(GR, FINALSTRING, FT, 'FILE', IMG_FNAME, 'WORLDFILE', 'FILE', TFW_FNAME);
SDO_GEOR.EXPORTTO(GR, NULL, FT, 'FILE', 'c:\bla1', 'WORLDFILE', 'FILE', 'c:\bla1');
END;
works fine but i'm unable to write in the filesystem. after execute my procedure i get the following message:
SQL> exec EXPORT_GEORASTER_FILE(1,'c:\bla',0,0,null,null,null,null);
BEGIN EXPORT_GEORASTER_FILE(1,'c:\bla',0,0,null,null,null,null); END;
ERROR at line 1:
ORA-13463: error retrieving GeoRaster data: the Permission
(java.io.FilePermission c:\bla1.tfw write) has not been granted to MDSYS. The
PL/SQL to grant this is dbms_java.grant_permission( 'MDSYS',
'SYS:java.io.FilePermission', 'c:\bla1.tfw', 'write' )
ORA-06512: at "MDSYS.MD", line 1723
ORA-06512: at "MDSYS.MDERR", line 17
ORA-06512: at "MDSYS.SDO_GEOR", line 3048
ORA-06512: at "RASTER.EXPORT_GEORASTER_FILE", line 45
ORA-06512: at line 1
now i connected wto ora with system (dba) and tried:
SQL> CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\'
, 'WRITE' );
but i get the exception:
CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\', 'WR
ITE' )
ERROR at line 1:
ORA-29532: Java call terminated by uncaught Java exception:
java.lang.SecurityException: policy table update SYS:JAVA.IO.FILEPERMISSION,
C:\
SQL> CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\b
la1.tfw', 'WRITE' );
CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\bla1.t
fw', 'WRITE' )
ERROR at line 1:
ORA-29532: Java call terminated by uncaught Java exception:
java.lang.SecurityException: policy table update SYS:JAVA.IO.FILEPERMISSION,
C:\bla1.tfw
i don't know why i get the exception. is there a problem with my java rights?
can anybody help me?
thanks a lot,
michael

Hi Dan!
Thanks for your tip. The roblem was that not my user RASTER (who are owner of sdo_raster) has the WRITE-Permission. So I gave it to MDSYS and RASTER with the following result:
SQL> exec export_georaster_file(1,'e:\bla\bla1',0,NULL,NULL,NULL,NULL,NULL);
-13463
BEGIN export_georaster_file(1,'e:\bla\bla1',0,NULL,NULL,NULL,NULL,NULL); END;
ERROR at line 1:
ORA-13463: error retrieving GeoRaster data: the Permission
(java.io.FilePermission e:\bla\bla1.tfw write) has not been granted to RASTER.
The PL/SQL to grant this is dbms_java.grant_permission( 'RASTER',
'SYS:java.io.FilePermission', 'e:\bla\bla1.tfw', 'write' )
ORA-06512: at "MDSYS.MD", line 1723
ORA-06512: at "MDSYS.MDERR", line 17
ORA-06512: at "MDSYS.SDO_GEOR", line 3048
ORA-06512: at "RASTER.EXPORT_GEORASTER_FILE", line 45
ORA-06512: at line 1
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Pr
oduction
With the Partitioning, OLAP and Data Mining options
C:\>sqlplus system/***********
SQL*Plus: Release 10.1.0.2.0 - Production on Mo Aug 30 09:55:37 2004
Copyright (c) 1982, 2004, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> call dbms_java.grant_permission( 'RASTER',
2 'SYS:java.io.FilePermission', 'e:\bla\bla1.tfw', 'write' );
Call completed.
SQL> call dbms_java.grant_permission( 'RASTER',
2 'SYS:java.io.FilePermission', 'e:\bla\bla1.tif', 'write' )
3 ;
Call completed.
SQL> CALL dbms_java.grant_permission( 'MDSYS',
2 'SYS:java.io.FilePermission', 'e:\bla\bla1.tif', 'write' )
3 ;
Call completed.
SQL> CALL dbms_java.grant_permission( 'MDSYS',
2 'SYS:java.io.FilePermission', 'e:\bla\bla1.tfw', 'write' );
Call completed.
SQL> commit;
Commit complete.
SQL> exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Pr
oduction
With the Partitioning, OLAP and Data Mining options
C:\>sqlplus raster/*******
SQL*Plus: Release 10.1.0.2.0 - Production on Mo Aug 30 10:00:06 2004
Copyright (c) 1982, 2004, Oracle. All rights reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.1.0.2.0 - Production
With the Partitioning, OLAP and Data Mining options
SQL> exec export_georaster_file(1,'e:\bla\bla1',0,NULL,NULL,NULL,NULL,NULL);
PL/SQL procedure successfully completed.
SQL>
Thanks to you,
michael

Similar Messages

  • Write file into filesystem of fileserver

    hi,
    I must write a file into filesystem of an fileserver. Does anyone know how could I write a file in any filesystem (e.g.
    server\test\...)?
    'GUI_DOWNLOAD' doesnt work, because my program run's in batch job.
    Thanks
    markus

    Hi,
    You can download the file in application server as a background job.Kindly reward points if the sample code helps.
    PARAMETERS : p_appl RADIOBUTTON GROUP rad1 DEFAULT 'X' USER-COMMAND rad,
                 p_afile TYPE rlgrap-filename DEFAULT g_appl.
    types : BEGIN OF ty_output,
            record(362) TYPE c,    
            END OF ty_output.
    data t_output TYPE STANDARD TABLE OF ty_output.
    Local variable Declaration
      DATA l_msg(60) TYPE c.
    Opening the file for output in text mode
      OPEN DATASET p_afile FOR OUTPUT IN TEXT MODE ENCODING DEFAULT
                                                      MESSAGE l_msg.
      IF sy-subrc NE 0.
        "Error in opening file for output
        LEAVE LIST-PROCESSING.
      ENDIF.
      LOOP AT t_output INTO w_output.
        TRANSFER w_output TO p_afile .
      ENDLOOP.
    Closing the file
      CLOSE DATASET p_afile.
      IF sy-subrc NE 0.
      "Error in closing file
        LEAVE LIST-PROCESSING.
      ENDIF.

  • Permission to write into filesystem

    hi,
    i have an oracle sdo_georaster problem. my procedure:
    CREATE OR REPLACE PROCEDURE EXPORT_GEORASTER_FILE(
    RID NUMBER,
    IMG_FNAME VARCHAR,
    FILETYP INTEGER,
    P_LEVEL NUMBER,
    CA_ULX NUMBER,
    CA_ULY NUMBER,
    CA_LRX NUMBER,
    CA_LRY NUMBER
    IS
    GR SDO_GEORASTER;
    FINALSTRING VARCHAR(500);
    FT VARCHAR(20);
    CA VARCHAR(300);
    PLEVEL VARCHAR(40);
    BEGIN
    IF FILETYP = 0 THEN
    FT := 'TIFF';
    ELSIF FILETYP = 1 THEN
    FT := 'BMP';
    ELSIF FILETYP = 2 THEN
    FT := 'PNG';
    ELSE
    FT := 'PNG';
    END IF;
    IF P_LEVEL IS NULL THEN
    PLEVEL := 0;
    ELSE
    PLEVEL := NULL;
    END IF;
    IF CA_ULX IS NULL AND CA_ULY IS NULL AND CA_LRX IS NULL AND CA_LRY IS NULL THEN
    CA := NULL;
    ELSE
    CA := 'CROPAREA=('|| CA_ULX || ', ' || CA_ULY || ', ' || CA_LRX || ', ' || CA_LRY ||')';
    END IF;
    FINALSTRING := 'PLEVEL = ' || P_LEVEL || ', ' || CA;
    SELECT GEORASTER INTO GR FROM T99_GEORASTER WHERE ID = RID;
    --SDO_GEOR.EXPORTTO(GR, FINALSTRING, FT, 'FILE', IMG_FNAME, 'WORLDFILE', 'FILE', TFW_FNAME);
    SDO_GEOR.EXPORTTO(GR, NULL, FT, 'FILE', 'c:\bla1', 'WORLDFILE', 'FILE', 'c:\bla1');
    END;
    works fine but i'm unable to write in the filesystem. after execute my procedure i get the following message:
    SQL> exec EXPORT_GEORASTER_FILE(1,'c:\bla',0,0,null,null,null,null);
    BEGIN EXPORT_GEORASTER_FILE(1,'c:\bla',0,0,null,null,null,null); END;
    ERROR at line 1:
    ORA-13463: error retrieving GeoRaster data: the Permission
    (java.io.FilePermission c:\bla1.tfw write) has not been granted to MDSYS. The
    PL/SQL to grant this is dbms_java.grant_permission( 'MDSYS',
    'SYS:java.io.FilePermission', 'c:\bla1.tfw', 'write' )
    ORA-06512: at "MDSYS.MD", line 1723
    ORA-06512: at "MDSYS.MDERR", line 17
    ORA-06512: at "MDSYS.SDO_GEOR", line 3048
    ORA-06512: at "RASTER.EXPORT_GEORASTER_FILE", line 45
    ORA-06512: at line 1
    now i connected wto ora with system (dba) and tried:
    SQL> CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\'
    , 'WRITE' );
    but i get the exception:
    CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\', 'WR
    ITE' )
    ERROR at line 1:
    ORA-29532: Java call terminated by uncaught Java exception:
    java.lang.SecurityException: policy table update SYS:JAVA.IO.FILEPERMISSION,
    C:\
    SQL> CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\b
    la1.tfw', 'WRITE' );
    CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\bla1.t
    fw', 'WRITE' )
    ERROR at line 1:
    ORA-29532: Java call terminated by uncaught Java exception:
    java.lang.SecurityException: policy table update SYS:JAVA.IO.FILEPERMISSION,
    C:\bla1.tfw
    i don't know why i get the exception. is there a problem with my java rights?
    can anybody help me?
    thanks a lot,
    michael

    hi,
    i have an oracle sdo_georaster problem. my procedure:
    CREATE OR REPLACE PROCEDURE EXPORT_GEORASTER_FILE(
    RID NUMBER,
    IMG_FNAME VARCHAR,
    FILETYP INTEGER,
    P_LEVEL NUMBER,
    CA_ULX NUMBER,
    CA_ULY NUMBER,
    CA_LRX NUMBER,
    CA_LRY NUMBER
    IS
    GR SDO_GEORASTER;
    FINALSTRING VARCHAR(500);
    FT VARCHAR(20);
    CA VARCHAR(300);
    PLEVEL VARCHAR(40);
    BEGIN
    IF FILETYP = 0 THEN
    FT := 'TIFF';
    ELSIF FILETYP = 1 THEN
    FT := 'BMP';
    ELSIF FILETYP = 2 THEN
    FT := 'PNG';
    ELSE
    FT := 'PNG';
    END IF;
    IF P_LEVEL IS NULL THEN
    PLEVEL := 0;
    ELSE
    PLEVEL := NULL;
    END IF;
    IF CA_ULX IS NULL AND CA_ULY IS NULL AND CA_LRX IS NULL AND CA_LRY IS NULL THEN
    CA := NULL;
    ELSE
    CA := 'CROPAREA=('|| CA_ULX || ', ' || CA_ULY || ', ' || CA_LRX || ', ' || CA_LRY ||')';
    END IF;
    FINALSTRING := 'PLEVEL = ' || P_LEVEL || ', ' || CA;
    SELECT GEORASTER INTO GR FROM T99_GEORASTER WHERE ID = RID;
    --SDO_GEOR.EXPORTTO(GR, FINALSTRING, FT, 'FILE', IMG_FNAME, 'WORLDFILE', 'FILE', TFW_FNAME);
    SDO_GEOR.EXPORTTO(GR, NULL, FT, 'FILE', 'c:\bla1', 'WORLDFILE', 'FILE', 'c:\bla1');
    END;
    works fine but i'm unable to write in the filesystem. after execute my procedure i get the following message:
    SQL> exec EXPORT_GEORASTER_FILE(1,'c:\bla',0,0,null,null,null,null);
    BEGIN EXPORT_GEORASTER_FILE(1,'c:\bla',0,0,null,null,null,null); END;
    ERROR at line 1:
    ORA-13463: error retrieving GeoRaster data: the Permission
    (java.io.FilePermission c:\bla1.tfw write) has not been granted to MDSYS. The
    PL/SQL to grant this is dbms_java.grant_permission( 'MDSYS',
    'SYS:java.io.FilePermission', 'c:\bla1.tfw', 'write' )
    ORA-06512: at "MDSYS.MD", line 1723
    ORA-06512: at "MDSYS.MDERR", line 17
    ORA-06512: at "MDSYS.SDO_GEOR", line 3048
    ORA-06512: at "RASTER.EXPORT_GEORASTER_FILE", line 45
    ORA-06512: at line 1
    now i connected wto ora with system (dba) and tried:
    SQL> CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\'
    , 'WRITE' );
    but i get the exception:
    CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\', 'WR
    ITE' )
    ERROR at line 1:
    ORA-29532: Java call terminated by uncaught Java exception:
    java.lang.SecurityException: policy table update SYS:JAVA.IO.FILEPERMISSION,
    C:\
    SQL> CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\b
    la1.tfw', 'WRITE' );
    CALL DBMS_JAVA.GRANT_PERMISSION('MDSYS','SYS:JAVA.IO.FILEPERMISSION', 'C:\bla1.t
    fw', 'WRITE' )
    ERROR at line 1:
    ORA-29532: Java call terminated by uncaught Java exception:
    java.lang.SecurityException: policy table update SYS:JAVA.IO.FILEPERMISSION,
    C:\bla1.tfw
    i don't know why i get the exception. is there a problem with my java rights?
    can anybody help me?
    thanks a lot,
    michael

  • IPhoto: Unable to write to library. Check that you have permission to write to the library directory

    I have been asked to submit a new thread regarding iPhoto's recent inability to write to library.
    The original thread can be found here.
    SPECS:
    Mac Mini (Mid 2011)
    OSX 10.10.2
    Seagate 4TB External HDD, formatted to Mac OS External (Journaled) (purchased 8 Feb 2015)
    Previously, "Ignore ownership on this volume" was not ticked. Now it has been selected.
    Before 30 March, iPhoto Library located on the Seagate external HDD worked fine with no errors. It was previous copied from Carbon Copy Cloner from one of my Samsung internal HDD in my Mac Mini that had a S.M.A.R.T. failure. There were errors with particular thumbnails and files (I assume had corrupted due to the internal HDD failing) but CCC did as directed and copied the entire iPhoto Library to the new Seagate external HDD.
    It seems that after installing the latest iPhoto update:
    iPhoto version 9.6.1 from the App Store (installed March 30, 2015), iPhoto no longer has "permission" to write to library when opened:
    (Could this be a program with the latest software update?)
    Upon accessing the Photo Library First Aid control panel (holding Option+Command keys and selecting iPhoto):
    And selecting the first option, "Repair Permission,"
    I still receive the error message (doesn't even start repairing photo library permissions):
    What else should I do? It won't let me "Rebuild Database" either. I have restarted the Mac Mini. I haven't tried disconnecting the external HDD. And I do not have another HDD big enough to transfer the entire iPhoto Library to see if it is my iPhoto Library that has corrupted, or the new Seagate external HDD that has decided not to play nice. Suggestions would be greatly appreciated!

    OK. I've been trying to workshop this some more.
    AFTER restarting my Mac Mini, I selected "Get Info" on this Seagate external HDD, and low and behold, "everyone" sharing & permissions was reset back to "Read Only." I attempted to move a folder into this external HDD and was as to "Authenticate" the move. So entering my Administrator password, the folder can be moved.
    I went into Disk Utility to "Verify Disk" and I now get the green text "This volume appears to be OK."
    But I am UNABLE to "Ignore ownership on this volume."
    I receive the following error message:
    The operation can't be completed. "An unexpected error occurred (error code -8076)."
    I am pulling my hair out!

  • I upgraded my OS in my Mac and now I cab't open iTunes. Error message says the iTunes library is locked, in a locked disk or I don't have permission to write.

    I upgraded my OS from Lion to Mountain Lion. After that I can't access or open Itunes anymore. Message says " Itunes library is locked, in a locked disc or I don't have permission to write permission for this file.

    Back up all data. Don't continue unless you're sure you can restore from a backup, even if you're unable to log in.
    This procedure will unlock all your user files (not system files) and reset their ownership and access-control lists to the default. If you've set special values for those attributes on any of your files, they will be reverted. In that case, either stop here, or be prepared to recreate the settings if necessary. Do so only after verifying that those settings didn't cause the problem. If none of this is meaningful to you, you don't need to worry about it.
    Step 1
    If you have more than one user account, and the one in question is not an administrator account, then temporarily promote it to administrator status in the Users & Groups preference pane. To do that, unlock the preference pane using the credentials of an administrator, check the box marked Allow user to administer this computer, then reboot. You can demote the problem account back to standard status when this step has been completed.
    Triple-click the following line on this page to select it. Copy the selected text to the Clipboard (command-C):
    { sudo chflags -R nouchg,nouappnd ~ $TMPDIR.. ; sudo chown -R $UID:staff ~ $_ ; sudo chmod -R u+rwX ~ $_ ; chmod -R -N ~ $_ ; } 2> /dev/null
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Paste into the Terminal window (command-V). You'll be prompted for your login password. Nothing will be displayed when you type it. You may get a one-time warning to be careful. If you don’t have a login password, you’ll need to set one before you can run the command. If you see a message that your username "is not in the sudoers file," then you're not logged in as an administrator.
    The command will take a noticeable amount of time to run. Wait for a new line ending in a dollar sign (“$”) to appear, then quit Terminal.
    Step 2 (optional)
    Take this step only if you have trouble with Step 1 or if it doesn't solve the problem.
    Boot into Recovery. When the OS X Utilities screen appears, select
    Utilities ▹ Terminal
    from the menu bar. A Terminal window will open.
    In the Terminal window, type this:
    res
    Press the tab key. The partial command you typed will automatically be completed to this:
    resetpassword
    Press return. A Reset Password window will open. You’re not  going to reset a password.
    Select your boot volume ("Macintosh HD," unless you gave it a different name) if not already selected.
    Select your username from the menu labeled Select the user account if not already selected.
    Under Reset Home Directory Permissions and ACLs, click the Reset button.
    Select
     ▹ Restart
    from the menu bar.

  • Permission to write

    I have a MacBook Pro.  I have several pages and numbers documents saved to my Desktop.  Suddenly when I try to open and edit the files they all say "You don't have permission to write to the folder that this file is in."  It then directs me to make a duplicate of the file so I can edit it.  When I duplicate it, make the changes, and try to save it again, it says, "The Document could not be saved.  You do not have permission." It tells me to choose "File>Get Info" to make changes.  I have done this several times.  I tried unlocking the document.  I tried changing all the settings to "read and write" for myself, and every other user on my computer.  Nothing seems to work.  Please HELP.

    Repairing the permissions of a home folder in Lion is a complicated procedure. I don’t know of a simpler one that always works.
    Launch the Terminal application by entering the first few letters of its name into a Spotlight search. Drag or copy -- do not type -- the following line into the window, then press return:
    chmod -R -N ~
    If you get an error message about permissions, enter this:
    sudo !!
    You'll be prompted for your login password, which won't be displayed when you type it. You may get a one-time warning not to screw up.
    Next, boot from your recovery partition by holding down the key combination command-R at startup. Release the keys when you see a gray screen with a spinning dial.
    When the recovery desktop appears, select Utilities ▹ Terminal from the menu bar.
    In the Terminal window, enter “resetpassword” (without the quotes) and press return. A Reset Password window opens.
    Select your boot volume if not already selected.
    Select your username from the menu labeled Select the user account if not already selected.
    Under Reset Home Directory Permissions and ACLs, click the Reset button.
    Select  ▹ Restart from the menu bar.

  • Soundtrack Pro told me I "don't have permission to write it."

    This has never happened before. Found the FX track I want, a .caf file if that makes a diferance, clicked on it to put in the Edit window, did Command 'S' to save it and this came up:
    "Couldn't save the document because you don't have permission to write it."
    All the premissions, on the top Apple Loops floders are all "Read, Write".
    This is new to me. I could 'Save Copy as.." and save it as an .aiff file to use in FCP.
    Should I stop carring about it since I CAN get a copy?
    Bounus question: Why does YouTube flag my videos for using copywrited material (and may be blocked in some countries) when all the music I use comes out of SoundTrack Pro?

    Repairing the permissions of a home folder in Lion is a complicated procedure. I don’t know of a simpler one that always works.
    Back up all data now. Before proceeding, you must be sure you can restore your system to its present state
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the page that opens.
    Drag or copy — do not type — the following line into the Terminal window, then press return:
    chmod -R -N ~
    The command will take a noticeable amount of time to run. When a new line ending in a dollar sign ($) appears below what you entered, it’s done. You may see a few error messages about an “invalid argument” while the command is running. You can ignore those. If you get an error message with the words “Permission denied,” enter this:
    sudo !!
    You'll be prompted for your login password, which won't be displayed when you type it. You may get a one-time warning not to screw up.
    Next, boot from your recovery partition by holding down the key combination command-R at startup. Release the keys when you see a gray screen with a spinning dial.
    When the recovery desktop appears, select Utilities ▹ Terminal from the menu bar.
    In the Terminal window, enter “resetpassword” (without the quotes) and press return. A Reset Password window opens. You’re not going to reset the password.
    Select your boot volume if not already selected.
    Select your username from the menu labeled Select the user account if not already selected.
    Under Reset Home Directory Permissions and ACLs, click the Reset button.
    Select  ▹ Restart from the menu bar.

  • "Don't have permission to write..." message?

    Since upgrading to ML, I've been getting messages when I attempt to edit the contents of some folders which read, "You do not have permission to write to the folder that the (file name) file is in." I'm the only user of my laptop, and to my knowledge never changed any of the security settings, so I'm guessing something got changed when I upgraded to 10.8.4.
    I cna't figure out when and where these permission issues are coming from.
    I'm listed as Admin in the Users & Groups; nothing is checked in the Security & Privacy panel.
    I need access to everything on.There have been a few other notices, all along the same lines. I'm assuming there's some setting or authentication that got changed in ML. What am I missing?
    tia

    Back up all data. Don't continue unless you're sure you can restore from a backup, even if you're unable to log in.
    This procedure will unlock all your user files (not system files) and reset their ownership and access-control lists to the default. If you've set special values for those attributes on any of your files, they will be reverted. In that case, either stop here, or be prepared to recreate the settings if necessary. Do so only after verifying that those settings didn't cause the problem. If none of this is meaningful to you, you don't need to worry about it.
    Step 1
    If you have more than one user account, and the one in question is not an administrator account, then temporarily promote it to administrator status in the Users & Groups preference pane. To do that, unlock the preference pane using the credentials of an administrator, check the box marked Allow user to administer this computer, then reboot. You can demote the problem account back to standard status when this step has been completed.
    Triple-click the following line on this page to select it. Copy the selected text to the Clipboard (command-C):
    { sudo chflags -R nouchg,nouappnd ~ $TMPDIR.. ; sudo chown -R $UID:staff ~ $_ ; sudo chmod -R u+rwX ~ $_ ; chmod -R -N ~ $_ ; } 2> /dev/null
    Launch the Terminal application in any of the following ways:
    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)
    ☞ In the Finder, select Go ▹ Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.
    ☞ Open LaunchPad. Click Utilities, then Terminal in the icon grid.
    Paste into the Terminal window (command-V). You'll be prompted for your login password. Nothing will be displayed when you type it. You may get a one-time warning to be careful. If you don’t have a login password, you’ll need to set one before you can run the command. If you see a message that your username "is not in the sudoers file," then you're not logged in as an administrator.
    The command will take a noticeable amount of time to run. Wait for a new line ending in a dollar sign (“$”) to appear, then quit Terminal.
    Step 2 (optional)
    Take this step only if you have trouble with Step 1 or if it doesn't solve the problem.
    Boot into Recovery. When the OS X Utilities screen appears, select
    Utilities ▹ Terminal
    from the menu bar. A Terminal window will open.
    In the Terminal window, type this:
    res
    Press the tab key. The partial command you typed will automatically be completed to this:
    resetpassword
    Press return. A Reset Password window will open. You’re not  going to reset a password.
    Select your boot volume ("Macintosh HD," unless you gave it a different name) if not already selected.
    Select your username from the menu labeled Select the user account if not already selected.
    Under Reset Home Directory Permissions and ACLs, click the Reset button.
    Select
     ▹ Restart
    from the menu bar.

  • After upgrading to the latest version of itune, I get this message when trying to open itunes: "The I'tunes Library File is locked, on a locked disk, or you do not have permission to write for this file.

    After importing the latest version of itune, I now get this message:  "The I-tunes library file is locked, on a locked disk , or you do not have permission to write for this file.  How do I resolve this?

    check if you have read & write permissions for your music folder. in the finder, right-click on it and get info. unlock the little padlock (you may have to enter your admin password) and change the permission settings if necessary. next, click on the little gear-shaped icon and apply to enclosed items like so
    the important part is to apply to enclosed items !
    also, even if it seems unrelated, try the steps in this support article: iTunes: Missing folder or incorrect permissions may prevent authorization

  • Write arrays into a text file in different columns at different times

    Hi,
              I have a problem write data into a text file. I want to write 4 1D arrays into a text file. The problem is that I need to write it at different time and in different column (in other word, not only append the arrays).
    Do you have an idea to solve my problem?
    Thank you

    A file is long a linear string of data (text). In order ro insert columns, you need to rewrite the entire file, because colums are interlaced over the entire lenght of the file.
    So:
    read file into 2D array
    insert columns using array operations
    write resulting 2D array to file again.
    (Only if your colums are guaranteed to be fixed width AND you know the final number of colums, you could write the missing columns as spaces and then overwrite later. Still, it will be painful and inefficient, because column data are not adjacent in the file.)
    LabVIEW Champion . Do more with less code and in less time .

  • Eventually denied permission to write in home directory

    Hello,
    My wife is using a Mid-2007, 2.4GHz Intel Core 2 Duo iMac (iMac7,1) with 6GB RAM and more than 1TB of free available HD space.  She is running Mountain Lion (10.8.3) and has administrator privileges.
    After she has been using the computer for a while (hours or days; it varies), the system eventually denies her writing privileges to folders in her own Home directory. 
    I'll give two common examples:
    She'll download a file in Safari (or iTunes), and everything appears to proceed normally until the download "finishes" at which point she receives an error message that says she doesn't have permission to write to the save location.  The download remains in her browser's download list, but the file itself "disappears".  Changing target directories (e.g. from Downloads to Desktop) makes no difference.
    TextEdit will automatically reopen upon log in, and display one or more SavedState "Untitled" documents with text in them (she uses it as a scratch pad). When she attempts to add text to one of these documents, e.g. "Untitled 8," an error appears that says she does not have permission to make changes to the document and is prompted to make a Duplicate, so she does so.  She can successfully enter text in "Untitled 8 (copy)" but when it comes time to save the file, another error is returned that claims she does not have permission to write to [whatever location].
    Only two things seem to correct this situation, neither of which are permanent. That is, it eventually happens again.
    1. She logs out and logs back in. Things will behave normally for a while.  This is a pain, of course, because she typically discovers the problem when she is in the middle on working on one or more things, and the login process is fairly slow (as are most things on this iMac since upgrading to Mountain Lion -- though better since restricting the activity of Sophos Antivirus).
    2. Repair the permissions in her Home directory:  Get Info, click the lock & enter her password, change the Privilege of Me from Read & Write to Read Only, then back to Read & Write, and finally click the gear so as to Apply to enclosed items.  Once this is finished, access is restored... until it happens again.  Funny thing about this particular procedure is that her permissions appear to be set normally at the outset, ie., Read & Write.
    Another odd thing about the download problem is that the system does not seem to have a problem writing to whatever temporary directory it uses during the downloading process. The error only comes once the file is complete.
    There does not seem to be any precipitating event that leads to this change in her permissions/access privileges.
    Repairing permissions using Disk Utility does not resolve the problem.
    Running other kinds of repairs (repair disk when booted in Recovery Mode, running Drive Genius 3 from a separate partition or from the optical media, TechTool Pro, etc.) do not resolve the problem.
    When I log in to this same computer using my account (also with admin privileges), I have yet to encounter this eventual-permission-denial problem.
    Any thoughts or recommendations are welcome, obviously.  This is driving us batty!

    Hmmm, sounded like a RAM problem until you mentioned your account doesn't do it.
    One way to test is to Safe Boot from the HD, (holding Shift key down at bootup), run Disk Utility in Applications>Utilities, then highlight your drive, click on Repair Permissions, Test for problem in Safe Mode...
    PS. Safe boot may stay on the gray radian for a long time, let it go, it's trying to repair the Hard Drive
    Reboot, test again.
    If it only does it in Regular Boot, then it could be some hardware problem like Video card, (Quartz is turned off in Safe Mode), or Airport, or some USB or Firewire device, or 3rd party add-on, Check System Preferences>Accounts (Users & Groups in later OSX versions)>Login Items window to see if it or something relevant is listed.
    Check the System Preferences>Other Row, for 3rd party Pref Panes.
    Also look in these if they exist, some are invisible...
    /private/var/run/StartupItems
    /Library/StartupItems
    /System/Library/StartupItems
    /System/Library/LaunchDaemons
    /Library/LaunchDaemons

  • Read Write Data into a MS Word document

    The requirement I am fullfilling directly specifies the need to write data into a Microsoft Word Document and if Necessary, Read Back data from a Microsoft Word Document. The data will be simple text but as time goes on I anticipate the systems engineers may expand the requirement. I want to cross one bridge at a time so I am just concentrating on the text issue. I must do it from within a stand-alone application. Not through a server, not through ASP, not through a browser, just a stand alone application. It appears from my own investigation of the JAVA API that this is not possible. Regrettably, I am only a day or so away from switching to C# or VB to get this job done. My first question is
    1. Can Java Do this?
    2. If not, does Sun Microsystems have any plans to add this capabiliy?
    3. Can we make recommendations to Sun to add this capability to JAVA?

    1. Can Java Do this?Java can do anything but there is no built-in ability to do just that.
    2. If not, does Sun Microsystems have any plans to add
    this capabiliy?
    3. Can we make recommendations to Sun to add this
    capability to JAVA?Very doubtful! MS Office document formats are not completely open to the public - and they are weird! Supporting this capability would probably require an agreement with Microsoft and it would mean you had to change the API for every time Microsoft chooses to change the document formats.
    But there are some open source tools that claim to be rather good at reading and writing MS Office files. Take a look at this one:
    http://jakarta.apache.org/poi/index.html

  • Uploading file to the servelet and write directly into database

    i want client to upload file to the server (using servlet for that) and i just don't want to store it to the hard disk, but i want to write it
    into the the ms sql database (that i m using).
    TIA

    Here is a good site for learning how to upload a file using a servlet:
    http://www.servlets.com/cos/index.html
    Once you get the file in the servlet you shouldn't have any problem storing it to a DB.

  • Unable to write to library iPhoto library Check that you have permission to write to the library directory

    I think my iPhoto memory is full. I cannot get in to delete photos.  When I open it I get the Unable to write to library iPhoto libraryCheck that you have permission to write to the library directory" and i can't do anything else. I tried alt/cmd first aid and it didn't work.
    I want to get in and move pics over to a USB stick drive but cannot get past the Unable to write to library..message.

    Option 1
    Back Up and try rebuild the library: hold down the command and option (or alt) keys while launching iPhoto. Use the resulting dialogue to rebuild. Choose to Repair Database. If that doesn't help, then try again, this time using Rebuild Database.
    If that fails:
    Option 2
    Download iPhoto Library Manager and use its rebuild function. (In early versions of Library Manager it's the File -> Rebuild command. In later versions it's under the Library menu.)
    This will create an entirely new library. It will then copy (or try to) your photos and all the associated metadata and versions to this new Library, and arrange it as close as it can to what you had in the damaged Library. It does this based on information it finds in the iPhoto sharing mechanism - but that means that things not shared won't be there, so no slideshows, books or calendars, for instance - but it should get all your events, albums and keywords, faces and places back.
    Because this process creates an entirely new library and leaves your old one untouched, it is non-destructive, and if you're not happy with the results you can simply return to your old one.  
    Regards
    TD

  • "Check that you have permission to write to the library directory." I had this error pop up when trying to access a iPhoto Library from Finder.

    The error, "Check that you have permission to write to the library directory." Displayed after trying to access a iPhoto Library from finder. The file is located on the local hard drive and was accessed not 5 minutes before the error displayed. Upon searching the forums I found a similar problem and the instructions said to check a permission box in the "Get Info" tab. There was no box visible and after clicking the arrow to open the "Open With" tab, the rainbow wheel started to spin and I could no longer access Finder or the desktop. I was deleting files trying to make space on my hard drive and noticed as I was deleting files more data was being added to the iPhoto Library. My question is how can I fix this and how can I prevent this in the future, thank you very much for any help, I would really like to keep these pictures.

    I found a similar problem and the instructions said to check a permission box in the "Get Info" tab.
    This applies only when the Library is on an external drive. You cannot ignore permissions on the system drive.
    I was deleting files trying to make space on my hard drive
    What were you deleting?
    and noticed as I was deleting files more data was being added to the iPhoto Library.
    Hard to see how deleting files can add data to the iPhoto Library. Can you explain why you thought this?
    I would really like to keep these pictures.
    Make a back up now.
    Most Simple Back Up:
    Drag the iPhoto Library from your Pictures Folder to another Disk. This will make a copy on that disk.
    Slightly more complex: Use an app that will do incremental back ups. This is a very good way to work. The first time you run the back up the app will make a complete copy of the Library. Thereafter it will update the back up with the changes you have made. That makes subsequent back ups much faster. Many of these apps also have scheduling capabilities: So set it up and it will do the back up automatically.
    Example of such apps: Chronosync - but there are many others. Search on MacUpdate or the App Store

Maybe you are looking for

  • I can log on Apple ID, however, impossible to activate iMessage and Facetime

    I definitely log on my Apple ID, make sure there is no problem about the username nor password and network connection; however; it's constantly a failure of activation for iMessage and Facetime with notification " Could not sign in. Please check your

  • A web service that returns a xml file and gets another xml file as input?

    Hi, I want to create a web service which gets an xml document as input then returns again an xml document.How can I create this kind of web service? Is this kind of implementation is possible? public Document mywebservice(Document input){ Document d;

  • A query on a small benchmark test.

    I ran a small code snippet from a book I am reading and was surprised by the results. The code calls an empty method and also a method with a variables assignment as the body. I figured the empty method call should have been quicker but it is consist

  • I'm trying to make a Bug Database

    Hi there, I am trying to make my own bug database app using Objective-C(I will try and work out the Core Data part later - sticking to the code now). So here goes. I have created the code to add a column; NSTableColumn *newColumn = [[NSTableColumn al

  • 32 Bit Version CS5 Default

    I have both the 32 bit and 64 bit version of CS5 installed on a Windows 7 machine.  When I open Photoshop files or send files to Photoshop, they open in the 64 bit version.  However, my plugins are 32 bit and I want the 32 bit version of Photoshop to