Using Fenics with Petsc TS

Hello,
I am using Fenics together with Petsc TS for timestepping.
This works in serial. If I am using mpirun -N 2 the solution is only calculated on one partition. Which is probably related to the way I access the vectors.
At the moment I use

x=u.vector().vec().copy()

and pass this vector x to the Petsc routines. Afterwards I write it back with

x.copy(u.vector().vec()
u.vector().apply(‘insert’)

What is the right way to interface the vectors in parallel?
Edit:
I am using the discontinous Garlerkin Method, it seems the problem is solved on both partitions, but the domain are not coupled (ghost_mode is set to shared_facet)
Hower solving my steady state problem with dolfin PETScSNESSolver, both partitions are coupled.

Hello,

I can’t answer your question, but I was wondering how you implemented Petsc TS for time stepping.
What does the interface between fenics/Petsc look like?

I currently implement my own backward finite differences, but would like to try to call a solver that does time steping for me.

Thank you