How to combine .rma6 file


Hi there,

I’m working with the MEGAN command line mode.
I want to know how to combine multiple .rma6 files created by blast2rma script.
When I simplly concatenate .rma6 files (using bash cat command) it doesn’t work because .rma6 files contain binary.

Here is my commands

./blast2rma -i ~ -o out1.rma6 -a2kegg ~ -f ~ -bm ~ -c false
./blast2rma -i ~ -o out2.rma6 -a2kegg ~ -f ~ -bm ~ -c false

cat out1.rma6 out2.rma6 > out_concat.rma6

then I open out_concat.rma6 using MEGAN, the error below occurs.

Thanks a lot for your help!


Hi Marina.

rma files can’t be concatenated. You can open two or more .rma files and then use menu items of the Sample Viewer to combined into a “total biome” file that represents the union of all the files


Thank you for your reply, Daniel.

I want to use commandFile option, how can I do that using command line mode?

$ ./MEGAN -g -c



Do something like this:

-g -c ~/script -E

However, please note that this is only available in MEGAN UE

If you are using MEGAN CE, then use one of the command line programs in the tools directory