Index: palm/trunk/SOURCE/check_parameters.f90
===================================================================
--- palm/trunk/SOURCE/check_parameters.f90	(revision 679)
+++ palm/trunk/SOURCE/check_parameters.f90	(revision 680)
@@ -677,4 +677,12 @@
     ENDIF
 
+    IF ( TRIM( initializing_actions ) == 'initialize_vortex' .AND. &
+         conserve_volume_flow ) THEN
+         message_string = 'initializing_actions = "initialize_vortex"' // &
+                        ' ist not allowed with conserve_volume_flow = .T.'
+       CALL message( 'check_parameters', 'PA0343', 1, 2, 0, 6, 0 )
+    ENDIF       
+
+
     IF ( INDEX( initializing_actions, 'set_constant_profiles' ) /= 0  .AND. &
          INDEX( initializing_actions, 'set_1d-model_profiles' ) /= 0 )  THEN
Index: palm/trunk/SOURCE/init_3d_model.f90
===================================================================
--- palm/trunk/SOURCE/init_3d_model.f90	(revision 679)
+++ palm/trunk/SOURCE/init_3d_model.f90	(revision 680)
@@ -7,4 +7,7 @@
 ! Current revisions:
 ! -----------------
+!
+! gryschka
+! bugfix: volume_flow_control
 !
 ! Former revisions:
@@ -881,15 +884,4 @@
 
 !
-!--    Impose random perturbation on the horizontal velocity field and then
-!--    remove the divergences from the velocity field
-       IF ( create_disturbances )  THEN
-          CALL disturb_field( nzb_u_inner, tend, u )
-          CALL disturb_field( nzb_v_inner, tend, v )
-          n_sor = nsor_ini
-          CALL pres
-          n_sor = nsor
-       ENDIF
-
-!
 !--    Once again set the perturbation pressure explicitly to zero in order to
 !--    assure that it does not generate any divergences in the first time step.
@@ -1116,4 +1108,5 @@
        
     ENDIF
+
 !
 !-- Calculate the initial volume flow at the right and north boundary
@@ -1170,17 +1163,12 @@
 
 #if defined( __parallel )
-          CALL MPI_ALLREDUCE( volume_flow_initial_l(1), volume_flow_initial(1),&
-                              2, MPI_REAL, MPI_SUM, comm2d, ierr )
-          CALL MPI_ALLREDUCE( volume_flow_area_l(1), volume_flow_area(1),      &
-                              2, MPI_REAL, MPI_SUM, comm2d, ierr )
-
-          CALL MPI_ALLREDUCE( volume_flow_initial_l(2), volume_flow_initial(2),&
-                              2, MPI_REAL, MPI_SUM, comm2d, ierr )
-          CALL MPI_ALLREDUCE( volume_flow_area_l(2), volume_flow_area(2),      &
-                              2, MPI_REAL, MPI_SUM, comm2d, ierr )
+       CALL MPI_ALLREDUCE( volume_flow_initial_l(1), volume_flow_initial(1),&
+                           2, MPI_REAL, MPI_SUM, comm2d, ierr )
+       CALL MPI_ALLREDUCE( volume_flow_area_l(1), volume_flow_area(1),      &
+                           2, MPI_REAL, MPI_SUM, comm2d, ierr )
 
 #else
-          volume_flow_initial = volume_flow_initial_l
-          volume_flow_area    = volume_flow_area_l
+       volume_flow_initial = volume_flow_initial_l
+       volume_flow_area    = volume_flow_area_l
 #endif  
 
@@ -1188,13 +1176,29 @@
 !--       In case of 'bulk_velocity' mode, volume_flow_initial is overridden
 !--       and calculated from u|v_bulk instead.
-          IF ( TRIM( conserve_volume_flow_mode ) == 'bulk_velocity' )  THEN
-             volume_flow_initial(1) = u_bulk * volume_flow_area(1)
-             volume_flow_initial(2) = v_bulk * volume_flow_area(2)
-          ENDIF
-
-       ENDIF
+       IF ( TRIM( conserve_volume_flow_mode ) == 'bulk_velocity' )  THEN
+          volume_flow_initial(1) = u_bulk * volume_flow_area(1)
+          volume_flow_initial(2) = v_bulk * volume_flow_area(2)
+       ENDIF
+
+    ENDIF
+
+
+!
+!-- Impose random perturbation on the horizontal velocity field and then
+!-- remove the divergences from the velocity field at the initial stage
+    IF ( create_disturbances .AND. &
+         TRIM( initializing_actions ) /= 'read_restart_data'  .AND.  &
+         TRIM( initializing_actions ) /= 'cyclic_fill' )  THEN
+
+       CALL disturb_field( nzb_u_inner, tend, u )
+       CALL disturb_field( nzb_v_inner, tend, v )
+       n_sor = nsor_ini
+       CALL pres
+       n_sor = nsor
+    ENDIF
+
 !
 !-- Initialization of the leaf area density
-    IF ( plant_canopy ) THEN
+     IF ( plant_canopy ) THEN
  
        SELECT CASE ( TRIM( canopy_mode ) )
Index: palm/trunk/SOURCE/pres.f90
===================================================================
--- palm/trunk/SOURCE/pres.f90	(revision 679)
+++ palm/trunk/SOURCE/pres.f90	(revision 680)
@@ -4,4 +4,7 @@
 ! Current revisions:
 ! -----------------
+!
+! gryschka
+! bugfix in case of collective_wait
 !
 ! Former revisions:
@@ -118,4 +121,5 @@
 !
 !-- Left/right
+
     IF ( conserve_volume_flow  .AND.  ( outflow_l  .OR. outflow_r ) )  THEN
 
@@ -138,5 +142,5 @@
 
 #if defined( __parallel )   
-       IF ( collective_wait )  CALL MPI_BARRIER( comm2d, ierr )
+       IF ( collective_wait )  CALL MPI_BARRIER( comm1dy, ierr )
        CALL MPI_ALLREDUCE( volume_flow_l(1), volume_flow(1), 1, MPI_REAL, &
                            MPI_SUM, comm1dy, ierr )   
@@ -177,5 +181,5 @@
 
 #if defined( __parallel )   
-       IF ( collective_wait )  CALL MPI_BARRIER( comm2d, ierr )
+       IF ( collective_wait )  CALL MPI_BARRIER( comm1dx, ierr )
        CALL MPI_ALLREDUCE( volume_flow_l(2), volume_flow(2), 1, MPI_REAL, &
                            MPI_SUM, comm1dx, ierr )   
@@ -547,5 +551,5 @@
        
     ENDIF
-
+print*, "cc"
 !
 !-- Correction of the provisional velocities with the current perturbation 
@@ -648,4 +652,5 @@
     ENDIF
 
+
 !
 !-- Conserve the volume flow
