Mucosal immunity typically involves innate and adaptive immune cells, while the cellular mechanism of teleost's intestinal immune cells that engages gut homeostasis against bacterial infection remains largely unknown. Taking advantage of the enteric fish pathogen (Edwardsiella piscicida) infection-induced intestinal inflammation in turbot (Scophthalmus maximus), we find that β-glucan training could mitigate the bacterial infection-induced intestinal inflammation. Through single-cell transcriptome profiling and cellular function analysis, we identify that E. piscicida infection could tune down the activation of intestinal Th17 cells, while β-glucan-training could preserve the potential to amplify and restore the function of intestinal Th17 cells. Moreover, through pharmacological inhibitor treatment, we identify that Th17 cells are essential for ameliorating bacterial infection-induced intestinal inflammation in teleost. Taken together, these results suggest a new concept of trained immunity activation to regulate the intestinal Th17 cells' function, which might contribute to better developing strategies for maintaining gut homeostasis against bacterial infection.