DICOM @ OFFIS

Discussion Forum for OFFIS DICOM Tools - For registration, send email with desired user name to the OFFIS DICOM team
It is currently Tue, 2017-11-21, 09:10

All times are UTC + 1 hour




Post new topic Reply to topic  [ 6 posts ] 
Author Message
PostPosted: Thu, 2017-10-19, 18:05 
Offline

Joined: Thu, 2017-10-19, 16:54
Posts: 3
Hello

We start StoreSCP DICOM service using the following script. The output directory is C:\Output. The studies get sorted into subdirectories using patient name within the output directory, e.g. C:\Output\TestPatient1.
"%SCPProgDir%\SCP.exe" +v --log-config "%SCPProgDir%\SCP.cfg" -aet %SCPAET% -od %SCPOutputDir% -fe .dcm %SCPPort% -sp""

If a patient directory, e.g. C:\Output\TestPatient1, is deleted and we try to resend the same (deleted) patient study from our PACS then it fails. The StoreSCP log displays the following entry:
2017-10-19 16:16:38.505 INFO: Received Store Request: MsgID 1, (CT)
2017-10-19 16:16:38.511 INFO: storing DICOM file: <filename>.dcm
2017-10-19 16:16:38.512 ERROR: cannot write DICOM file: <filename>.dcm: No such file or directory

If the patient directory is not deleted then "move to" works successfully. Even if the files within the patient directory are deleted the "move to" works.

The problem is when the patient directory is deleted from within the output directory, the study fails and above error appears in the log.

I've been unsuccessful to find a parameter, which re-creates the patient directory if it doesn't exist.
Could someone please help me with this. Which parameter do I use?

Thanks
Idil


Top
 Profile  
 
PostPosted: Sat, 2017-10-21, 19:42 
Offline
DCMTK Developer

Joined: Tue, 2011-05-03, 14:38
Posts: 1874
Location: Oldenburg, Germany
I checked the source code of "storescp": If the directory is deleted while storescp is running, it is not re-created (unless a different patient is sent in between).


Top
 Profile  
 
PostPosted: Tue, 2017-10-24, 13:18 
Offline

Joined: Thu, 2017-10-19, 16:54
Posts: 3
Thanks Riesmeir. You are right that's exactly what's happening.
Is there anyway to re-create the deleted directory without sending a different patient first?
Or are there any workarounds?

Thanks


Top
 Profile  
 
PostPosted: Tue, 2017-10-24, 17:22 
Offline
DCMTK Developer

Joined: Tue, 2011-05-03, 14:38
Posts: 1874
Location: Oldenburg, Germany
The only "workaround" I can see would be to modify the source code of storescp accordingly (check whether the corresponding directory already exists and recreate it if needed each time a new DICOM object is received).


Top
 Profile  
 
PostPosted: Wed, 2017-10-25, 10:10 
Offline

Joined: Thu, 2017-10-19, 16:54
Posts: 3
Thanks Riesmeier!


Top
 Profile  
 
PostPosted: Fri, 2017-10-27, 11:55 
Offline
DCMTK Developer

Joined: Fri, 2004-11-05, 13:47
Posts: 1633
Location: Oldenburg, Germany
Just something that instantly came to my mind: Some tool of yours is deleting the patient directories frequently, do I get this right? Could you modify this tool that it checks whether there is a patient with a newer modification date than the one that is to be deleted? If so, delete it, otherwise wait. Just an idea.

Best,
Michael


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: Bing [Bot] and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group