To load the octomap in Gazebo, you have to get a COLLADA file first. To get it, you can can follow these steps:
First, save the octomap using the node provided by the octomap_server package itself:
rosrun octomap_server octomap_saver octomap_model_test.bt
Then, run provided by the octomap library, inside octomap/bin, to obtain the corresponding .pcd file:
./octree2pointcloud ~/octomap_model_test.bt octomap_model_test.pcd
To get the COLLADA (.dae) file that can be loaded into Gazebo, the way I know is converting the .pcd to a .ply file first. The PCL library offers an Ubuntu command for this task:
pcl_pcd2ply octomap_model_test.pcd octomap_model_test.ply
Once you have the .ply file, it can be converted to a .dae file with, for example, MeshLab:
Install meshlab.
sudo apt update
sudo apt install meshlab
Open meshlab.
'File' > 'Import Mesh (Ctrl+I)'.
'Export Mesh As...'.
Select 'Collada File Format (*.dae)'.
Once you have the model with a .dae format, you can load it in Gazebo as usual. I posted an example here of how to do it, where I also suggest how to keep the texture of the PLY file with COLLADA. However, I don't know how to save the octomap keeping the colour of the voxels. I'd appreciate it if someone has any information on this.
Hope it helps!