Donate245Patreon129


Important note about version

The following GraphViz versions have been tested, and are known to work:

Note that versions 2.39 to 2.42 do not work very well with PlantUML.

With version 2.44, under Windows, you may have to run dot -c in a command line to finalize the installation, like in the following example:

You may have to run dot -c with Administrator Right.

Another option is to install Win32 version of GraphViz 2.44 which does not require this post-install process.

If you compile Graphviz by yourself, you have to build it with libexpat in order to work with PlantUML.

If you find something wrong, thanks for sending us a note or posting a message on the forum.

Default

By default, the dot executable should be:

You can also specify the environment variable GRAPHVIZ_DOT to set the exact location of your GraphViz executable.

Note for Mac users

You can easily install GraphViz by installing brew on your Mac machine. This could fix issues if you have installed GraphViz as .dmg package.

brew install libtool
brew link libtool
brew install graphviz
brew link --overwrite graphviz

Testing

To have information about where PlantUML expects to find dot, you can use the command line:

java -jar plantuml.jar -testdot

You can also use this special diagram description:

@startuml
testdot
@enduml

Sequence Diagram

First, you should focus only on Sequence Diagrams. Even if you are not interested in sequence diagrams, since they are working without Graphviz, it is somehow simplier to let them work. And if they do not work, other diagrams will probably also not work.

You should then test Sequence Diagrams using the command line, and not in the target tool you want to install (Eclipse, Word, Mediawiki...) :

java -jar plantuml.jar -verbose sequenceDiagram.txt

In the sequenceDiagram.txt file, you can have a very simple test:

@startuml
Alice -> Bob: test
@enduml

The -verbose flag is used to generated some logs that you can send to us, if no image is generated.

Under Unix, you must have X11 librairies installed (which is done by default). Otherwise, you will have some HeadlessException. You may have to add a flag -Djava.awt.headless=true in the command line.

If this is working, but not in your tool, it is probably due to a specific tool issue:

On MediaWiki & Windows, you must set the read & execute permissions on C:\Windows\system32\cmd.exe for the account the PHP web service extension is running under. PHP needs those permissions to "fork" other processes.

Others Diagrams

Once sequence diagrams are working fine, you can focus on others diagrams.

If Graphviz is not installed on your system, you have to install it first.

Under Linux, try to launch dot command into a command shell. You may have to finalize the installation by typing dot -C.

You may have to set GRAPHVIZ_DOT variables if you have not chosen the default installation directory of Graphviz.

To test the installation of Graphviz, you can use the command line:

java -jar plantuml.jar -testdot

You can also use this special diagram description:

@startuml
testdot
@enduml

Once again, you should test using the command line and the -verbose flag:

java -jar plantuml.jar -verbose classDiagram.txt

The classDiagram.txt file can be very simple:

@startuml
A <|-- B
@enduml

If you still have issues, then you can send us a mail.