Hello,
Before messing with the ICD10 code to load the new code tables, I have an unmodified v4.1.1dev tree up and running and have the RxNorm_full_03052012.zip file that i wanted to install to see how the code works.
1.) I put the zip in the contrib/rxnorm directory
2.) set globals temp dir to “contrib” (no quotes)
3.) verified with a test php file in the document root that i can unzip the file correctly from the contrib/rxnorm location
4.) use the RxNorm interface to Install the file and I get the ERROR: Unable to extract the file.
Can’t seem to find any specific messages in the error.log file. Any ideas?
Brady,
The full globals temp directory path (located in Globals->miscellaneous->Path To Temporary Files) started out as /tmp and I’ve tried these other setting with nothing working correctly:
- contrib
- <document root>/contrib
I get to the Install page once i put the zip file in <docroot>contrib/rxnorm but get the unable to extract error.
I’ve taken a look at the code in library/standard_tables_capture.inc and I added an echo to display the directory the code is using -> /tmp/rxnorm. Not sure I am setting the correct variable. I have been restarting apache after changing the config but not sure if I need to be doing something else. After a couple of go-arounds my experiment was to take the code that opens and extracts the file and putting it into a test jig php file and that code works when i hard code the relative path name to the zip file for the open and subsequent extract.
Generally best to use /tmp for the temporary directory (since this is used in other places of OpenEMR and will have write privileges). Also should ensure ZipArchive module for php is installed. To problem solve:
1. Remove /tmp/rxnorm
2. uncomment temp_dir_cleanup($mode); at line 182 of interface/code_systems/standard_tables_manage.php
3. Then run the rxnorm import within OpenEMR
4. If get the error, then see what is currently at /tmp/rxnorm/
Just tried this on Ubuntu Server and it worked (used RxNorm_full_04022012.zip). Used /tmp as the temporary directory. How large was the rxnorm file you downloaded (it should be about 132MB; I am asking this because wget does not work and downloads a much smaller file since you need to authenticate before you can download the file).
Hello,
I got to the bottom of this extract failure. While I was off reviewing code for the past week (and playing around with the load code for rxnorm) bradymiller IMPLEMENTED the better half of the ICD10 stuff! Thanks.
The problem with this import failure was a bogus zip file. For anyone else ever seeing this error again, you don’t need to mess with the global settings but you do need to make sure you get the checksum on the file from the source site and validate the sum once you finish the download. Read up on the sum or md5 commands depending on source site’s checksum type …
Mac
p.s. i saw that SNOMED fix last night … I ended up taking your branch to work some additional ICD10 stuff that I will post on the developer’s forum.
Hello Brady,
I am new to OpenEMR. I am unable to load RxNorm and SNOMED from with Openemr, getting the follow message: “ERROR: Unable to extract the file.” I have tried to implement the above changes - but they dont even appear applicable to me. I used the linux installation, Openemr 4.1.1 with the latest patch (6).
Help will be greatly appreciated.
Paul
Hi Paul,
Away from my development environment for next couple days (guessing grep of above ERROR: Unable to extract the file string will pinpoint where in code the issue is happening), so if nobody helps you out, I look into it more in a couple days.
-brady OpenEMR