Setup 'dcmqrdb' for server-client systems on ubuntu

All other questions regarding DCMTK

Moderator: Moderator Team

Post Reply
Message
Author
sumedh_dcm_user
Posts: 5
Joined: Fri, 2018-02-23, 07:55
Location: Bengaluru, India
Contact:

Setup 'dcmqrdb' for server-client systems on ubuntu

#1 Post by sumedh_dcm_user »

Hello there,
I am new to dcmtk. I was following the dcmqrset.txt (http://support.dcmtk.org/docs/file_dcmqrset.html) file in the dcmqrdb module of the main dcmtk documentation. I was stuck at step 10, which starts like
You can try sending a DICOM image to dcmqrscp from one of the remote machines which may access dcmqrscp's storage areas.
e.g.
storescu -v --aetitle ACME1 --call ACME_STORE dbhost 5678 ctimage.dcm
So I stepped down the difficulty a little bit and instead tried the same but from my local system i.e., using localhost. The procedure is elaborated in the 'dcmtk wiki Howto' page titled 'PACS Debugging with DCMTK' http://support.dcmtk.org/redmine/projec ... gWithDCMTK. In a nutshell, the essentials were:
Server side command:

Code: Select all

path/to/dcmqrscp -v --config path/to/dcmqrscp.cfg
Client side command:

Code: Select all

path/to/echoscu -aec "DCM_STORE" -aet "DCM_server" localhost 11115
My dcmqrscp.cfg file:

Code: Select all

#-----------------------------------------------------------------------
#
# Example configuration file for the dcmqrscp and dcmqrti applications.
#
#-----------------------------------------------------------------------

#
# Global Configuration Parameters
#
NetworkTCPPort  = 11115
MaxPDUSize      = 16384
MaxAssociations = 16

HostTable BEGIN
#
dcm_server			= 		(DCM_server, localhost, 5678)
#
HostTable END

VendorTable BEGIN
VendorTable END

AETable BEGIN
#
DCM_STORE   /home/sumedh/Downloads/dcmtk-3.6.3-install/usr/local/db/DCM_STORE   RW (9, 1024mb)   dcm_server
#
AETable END
Since I ran the commands with verbose option, I was able to see that the network connection worked.

Coming back to the step 10 of dcmrset.txt file, I made following changes to the above server-client setup but with different systems on the same wifi network. FYI, I tested dicom connectivity successfully following the 'testing.txt' file (http://support.dcmtk.org/docs/file_testing.html) in the dcmnet module, so I am pretty confident that the two systems on the same wifi network are indeed connected. The changes:
- dcmqrscp.cfg file: dcm_server = (DCM_server, localhost, 5678) -> dcm_server = (DCM_server, sumedh, 5678)
I presumed that hostname is the terminal output of command line tool 'whoami', which for my server system is sumedh.
- client side command:

Code: Select all

path/to/echoscu -aec "DCM_STORE" -aet "DCM_server" sumedh 11115
I get a fatal error F: 0006:0320 Attempt to connect to unknown host: sumedh, which kind of makes sense because how is the client system supposed to know server system's hostname i.e., sumedh. I feel like somehow I need to pass the IP information of server from the client-side to make the echoscu work. Does it have to do with generating UID root? I read DCMTK FAQ #25 and FAQ #41, but couldn't relate further.

Thanks in advance :) .

J. Riesmeier
DCMTK Developer
Posts: 2501
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: Setup 'dcmqrdb' for server-client systems on ubuntu

#2 Post by J. Riesmeier »

Your assumption is incorrect: "whoami" returns the user and not the host name (actually, "prints the effective userid" as the man page says.) The command "hostname" should do what you want.

sumedh_dcm_user
Posts: 5
Joined: Fri, 2018-02-23, 07:55
Location: Bengaluru, India
Contact:

Re: Setup 'dcmqrdb' for server-client systems on ubuntu

#3 Post by sumedh_dcm_user »

Hi J. Riesmeier,
Well, that doesn't change the output. My hostname is 'sumedhsys' (print reply of command line tool 'hostname', which actually maps to the loopback address 127.0.1.1), still the client-side fatal error is F: 0006:0320 Attempt to connect to unknown host: sumedhsys. Commands were

Code: Select all

server side> path/to/dcmqrscp -v -c path/to/dcmqrscp.cfg
client side> path/to/echoscu -aec "DCM_STORE" -aet "DCM_server" sumedhsys 11115 
, whereas my dcmqrscp.cfg file is

Code: Select all

#-----------------------------------------------------------------------
#
# Example configuration file for the dcmqrscp and dcmqrti applications.
#
#-----------------------------------------------------------------------

#
# Global Configuration Parameters
#
NetworkTCPPort  = 11115
MaxPDUSize      = 16384
MaxAssociations = 16

HostTable BEGIN
#
dcm_server			= 		(DCM_server, sumedhsys, 5678)
#
HostTable END

VendorTable BEGIN
VendorTable END

AETable BEGIN
#
DCM_STORE   /home/sumedh/Downloads/dcmtk-3.6.3-install/usr/local/db/DCM_STORE   RW (9, 1024mb)   dcm_server
#
AETable END
Drawing analogies from other server-client models namely ssh or even the dcmtk storescp-echoscu model i.e., something like

Code: Select all

server side> storescp -v 5678
client side> echoscu -v 192.168.2.11 5678
, I somehow feel that client system needs to know the IP address of the server.

J. Riesmeier
DCMTK Developer
Posts: 2501
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: Setup 'dcmqrdb' for server-client systems on ubuntu

#4 Post by J. Riesmeier »

Of course, if the hostname "sumedhsys" does not work (because of some misconfiguration?) you could also use the IP address of the system where the SCP listens for incoming network connections. However, you should probably also start with using "ANY" instead of "dcm_server" in the "AETable" section of your dcmqrscp.cfg file in order to avoid problems with access rights.

sumedh_dcm_user
Posts: 5
Joined: Fri, 2018-02-23, 07:55
Location: Bengaluru, India
Contact:

Re: Setup 'dcmqrdb' for server-client systems on ubuntu

#5 Post by sumedh_dcm_user »

Thanks J. Riesmeier.
Your suggestion of using 'ANY' instead of 'dcm_server' in the "AETable" section of my dcmqrscp.cfg file solved the problem. But don't 'RW' options warrant read/write rights of the storage area 'DCM_STORE' to the 'dcm_server'?
Commands:

Code: Select all

server side> path/to/dcmqrscp -v -c dcmqrscp.cfg
client side> path/to/storescu -v --aetitle DCM_server --call DCM_STORE 192.168.2.8 5757 path/to/dcm_file
whereas the dcmqrscp.cfg file:

Code: Select all

#
# Global Configuration Parameters
#
NetworkTCPPort  = 5757
MaxPDUSize      = 16384
MaxAssociations = 16

HostTable BEGIN
#
dcm_server = (DCM_server, gaurav-Inspiron-5520, 5678)
#
HostTable END

VendorTable BEGIN
VendorTable END

AETable BEGIN
#
DCM_STORE   /home/gaurav/Downloads/dcmtk-3.6.3-install/usr/local/db/DCM_STORE   RW (9, 1024mb)   ANY
#
AETable END
But you can still see I had to use the internal IP address of the server in place of hostname i.e., gaurav-Inspiron-5520.

J. Riesmeier
DCMTK Developer
Posts: 2501
Joined: Tue, 2011-05-03, 14:38
Location: Oldenburg, Germany
Contact:

Re: Setup 'dcmqrdb' for server-client systems on ubuntu

#6 Post by J. Riesmeier »

But don't 'RW' options warrant read/write rights of the storage area 'DCM_STORE' to the 'dcm_server'?
It allows a system with the hostname "gaurav-Inspiron-5520" and the (calling) AE title "DCM_server" to access the storage area "DCM_STORE" (selected by the called AE title).

Post Reply

Who is online

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