Using an AIX archive file as a library for an external procedure.

I cannot use an archive file, created with the ar command, that contains a shared object that was created with the xlc and ld commands as a library for external procedures. I can use the shared object file created with the ld command as a library for an external procedure. Why would I encounter an invalid magic number and what is the resolution?
Example:
oracle:@husk21:/home/oracle> ksh -x ./Oracle_demo.ksh
+ rm shell.o shell.so shell.so.exp shell.so.imp
+ make -f /u01/oracle/product/11.1.0.7/db/rdbms/demo/demo_rdbms32.mk extproc_no_context SHARED_LIBNAME=shell.so OBJS=shell.o
/u01/oracle/product/11.1.0.7/db/bin/oraxlc -q32 -c -I/u01/oracle/product/11.1.0.7/db/rdbms/demo -I/u01/oracle/product/11.1.0.7/db/rdbms/public -I/u01/oracle/product/11.1.0.7/db/plsql/public -I/u01/oracle/product/11.1.0.7/db/network/public -I/u01/oracle/product/11.1.0.7/db/precomp/public shell.c
generate_export_list() { /bin/nm -X32_64 -B -h -g "$1" | grep -v ' U ' | awk '{print $3}' | egrep -v '^\.|^TOC' | sort | uniq ; }; generate_import_list() { LIB_NAME=$1; IMP_FILE=$2; cat /u01/oracle/product/11.1.0.7/db/rdbms/lib/xa.imp | head -1 | awk '{print $0, "." }' > ${IMP_FILE}; /bin/nm -X32_64 -C -B -h -g ${LIB_NAME} | grep ' U ' | grep -v "::" | grep -v "(" | grep -v "\.cc" | awk '{print $3}' | sed -e "s/\.//g" | grep -v "^_" >> ${IMP_FILE}; }; generate_import_list shell.o shell.so.imp; generate_export_list shell.o > shell.so.exp; /bin/ld -b32 -bnoentry -bM:SRE -bE:shell.so.exp -bI:shell.so.imp -o shell.so shell.o -L/u01/oracle/product/11.1.0.7/db/lib -lc_r -lm
ld: 0711-224 WARNING: Duplicate symbol: .system
ld: 0711-224 WARNING: Duplicate symbol: system
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
oracle:@husk21:/home/oracle> ar rv libshell.a shell.so
ar: Creating an archive file libshell.a.
a - shell.so
oracle:@husk21:/home/oracle> ar tv libshell.a
rwxr-xr-x 3514/3516 1263 Sep 08 10:00 2009 shell.so
oracle:@husk21:/home/oracle> file shell.so
shell.so: executable (RISC System/6000) or object module not stripped
oracle:@husk21:/home/oracle> file libshell.a
libshell.a: archive (big format)
SQL> CREATE OR REPLACE LIBRARY shell_lib is '/home/oracle/libshell.a';
/ 2
Library created.
SQL> CREATE OR REPLACE PROCEDURE shell(command IN char)
AS EXTERNAL
NAME "shell"
LIBRARY shell_lib
LANGUAGE C
PARAMETERS (command string);
/ 2 3 4 5 6 7
Procedure created.
SQL> exec shell('ls');
BEGIN shell('ls'); END;
ERROR at line 1:
ORA-06520: PL/SQL: Error loading external library
ORA-06522: 0509-022 Cannot load module /home/oracle/libshell.a.
0509-103 The module has an invalid magic number.
ORA-06512: at "V500.SHELL", line 1
ORA-06512: at line 1
SQL> CREATE OR REPLACE LIBRARY shell_lib is '/home/oracle/shell.so';
2 /
Library created.
SQL> exec shell('ls');
PL/SQL procedure successfully completed

Using an AIX archive file as a library for an external procedure.

