Re: [Dspace-tech] Item Import Error
Hello Ritika The error says that import utility tries to search the file at D:\tmp\testimport\1\contents location and not able to find the file there. Re-Check your directory structure and files. It should work. Hardik Mishra Software Developer Ahmedabad - Gujarat essage: 4 Date: Wed, 14 Mar 2012 16:01:22 +0530 From: ritika bhalla rit.bhall...@gmail.com Subject: [Dspace-tech] Batch Import for dspace 1.8.1 To: DSpace-tech@lists.sourceforge.net, Henry, Matt - OPS District Computer Technicianmatt.he...@owensboro.kyschools.us, revskill revskil...@gmail.com Message-ID: CA+tX-FaxHPLed1XJOr32BdydA9Ph-Rcr=z26scw6kmoq3k+...@mail.gmail.com Content-Type: text/plain; charset=iso-8859-1 Hi all, I am trying to upload some files using dspace batch import facility. This is my output: C:\dspace\bindsrun org.dspace.app.itemimport.ItemImport -a -e rit.bhall...@gmail.com -c 123456789/2 -s D:\tmp\testimport -m D:\tmp\testimport\1\mapfile.txt Using DSpace installation in: C:\dspace Destination collections: Owning Collection: Digital Library Collection Adding items from directory: D:\tmp\testimport Generating mapfile: D:\tmp\testimport\1\mapfile.txt Adding item from directory 1 Loading dublin core from D:\tmp\testimport\1\dublin_core.xml Schema: dc Element: contributor Qualifier: author Value: Public, JohnQ. Schema: dc Element: title Qualifier: none Value: Sample Dublin Core Schema: dc Element: subject Qualifier: none Value: Technology Processing contents file: D:\tmp\testimport\1\contents java.io.FileNotFoundException: *No contents file found* at org.dspace.app.itemimport.ItemImport.processContentsFile(ItemImport.j ava:1309) at org.dspace.app.itemimport.ItemImport.addItem(ItemImport.java:751) at org.dspace.app.itemimport.ItemImport.addItems(ItemImport.java:617) at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:498) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:183) java.io.FileNotFoundException: No contents file found Started: 1331709284726 Ended: 1331709285727 Elapsed time: 1 secs (1001 msecs) *I have maintained my directory structure as follows:* D:\ D:\tmp D:\tmp\testimport D:\tmp\testimport\1 D:\tmp\testimport\1\dspace.pdf D:\tmp\testimport\1\contents.txt D:\tmp\testimport\1\dublin_core.xml contents.txt contains only one entry: dspace.pdf bundle: ORIGINAL Can u tell me where I am going wrong?? *Thanks* *Ritika* -- Virtualization Cloud Management Using Capacity Planning Cloud computing makes use of virtualization - but cloud computing also focuses on allowing computing to be delivered as a service. http://www.accelacomm.com/jaw/sfnl/114/51521223/___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] Item Import error WAS Re: no subject
Oh, it worked beautifully! Thanks so much! -- Karen S From: Stuart Lewis s.le...@auckland.ac.nz Date: Thu, 16 Apr 2009 14:41:49 +1200 To: Karen Savage karen_sav...@baylor.edu, dspace-tech@lists.sourceforge.net Subject: RE: [Dspace-tech] Item Import error WAS Re: no subject Hi Karen, The normal issue that causes this is if you have been running the importer as a different user to the user that is running tomcat, or another user has been changing files (maybe running the filter-media cron job as root etc). Check that all of the directories under [dspace]/assetstore/ are owned by the correct user. DSpace randomly selects a set of directories to put a new file in, and if one of these happens to not be owned by the same user you are running the importer as, then it won't be able to write the file, and will stop. So check they are all owned by the correct user or that you have the correct permissions to write to them. Because Dspace randomly chooses the directories to write the file to, the importer will stop and different places randomly. Hope this helps, Stuart Lewis Digital Services Programmer Te Tumu Herenga The University of Auckland Library Auckland Mail Centre, Private Bag 92019, Auckland 1142, New Zealand Ph: 64 9 373-7599 x81928 http://www.library.auckland.ac.nz http://www.library.auckland.ac.nz/ / From: Karen_Savage [mailto:karen_sav...@baylor.edu] Sent: Thursday, 16 April 2009 7:00 a.m. To: dspace-tech@lists.sourceforge.net Subject: [Dspace-tech] Item Import error WAS Re: no subject Yes, thank you, this was what was generating the error. I was trying to use the item handle instead of the collection one. However, now that I've got past that, I'm getting this error: java.io.IOException: No such file or directory at java.io.UnixFileSystem.createFileExclusively(Native Method) at java.io.File.createNewFile(File.java:850) at edu.sdsc.grid.io.local.LocalFile.createNewFile(LocalFile.java:481) at org.dspace.storage.bitstore.BitstreamStorageManager.store(BitstreamStorageManager.java:325) at org.dspace.content.Bitstream.create(Bitstream.java:184) at org.dspace.content.Bundle.createBitstream(Bundle.java:355) at org.dspace.app.itemimport.ItemImport.processContentFileEntry(ItemImport.java:1045) at org.dspace.app.itemimport.ItemImport.processContentsFile(ItemImport.java:972) at org.dspace.app.itemimport.ItemImport.addItem(ItemImport.java:609) at org.dspace.app.itemimport.ItemImport.addItems(ItemImport.java:476) at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:385) java.io.IOException: No such file or directory I've tried uploading a smaller subset (the full batch has over 800 files), and it keeps stopping three or four bitstreams in (a different one each time). Any ideas? Thanks, -- Karen S From: Stuart Lewis s.le...@auckland.ac.nz Date: Tue, 7 Apr 2009 09:02:53 +1200 To: Karen Savage karen_sav...@baylor.edu, dspace-tech@lists.sourceforge.net Subject: RE: [Dspace-tech] no subject Hi Karen, Is 3029/2039 definitely a Collection? This error gets thrown if you try to deposit items into a handle that is an Item, rather than a Collection. Thanks, Stuart Lewis Digital Services Programmer Te Tumu Herenga The University of Auckland Library Auckland Mail Centre, Private Bag 92019, Auckland 1142, New Zealand Ph: 64 9 373-7599 x81928 http://www.library.auckland.ac.nz http://www.library.auckland.ac.nz/ / From: Karen_Savage [mailto:karen_sav...@baylor.edu] Sent: Tuesday, 7 April 2009 3:36 a.m. To: dspace-tech@lists.sourceforge.net Subject: [Dspace-tech] no subject Hi, I'm trying to do a batch import of files to a particular etd in our collection, but I keep getting the following error: Destination collections: Exception in thread main java.lang.ClassCastException: org.dspace.content.Item at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:341) This is the command I'm running (I've switched out the ids): /dspace/bin/dsrun org.dspace.app.itemimport.ItemImport -a -e 2039 -c 3029/2039 -s import -m /mapfiles/mapfile_ball -t This is my directory structure: import 001 contents dublin_core.xml various files to upload We're running Dspace 1.3.2. I double-checked all the log files and didn't see any errors for the time that I last ran the command. I'd appreciate any help or suggestions! -- Karen Savage Baylor University Central Libraries Electronic Libraries ext. 3275 -- Stay on top of everything new and different, both inside and around Java (TM) technology - register by April 22, and save $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco. 300 plus technical and hands-on sessions. Register today. Use priority code J9JMT32. http://p.sf.net/sfu/p ___ DSpace-tech mailing list DSpace
[Dspace-tech] Item Import error WAS Re: no subject
Yes, thank you, this was what was generating the error. I was trying to use the item handle instead of the collection one. However, now that I¹ve got past that, I¹m getting this error: java.io.IOException: No such file or directory at java.io.UnixFileSystem.createFileExclusively(Native Method) at java.io.File.createNewFile(File.java:850) at edu.sdsc.grid.io.local.LocalFile.createNewFile(LocalFile.java:481) at org.dspace.storage.bitstore.BitstreamStorageManager.store(BitstreamStorageMa nager.java:325) at org.dspace.content.Bitstream.create(Bitstream.java:184) at org.dspace.content.Bundle.createBitstream(Bundle.java:355) at org.dspace.app.itemimport.ItemImport.processContentFileEntry(ItemImport.java :1045) at org.dspace.app.itemimport.ItemImport.processContentsFile(ItemImport.java:972 ) at org.dspace.app.itemimport.ItemImport.addItem(ItemImport.java:609) at org.dspace.app.itemimport.ItemImport.addItems(ItemImport.java:476) at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:385) java.io.IOException: No such file or directory I¹ve tried uploading a smaller subset (the full batch has over 800 files), and it keeps stopping three or four bitstreams in (a different one each time). Any ideas? Thanks, -- Karen S From: Stuart Lewis s.le...@auckland.ac.nz Date: Tue, 7 Apr 2009 09:02:53 +1200 To: Karen Savage karen_sav...@baylor.edu, dspace-tech@lists.sourceforge.net Subject: RE: [Dspace-tech] no subject Hi Karen, Is 3029/2039 definitely a Collection? This error gets thrown if you try to deposit items into a handle that is an Item, rather than a Collection. Thanks, Stuart Lewis Digital Services Programmer Te Tumu Herenga The University of Auckland Library Auckland Mail Centre, Private Bag 92019, Auckland 1142, New Zealand Ph: 64 9 373-7599 x81928 http://www.library.auckland.ac.nz http://www.library.auckland.ac.nz/ / From: Karen_Savage [mailto:karen_sav...@baylor.edu] Sent: Tuesday, 7 April 2009 3:36 a.m. To: dspace-tech@lists.sourceforge.net Subject: [Dspace-tech] no subject Hi, I'm trying to do a batch import of files to a particular etd in our collection, but I keep getting the following error: Destination collections: Exception in thread main java.lang.ClassCastException: org.dspace.content.Item at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:341) This is the command I'm running (I¹ve switched out the ids): /dspace/bin/dsrun org.dspace.app.itemimport.ItemImport -a -e 2039 -c 3029/2039 -s import -m /mapfiles/mapfile_ball -t This is my directory structure: import 001 contents dublin_core.xml various files to upload We're running Dspace 1.3.2. I double-checked all the log files and didn¹t see any errors for the time that I last ran the command. I'd appreciate any help or suggestions! -- Karen Savage Baylor University Central Libraries Electronic Libraries ext. 3275 -- This SF.net email is sponsored by: High Quality Requirements in a Collaborative Environment. Download a free trial of Rational Requirements Composer Now! http://p.sf.net/sfu/www-ibm-com___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech
Re: [Dspace-tech] Item Import error WAS Re: no subject
Hi Karen, The normal issue that causes this is if you have been running the importer as a different user to the user that is running tomcat, or another user has been changing files (maybe running the filter-media cron job as root etc). Check that all of the directories under [dspace]/assetstore/ are owned by the correct user. DSpace randomly selects a set of directories to put a new file in, and if one of these happens to not be owned by the same user you are running the importer as, then it won't be able to write the file, and will stop. So check they are all owned by the correct user or that you have the correct permissions to write to them. Because Dspace randomly chooses the directories to write the file to, the importer will stop and different places randomly. Hope this helps, Stuart Lewis Digital Services Programmer Te Tumu Herenga The University of Auckland Library Auckland Mail Centre, Private Bag 92019, Auckland 1142, New Zealand Ph: 64 9 373-7599 x81928 http://www.library.auckland.ac.nz http://www.library.auckland.ac.nz/ / From: Karen_Savage [mailto:karen_sav...@baylor.edu] Sent: Thursday, 16 April 2009 7:00 a.m. To: dspace-tech@lists.sourceforge.net Subject: [Dspace-tech] Item Import error WAS Re: no subject Yes, thank you, this was what was generating the error. I was trying to use the item handle instead of the collection one. However, now that I've got past that, I'm getting this error: java.io.IOException: No such file or directory at java.io.UnixFileSystem.createFileExclusively(Native Method) at java.io.File.createNewFile(File.java:850) at edu.sdsc.grid.io.local.LocalFile.createNewFile(LocalFile.java:481) at org.dspace.storage.bitstore.BitstreamStorageManager.store(BitstreamStora geManager.java:325) at org.dspace.content.Bitstream.create(Bitstream.java:184) at org.dspace.content.Bundle.createBitstream(Bundle.java:355) at org.dspace.app.itemimport.ItemImport.processContentFileEntry(ItemImport. java:1045) at org.dspace.app.itemimport.ItemImport.processContentsFile(ItemImport.java :972) at org.dspace.app.itemimport.ItemImport.addItem(ItemImport.java:609) at org.dspace.app.itemimport.ItemImport.addItems(ItemImport.java:476) at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:385) java.io.IOException: No such file or directory I've tried uploading a smaller subset (the full batch has over 800 files), and it keeps stopping three or four bitstreams in (a different one each time). Any ideas? Thanks, -- Karen S From: Stuart Lewis s.le...@auckland.ac.nz Date: Tue, 7 Apr 2009 09:02:53 +1200 To: Karen Savage karen_sav...@baylor.edu, dspace-tech@lists.sourceforge.net Subject: RE: [Dspace-tech] no subject Hi Karen, Is 3029/2039 definitely a Collection? This error gets thrown if you try to deposit items into a handle that is an Item, rather than a Collection. Thanks, Stuart Lewis Digital Services Programmer Te Tumu Herenga The University of Auckland Library Auckland Mail Centre, Private Bag 92019, Auckland 1142, New Zealand Ph: 64 9 373-7599 x81928 http://www.library.auckland.ac.nz http://www.library.auckland.ac.nz/ / From: Karen_Savage [mailto:karen_sav...@baylor.edu] Sent: Tuesday, 7 April 2009 3:36 a.m. To: dspace-tech@lists.sourceforge.net Subject: [Dspace-tech] no subject Hi, I'm trying to do a batch import of files to a particular etd in our collection, but I keep getting the following error: Destination collections: Exception in thread main java.lang.ClassCastException: org.dspace.content.Item at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:341) This is the command I'm running (I've switched out the ids): /dspace/bin/dsrun org.dspace.app.itemimport.ItemImport -a -e 2039 -c 3029/2039 -s import -m /mapfiles/mapfile_ball -t This is my directory structure: import 001 contents dublin_core.xml various files to upload We're running Dspace 1.3.2. I double-checked all the log files and didn't see any errors for the time that I last ran the command. I'd appreciate any help or suggestions! -- Karen Savage Baylor University Central Libraries Electronic Libraries ext. 3275 -- Stay on top of everything new and different, both inside and around Java (TM) technology - register by April 22, and save $200 on the JavaOne (SM) conference, June 2-5, 2009, San Francisco. 300 plus technical and hands-on sessions. Register today. Use priority code J9JMT32. http://p.sf.net/sfu/p___ DSpace-tech mailing list DSpace-tech@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-tech