After fidling a bit, I was able to make it work. Here’s what I did, if anyone is interested:
1- created a dataset for graylog, called “graylog”
2- install plugin “Graylog”
3- Stop graylog jail
4- in truenas CLI, copy the following dirs from the jail to the Dataset
a) cp -rp /mnt/Disk/iocage/jails/graylog/root/var/db/elasticsearch /mnt/Disk/graylog/.
b) cp -rp /mnt/Disk/iocage/jails/graylog/root/var/db/graylog /mnt/Disk/graylog/.
c) cp -rp /mnt/Disk/iocage/jails/graylog/root/var/db/mongodb /mnt/Disk/graylog/.
→ where “Disk” is my pool, and /mnt/Disk/graylog my dataset
5- Update permissions to all in mongodb:
a) chmod a+rwx /mnt/Disk/graylog/mongodb
6- do this command: iocage get -r enforce_statfs
in order for elasticsearch to work, this property in your graylog jail needs to be set to “1”. Mine was set to “2”
7- edit /mnt/Disk/iocage/jails/graylog/config.json, and add the following line:
a) “enforce_statfs”: “1”,
b) save and exit
8- running “iocage get -r enforce_statfs” again should show the property now set to “1”
9- Now, start your jail back up. Should be good to go, after it sets up everything.
10- doing a “tail -f /mnt/Disk/iocage/jails/graylog/root/var/log/graylog/server.log” should show you how everything is going.
When it hits “.InputSetupService [eventbus-handler-1] Triggering launching persisted inputs, node transitioned from Uninitialized [LB:DEAD] to Running [LB:ALIVE]”, you should be able to log in.