Similar Messages

  • How do i make a seperate itunes library for an external hard drive?

    my brother bought an external hard drive to have his own itunes library. We attemted to download the program into the ex. hard drive. but what it did was transfer all my music to the ex. hard drive. So we undid it, and now its back on my computer. So what can i do to have a seperate library for the external hard drive?
      Windows XP  

    Choose Go to Folder from the Finder's Go menu, provide ~/Music/ as the path, drag the entire iTunes library to the external drive, and if desired, then to the iMac's internal one. If you put it in a different location than the default, launch iTunes with the Option key held down and point it there.
    If the library contains rented movies, those won't play on a different computer.
    (110641)

  • Can I use REST to copy files from on library in a HNSC to another library in a different HNSC (or even different Tenants)

    Hi
    I am building a SharePoint hosted app which uses a REST Call to get file details of a file held in a host web library. Ok if want to copy that file to another a library held in another HNSC. Surely this is possible subject to the app manifest permission
    set to   tenant .  
    https://msdn.microsoft.com/office/office365/api/files-rest-operations#Folder6
    Daniel, WSL

    Reken
    Yes it is difficult. I coded up 3 requests in a SharePoint hosted app
    1) get file properties
     2) readfile  ( binarycontent)
     3) write file (binarycontent) to library in another HNSC
    1- 2 works fine but I am struggling with the 3) 
    To stop me from despairing ;-(  I thought I would modify my app to simply do a local copy ...
    However, this  not as simple as it looks.....
    (BTW this may be better discussed in a new post....)
    listurldir = "/appsdev/Marketing Lib;
    itemurl = "/Marketing Lib/betterlivingwithoutprogramming.pdf";
    filename = "betterlivingwithoutprogramming.pdf";
    // Get file to Copy This works with a GET and no Header
    var urlGetLocalFile = appweburl +
    "/_api/SP.AppContextSite(@target)/web/folders/GetByUrl('" + listurldir + "')/Files/getbyurl('" + filename + "')?@target='" + hostweburl + "'";
    executor.executeAsync(
    url: urlGetLocalFile,
    method: "GET",
    success: Function.createDelegate(this, function (data, errorCode, errorMessage) {
    // binary data available in data.body
    deferred.resolve(data, errorCode, errorMessage);
    error: Function.createDelegate(this, function (data, errorCode, errorMessage) {
    deferred.reject(data, errorCode, errorMessage);
    This works and finds my file ...... ok so far so good lets do a local copy with
    CopyTo
    localtargetfilepath = "/appsdev/Shared Documents/BeterLivingwithoutanyProgrammingever.pdf"var urlWriteLocalFile = appweburl +
        "/_api/SP.AppContextSite(@target)/web/folders/GetByUrl('" + listurldir + "')/Files/getbyurl('" + filename + "')/copyTo(strNewUrl='" + localtargetfilepath + "', bOverWrite=true)?@target='" + hostweburl + "'";
     executor.executeAsync(
                url: urlWriteLocalFile,
                method: "POST",
                success: Function.createDelegate(this, function (data, errorCode, errorMessage) {
                    // binary data available in data.body
                    deferred.resolve(data, errorCode, errorMessage);
                error: Function.createDelegate(this, function (data, errorCode, errorMessage) {
                    deferred.reject(data, errorCode, errorMessage);
    Unfortunately, I can't get passed this error  
    I have changed the HtpRuntime paramenters as in maxrequestlength and maxurlLength/. 
    Tried various header combinations with one or more of the following headers
    method: "POST",
    headers: {
    "Accept": "application/json; odata=verbose",
    "X-RequestDigest": $("#__REQUESTDIGEST").val()
    binaryStringResponseBody: true,
    However, I simply can't get passed the error
    Any ideas anyone?
    Daniel, WSL
    Freelance consultant

  • Archive file cannot be opened for write program

    Hi All,
    I am getting the error message "annot be opened for write program" in log view, when I am trying to write data into archive file using "write' function.
    Please provide us the solution for this problem.

    Hello,
    It must be due to missing authorization for the write operation.
    Please inform the security consultant along with SU53 details.
    Regards
    Vijay Gajavalli

  • Use SSIS to read files in SharePoint library

    Hi,
    I'm trying to use SSIS to read data from an Excel file in a SharePoint document library and I am having some problems with it.
    First I tried to use the Excel file as a source file in an Excel Source task which worked well in BIDS but not on the SQL server. ("CANNOTACQUIRECONNECTIONFROMCONNECTIONMANAGER")
    Next I tried to read data from an Excel file on the SQL server file system which worked well on the SQL server.
    Next I tried to use a File System Task to copy the Excel file to the SQL server file system. This also worked well in BIDS but not on the SQL server. ("The file name \\sharepoint\mylibrary\myfile.xls specified in the connection was not valid.")
    I have also tried to let the SQL server agent run on a domain account that is set up as a reader on the SharePoint document library without success.
    Where am I going wrong?

    I was playing around with the same issue. In my case SSIS and SharePoint run on the same server.
    In the IIS Log I noted that requests to the SharePoint library are made without credentials. This returns HTTP 404.
    I enabled anonymous access to the SharePoint Site and this Library without any change.
    IIS Log:
    date
    time
    s-ip
    cs-method
    cs-uri-stem
    cs-uri-query
    s-port
    cs-username
    c-ip
    cs(User-Agent)
    sc-status
    sc-substatus
    sc-win32-status
    time-taken
    07.01.2010
    11:19:31
    (removed)
    PROPFIND
    /SiteName/Test_Library
    80
    (removed)
    Microsoft-WebDAV-MiniRedir/6.0.6002
    401
    5
    0
    11
    Using the solution by Jason solved this: http://social.msdn.microsoft.com/Forums/en/sqlintegrationservices/thread/aea4a334-bc13-4fd2-aa59-6d31dfcc45e2
    In my SSIS Control Flow I run a Execute Process Task calling Net.exe with Params "Use \\share\folder password /User:domain\user /PERSISTENT:Yes" command before the file task. On the file connection I set DelayValidation to true.

  • Using a Vector Art File as a matte for an image collage

    II have a vector art file of a paw print.  I would like to use it with a variety of photos to create a collage.  I have the image files selected and the vector art file sized, but what I can't figure out is how to have the images seen ONLY inside each toe/pad of the paw print.  Once the file is completed, I would like to be able to flow text around the paw prints so I don't want the entire art board area to be white as this would effect my text wrap properties. Any and all suggestions are welcome!
    Ubiquitous Information:
    Adobe CS6 Design & Web premium
    Illustrator v. 16.0.3 (32-bit)
    Windows 7 Professional sp 1 64-bit OS
    Thanks in advance for your help this morning!
    Susan

    I developed a Photo Collage Toolkit for Photoshop.  I feel its very easy to create PSD templates that can be populated with images.
    Photo Collage Toolkit
    Photoshop scripting is powerful and I believe this package demonstrates this video showing a 5 image collage PSD template being populates with images:
    The package includes four simple rules to follow when making Photo Collage Template PSD files so they will be compatible with my Photoshop scripts.
    Size the photo collage templates for the print size you want - width, height and print DPI resolution.
    Photo collage templates must have a Photoshop background layer. The contents of this layer can be anything.
    Photo collage templates must have alpha channels named "Image 1", "Image 2", ... "Image n".
    Photo collage templates layers above the background layers must provide transparent areas to let the images that will be placed below them show through.
    There are twelve scripts in this package they provide the following functions:
    TestCollageTemplate.jsx - Used to test a Photo Collage Template while you are making it with Photoshop.
    CollageTemplateBuilder.jsx - Can build Templates compatible with this toolkit's scripts.
    LayerToAlphaChan.jsx - Used to convert a Prototype Image Layer stack into a template document.
    InteractivePopulateCollage.jsx - Used to interactively populate Any Photo Collage template. Offers most user control inserting pictures and text.
    ReplaceCollageImage.jsx - use to replace a populated collage image Smart Object layer with an other image correctly resized and positioned.
    ChangeTextSize.jsx - This script can be used to change Image stamps text size when the size used by the populating did not work well.
    PopulateCollageTemplate.jsx - Used to Automatically populate a Photo Collage template and leave the populated copy open in Photoshop.
    BatchOneImageCollage.jsx - Used to Automatically Batch Populate Collage templates that only have one image inserted. The Collage or Image may be stamped with text.
    BatchMultiImageCollage.jsx - Used to Automatically Batch Populate Any Photo Collage template with images in a source image folder. Easier to use than the interactive script. Saved collages can be tweaked.
    BatchPicturePackage.jsx - Used to Automatically Batch Populate Any Photo Collage template with an image in a source image folder
    PasteImageRoll.jsx - Paste Images into a document to be print on roll paper.
    PCTpreferences.jsx - Edit This File to Customize Collage Populating scripts default setting and add your own Layer styles.
    Documentation and Examples

  • I have an iPad1 and just purchased an iPad Air, both on the same iTunes account. Is it possible to UNSYNC the two iPads. I would like to use the iPad1 as a library for my frequent guests: KINDLE, AUDIBLE,

    I have an iPad1 and just purchased an iPad Air, both of which are on the same iTunes account. Is it possible to UNSYNC the two iPads with the purpose of using the iPad1 as a "Bare-Bones" library for my frequent guests: The content of my KINDLE, AUDIBLE, & ZINIO Accounts/Apps. How would I go about doing this, if it is at all possible?

    Is it possible to have an Iphone and an IPAD on the same Itunes account on a PC?
    yes.
    the number of mobile devices you can use with a single instance of iTunes is virtually unlimited.
    How to use multiple iPods with one computer

  • How do I import my library from an external disk to my new MBP hard drive?

    My old MBP was running out of space so I exported my Aperture library (250GB) to an external drive.  I just replaced my old computer with a new MBP with a 1TB flash drive.  Now that I have the space, I want to put my library back on my computer but I can't figure out how bring it in from my external hard drive.  Any ideas?  Many thanks.

    Why do you say " I exported my Aperture library"? Did you actually use "File > Export > Items as new Library" in Aperture to create a new library on your external drive? A simple drag and drop of the library should have sufficed. What is your Aperture version?
    My old MBP was running out of space so I exported my Aperture library (250GB) to an external drive.  I just replaced my old computer with a new MBP with a 1TB flash drive.  Now that I have the space, I want to put my library back on my computer but I can't figure out how bring it in from my external hard drive.  Any ideas?  Many thanks.
    Connect your external drive and use the Finder to drag the Aperture library from the external drive back to the Pictures folder.
    Then double-click the library to point Aperture to the new location and open the copied library in Aperture.
    If your Aperture library uses referenced originals, select the referenced images and use the command File > Consolidate originals"  to move the originals back to your internal disk.
    If you should encounter any error messages (like error -36) while moving the library to the internal drive, post back.

  • Building itunes library on an external hard drive

    How do I build a itunes library of my CDs directly onto an external hard drive that I can then load as an itunes library on another computer. this way I can use my home desktop to build the library, carry the external hard drive to work and see that library from my work computer.
    I have itunes version 8

    You might find this article useful: iLounge - Managing your iTunes Library on an External Hard Drive

  • PI 7.30: OS command on AIX to archive files on FTP does not work

    Dear experts,
    Our PI system runs on an AIX server.
    I have a scenario PI --> FTP. I also need to archive files in a seperate folder on the FTP.
    I have been following thread:
    Read or Write File On FTP server based on another file existence.
    After file processing in the Audit Log in RWB I among others I get the information:
    Execute OS command "sh /usr/sap/SYS/flex/batches/archive.sh file.zip /ftpfolder/file.zip"
    It seems it is working properly.
    The file itself gets processed to the "ftpfolder". But in the archive folder I do not get a copy of that file.
    My script looks like this:
    #!/bin/ksh
    ftp -n -v <<%%EOF%%
    open ftpserver
    user myuser mypassword
    prompt
    asci
    cd archivefolder
    mput $2
    bye
    %%EOF%%
    In the file receiver I have "Run OS command after message processing":
    "sh /usr/sap/SYS/flex/batches/archive.sh %f %F"
    %F stands for the complete path, right? So if I say "mput $2" in my script it should use %F.
    Could you please help me out here. I really don't know what the problem could be.
    Thank you and best regards,
    Peter

    hi Peter,
    >>>I have a scenario PI --> FTP
    but FTP does not support OS command as far as I remember
    correction:
    "Note that for the File Adapter transport protocol "FTP", the operating system command is NOT executed on the FTP server, but on the server hosting the Adapter Engine."
    please check for details:
    Note 841704 - XI File & JDBC Adapter: Operating system command
    Regards,
    Michal Krawczyk
    Edited by: Michal_Krawczyk_PIXI on Feb 3, 2012 3:38 PM

  • I have an itunes library on an external drive I want to use on a dool boot computer. How do I set this up without duplication of files

    Ok, here goes with the explanation. I am running a Mac Mini mid 2010 with mt iTunes library on an external USB drive. I dual boot the computer into Windows 7. I want to be able to use the same iTunes library in both Operating Systems. I am trying to set this up on the Windows side without accidentily erasing, moving or duplicating any files. In the past when I have tried I have ended up with multiple files. I have an iCloud also but do not want to download any files again. How can I get iTunes on Windows to simply recognise my existing storage and create a library list from what is already there rather than duplicating files?
    Update: As soon as I signed in with my iTunes account iCloud picked up my playlist and now lists all my music. Right clicking on the songs give me the choice to download the files, but the files already exist oin my external USB. I simply want iTunes on Windows 7 to point to the existing files.

    How is the external drive formatted?
    Allan

  • Hi. I opened iPhoto and, suddenly, it tells me " WHAT IPHOTO LIBRARY DO I WANT TO USE?" but i had a iPhoto library. When i search on my Pictures, i have the file IPHOTO LIBRARY but it appears on a dim letters and i can not open it.

    Hi. I need some help on the following problem. I opened iPhoto and, suddenly, it tells me " WHAT IPHOTO LIBRARY DO I WANT TO USE?" but i had a iPhoto library. When i search on my Pictures, i have the file IPHOTO LIBRARY but is was not the icon on it i previously remembered and it appears on a dim letters and it can not be opened ... How can i recover it??

    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 Rebuild iPhoto Library Database from automatic backup.
    If that fails:
    Option 2
    Download iPhoto Library Manager and use its rebuild function. This will create a new library based on data in the albumdata.xml file. Not everything will be brought over - no slideshows, books or calendars, for instance - but it should get all your albums and keywords 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

  • Moved iTunes library to an ext hard drive to make space on my int drive... Followed steps from apple.  Now I cannot access my music... It says: "File could not be used because the original file cannot be found.  Would you like to locate it?"

    Moved iTunes library to an ext hard drive to make space on my int drive... Followed steps from apple.  Now I cannot access my music... It says: "File could not be used because the original file cannot be found.  Would you like to locate it?"
    I moved my iTunes library to my external hard drive some time ago and I followed the directions listed here on the apple support page.  It did copy my library and now is on my hard drive... I can open iTunes and use it to sync all of my devices but I would like to play my music... I can see all of my music files but can not play them if I click on an album or song it says the following:  "(file name) could not be used because the original file cannot be found.  Would you like to locate it?"  I click locate but do not know where to go from there?  I need a way to access all files and not to hunt down one at a time on my hard drive... I am pretty sure I deleted the original library to make space on my internal drive which was the reason for moving it.  I have tried and tried to fix it and do not have a lot of time to do so with a one and two year old at my house who do not like it whenI sit down at my computer.  What to do???  Any help is much appreciated!!!

    See Make a split library portable. Move all of the bits of the library together in the the correct shape and it should work. Or undo exactly what you did and then start over.
    If you're a former Windows user don't try merging two folders together that have the same name by dropping one into the same folders as the other, as that goes badly on a Mac.
    tt2

  • Library Lost - Please HeIp I tried updating my old ipod & now all 10,000 songs in my library have an ! next to them and I get the error message "song " " could not be used because the original file could not be found" on every song I try to play

    Please help - this morning I tried updating one of my old ipods for my wife (this ipod hasn't been updated in 2-3 years).  I plugged it into my pc, it was recognized and the software updated.  I created a new playlist and tied to sync the ipod.  This ipod had never been used on this pc/itunes since the pc is only 2 years old.  When I tried to sync the ipod it stated that it would have to erase all the old songs on the ipod prior to syncing.  I clicked ok and it proceeded to wipe out the old ipod and sync the new playlist (~1000 songs).  When the sync was complete there were only 6 songs from the new playlist (all purchased this morning from itunes) on the ipod and to my horror all ~10,000 song on my pc in itunes now have a ! next to them.  Only my recent purchases from itunes do not.  When I click on a song with the ! I get the error message "the song " " could not be used because the original file could not be found."  How do I correct this issue - I am scared to hook my ipads or other ipods to my pc for fear of losing everything?!?!?  I spent 100s of hours burning the 10,000 songs from my cd collection and do not want to have to do it again. 
    Any help is greatly appreciated.

    This "original file cannot be found" thing happens if the file is no longer where iTunes expects to find it. Possible causes are that you or some third party tool has moved, renamed or deleted the file, or that the drive it lives on has had a change of drive letter. It is also possible that iTunes has changed from expecting the files to be in the pre-iTunes 9 layout to post-iTunes 9 layout,or vice-versa, and so is looking in slightly the wrong place.
    Select a track with an exclamation mark, use Ctrl-I to get info, then cancel when asked to try to locate the track. Look on the summary tab for the location that iTunes thinks the file should be. Now take a look around your hard drive(s). Hopefully you can locate the track in question. If a section of your library has simply been moved, or a drive letter has changed, it should be possible to reverse the actions.
    Alternatively, as long as you can find a location holding the missing files, then you should be able to use my FindTracks script to reconnect them to iTunes .
    tt2

  • I recently reset my computer and copy my music from an external hard drive to my itunes library.  When I click on a song to play i get an error message that says " the song could not be used because the original file could not be found".  need help

    I recently reset my computer and copy my music from an external hard drive to my itunes library.  When I click on a song to play i get an error message that says " the song could not be used because the original file could not be found".  But when I have my external hard drive plug in the song will play with no problem.  What do I need to do to play my music without having the external harddrive plug in ????????  Please help

    Because the location for each song in your library is on your hard drive.  If the hard drive isn't there, how can iTunes play it?
    You'll have to move/copy the music from your hard drive to your computer's hard drive.
    Basically, EASIEST way to do all this, if you don't care about your play counts, etc...
    -Delete EVERYTHING from iTunes, so that your library is now empty.
    -Go to "Advanced" inside of the "Preferences" window, found in the "Edit" drop-down.  You can also access Preferences by pressing Ctrl+, (Press Ctrl and the comma key)
    -Change your iTunes Media Folder Location to something simple, but on your computer. I use C:/iTunes.  Make sure "Keep iTunes Media Folder Organized" and "Copy files to...." are both checked.  You can close Preferences now.
    -Now, drag and drop your music from your hard drive into your iTunes library.  iTunes will automatically add the music to your library, as you would expect, and also creates a copy of each file to place into that iTunes Media Folder you just created.
    Shouldn't have any more problems...

Maybe you are looking for

  • Formula assistance in crystal reports

    Hello, I have a report that has 2 groups, first is by category and second is by code and the report displays Quantity which is sum in group footer 1 and 2 I want to create a column ' %', how do I pull in the sum of quantity in group footer 1 in the f

  • My lightening charger is not fitting snug into the charging port

    Hello. I am having trouble with the lightening charger for my iPhone 5. When I plug it in, the phone makes the sound that it always does, indicating that it is charging. Then, it starts making the noise over and over. The lightening charger is not fi

  • OWB 11.2.0.3 do not re-generate DDL on objects deploy

    Hi all, I've added a 2nd target location/schema (after a successful deploy on 1st target location) to our OWB project and we got an error on executing the DDL script for the dimension objects. I checked the script and found that it still contains the

  • DVD_RTAV Folder saying "you don't have permission to see its contents" HELP!

    Hi Community, I have bee going thrugh internet posts for an hour! Tried everything. On a DVD there is a folder called DVD_RTAV. On the bottom right of that folder us that little red circle with the white bar in it. I cannot open, nor can I change its

  • Rollback the single employee Payroll in 12.1.3

    Dear Guru's, We Ran the payroll for terminated employee. (Termination date is 1-May-2014.) We process the payroll on that month (31-May-2014) with including the terminated employee and posted all records in GL. We want to process all the settlement w